AmesimKnowledge

Description of the Expression Editor functions

Functions available from the Tools menu or when changing a submodel

parameter

When you open the Expression Editor from the Tools menu, or when changing a submodel parameter, the following functions are available:

Function Description Function Description
abs Valid expressions for the Expression editor abs abs absolute value fabs Valid expressions for the Expression editor fabs fabs absolute value of floating
acos Valid expressions for the Expression editor acos acos arc cosine floor floor
acosh Valid expressions for the Expression editor acosh acosh inverse hyperbolic cosine integ Valid expressions for the Expression editor integ integ integration
asin Valid expressions for the Expression editor asin asin arc sine log Valid expressions for the Expression editor log log natural logarithm
asinsh Valid expressions for the Expression editor asinsh asinsh inverse hyperbolic sine log10 Valid expressions for the Expression editor log10 log10 base-10 logarithm
atan Valid expressions for the Expression editor atan atan arc tangent mod Valid expressions for the Expression editor mod mod modulo
atanh Valid expressions for the Expression editor atanh atanh inverse hyperbolic tangent round Valid expressions for the Expression editor round round round
ceil Valid expressions for the Expression editor ceil ceil ceil sin Valid expressions for the Expression editor sin sin sine
cos Valid expressions for the Expression editor cos cos cosine sinh Valid expressions for the Expression editor sinh sinh hyperbolic sine
cosh Valid expressions for the Expression editor cosh cosh hyperbolic cosine sqrt Valid expressions for the Expression editor sqrt sqrt square root
differ Valid expressions for the Expression editor differ differ differentiation tan Valid expressions for the Expression editor tan tan tangent
exp Valid expressions for the Expression editor exp exp exponential tanh Valid expressions for the Expression editor tanh tanh hyperbolic tangent
  • The following functions of two variables:

Function

Description

Function

Description

     atan2
    
     Valid expressions for the Expression editor
     atan2
    atan2

arc tangent of y/x

     sign
    
     Valid expressions for the Expression editor
     sign
    sign

sign

     lsqrta
    lsqrta

square root

  • The following functions of two or more variables:

Function

Description

Function

Description

     min
    
     Valid expressions for the Expression editor
     min
    min

minimum

     max
    
     Valid expressions for the Expression editor
     max
    max

maximum

The meaning of most of these functions is obvious. However, here we give more details on some of them.

atan

The function atan2(a,b) means atan(a/b) unless b=0 in which case it means (∞) *=*π/2 if a≠0 and is an error otherwise.

ceil

Smallest integer value that is not less than x.

differ and integ

The function differ differentiates the argument with respect to time whereas integ integrates it. Note these two functions operate on the data stored in the results file. There is no control on error for these two functions and they should be regarded as rough estimates (1st order only) .

floor

floor

Smallest integer value that is not greater than x.

lsqrta

This utility is used to compute the square root of an input. The validity interval of the function lsqrta is . In fact, negative input values are accepted and the returned value is then .The function lsqrta also includes a linear region for input values which are too close to zero. The amplitude of this linear region centered on 0 can be set by the user with the xcrit.

Then, for the square root is considered as linear. The slope of the linear part is adjusted to allow continuity between linear and non linear signals. Its value is .

Figure 510: The characteristics of the function lsqrta

max/min

Returns the maximum or minimum of the arguments. You can enter as many arguments as you need.

round

Round x to the nearest integer, but round halfway cases away from zero.

sign

The function sign(a,b) means the absolute value of a with the sign of b.

Source: https://docs.sw.siemens.com/en-US/doc/254352342/PL20250521841123434.amesim_collection.Reference/id47817 · retrieved 2026-07-17