Skip to content

Esta página también está en español.

Léela en español

このページは日本語でも読めます。

日本語で読む

本页也有简体中文版本。

阅读简体中文版本

evaluate function

Evaluate an expression even where it would be held.

How to write it

evaluate(expr)

expr
Any expression: a number, a formula, a list or a matrix. Takes an expression.

Examples

  • 1+1=2\displaystyle 1+1 = 2
    evaluate(1 + 1)

    In the solver, evaluate(1 + 1) gives 2.

    Open in the solver
  • function

    A function with no name; also written x => body.

  • divide_by

    Divide a variable by a value in place and return the new value.

  • ifelse

    A value chosen by a test.

  • decrement

    Subtract 1 from a variable in place and return its old value.

  • increment

    Add 1 to a variable in place and return its old value.

  • construct

    Apply a head that is itself computed to arguments, as in f'(0) or (x => body)(a).