39.3 Overview of operations and functions in expression fields

This section lists the operations and functions available in the expression field editor. Arguments to trigonometric functions are assumed to be in radians in the range from to . For more information, see the documentation for the math module on the official Python home page.

Mathematical operations:

+Add
Subtract
*Multiply
/Divide
%Return the remainder of integer division.
1/AReturn the reciprocal of A.
ceil(A)Return the ceiling of A, the smallest integer value greater than or equal to A.
fabs(A)Return the absolute value.
floor(A)Return the floor of A, the largest integer value less than or equal to A.
fmod(A,B)Return fmod(A, B), as defined by the platform C library. The intent of the C standard is that fmod(A, B) be exactly (mathematically; to infinite precision) equal to An * B for some integer n such that the result has the same sign as A and magnitude less than abs(B).
modf(A)Return the fractional and integer parts of A.

Trigonometric functions:

acos(A)Return the arccosine.
asin(A)Return the arcsine.
atan(A)Return the arctangent.
cos(A)Return the cosine.
cosh(A)Return the hyperbolic cosine.
hypot(A,B)Return the Euclidean norm, sqrt(A*A + B*B). This is the length of the vector from the origin to point (A, B).
sin(A)Return the sine.
sinh(A)Return the hyperbolic sine.
tan(A)Return the tangent.
tanh(A)Return the hyperbolic tangent.

Power and logarithmic functions:

exp(A)Return the natural exponential to the power A, .
ldexp(A,B)Return A * ().
log(A)Return the natural logarithm.
log10(A)Return the base 10 logarithm.
pow(A,B)Raise a variable to a power.
sqrt(A)Return the square root.

Constants:

piMathematical constant π.
eMathematical constant e.


For information on related topics, click any of the following items: