Intrinsic operations
There are numerous of intrinsic operations in the software which are useful when defining functions. A complete list of the available intrinsic operations are presented here. These operations are divided into five different sections. Direct links to each one of them can be accessed from the quick links below.
Quick links
 Operations
 Objects and values
 Functions
 Feedback of data
 Control flow
Operations
Math operations
Math operations are used to do simple operations between two variables. If one wants to add the variable x with y, the result would be: x + y.
Operation  Description 

+ 
Addition 
 
Substraction 
* 
Multiplication 
/ 
Division 
^ 
Exponentiation 
Logical operations
Logical operations are used in condition controls and control flow operation. For example, 2 $\lt$ 10 would result in logical True.
Operation  Description 

&& 
And 
 
Or 
== 
Equality 
!= 
Inequality 
< 
Strictly less than 
<= 
Less than or equal 
> 
Strictly greater than 
>= 
Greater than or equal 
Objects and values
There are some builtin objects and values that can be used to get data from the simulation, such as time step size or current time.
Operation  Description 

pi 
3.141592653589793... 
dt 
Time step 
t 
Current simulation time 
term 
Termination time 
r 
Radius 
theta 
Angle 
X 
xcoordinate (initial) 
Y 
ycoordinate (initial) 
Z 
zcoordinate (initial) 
x 
xcoordinate (current) 
y 
ycoordinate (current) 
z 
zcoordinate (current) 
vx 
Local velocity in xdirection 
vy 
Local velocity in ydirection 
vz 
Local velocity in zdirection 
xnorm 
xcomponent of local surface normal direction 
ynorm 
ycomponent of local surface normal direction 
znorm 
zcomponent of local surface normal direction 
vnorm 
Local velocity in the normal direction to the surface of the structure 
epsp 
Equivalent plastic strain 
sigy0 
Initial yield stress 
dmg 
Damage 
amax 
Max acceleration 
eint 
Specific internal energy 
pres 
Contact pressure or hydrostatic pressure in material (LOAD_PRESSURE) 
vtang 
Relative tangential sliding velocity (for use with CONTACT) 
dnorm 
Spring elongation in CONNECTOR_SPRING 
vnorm 
Local velocity in the normal direction to the surface of the structure or rate of elongation in CONNECTOR_SPRING 
wi 
Returns the total internal energy in the model 
wk 
Returns the total kinetic energy in the model 
Functions

sin
(
x)

x = degrees Trigonometric sine function (degrees)

cos
(
x)

x = degrees Trigonometric cosine function (degrees)

tan
(
x)

x = degrees Trigonometric tangent function (degrees)

tanh
(
x)

x = degrees Hyperbolic tangent function (degrees)

sinr
(
x)

x = radians Trigonometric sine function (radians)

cosr
(
x)

x = radians Trigonometric cosine function (radians)

tanr
(
x)

x = radians Trigonometric tangent function (radians)

exp
(
x)

x = exp(x) = $e^x$ Exponential function

ln
(
x)

x = positive real number Natural logarithm

log
(
x)

x = positive real number Natural logarithm, identical to ln(x)

log10
(
x)

x = positive real number Logarithm to base 10

sqrt
(
x)

x = positive real number Square root

min
(
$x_1$, $x_2$, $x_n$)

$x_1$ = real number $x_2$ = real number $x_n$ = real number (Optional) Min value of arguments. This function can take up to 10 arguments, min($x_1$, $x_2$, ..., $x_n$)

max
(
$x_1$, $x_2$, $x_n$)

$x_1$ = real number $x_2$ = real number $x_n$ = real number (Optional) Max value of arguments. This function can take up to 10 arguments, max($x_1$, $x_2$, ..., $x_n$)

abs
(
x)

x = value Absolute value

sign
(
x)

x = value Sign function (sign(x $\lt$ 0) = 1; sign(x $\geq$ 0) = 1)

floor
(
x)

x = value Rounds to nearest integer below x

round
(
x)

x = value Rounds to nearest integer

d
(
i, j)

i = value j = value Kronecker delta. The function returns 1 if the variables are equal, and 0 otherwise

H
(
x)

x = value Heaviside Step function (H(x $\lt$ 0) = 0; H(x $\geq$ 0) = 1)

erf
(
x)

x = value Gauss error function

smooth_d
(
dmax, t0, t1)

dmax = displacement t0 = t0 t1 = t1 A displacement defined as smooth_d(%disp, %t_0, %t_1) is smoothly ramped up from 0 to %disp between time %t_0 and %t_1. The input does not have to be based on parameters; direct input works as well. Other quantities, such as pressure, temperature, force, e.t.c. can be used as input instead of displacement in smooth_d()

smooth_v
(
dmax, t0, t1)

dmax = displacement t0 = t0 t1 = t1 Smooth velocity function that is obtained by differentiating smooth_d() with respect to time

smooth_a
(
dmax, t0, t1)

dmax = displacement t0 = t0 t1 = t1 Smooth acceleration function that is obtained by differentiating smooth_v with respect to time

norminv
(
$\mu$, $\sigma$, P, cap)

$\mu$ = Median value $\sigma$ = Standard deviation P = Cumulative point cap = Limit the deviation (Optional) Normal distribution quantile (inverse cumulative distribution function). The function returns a value in a normal distribution. Required input is the median value $\mu$, standard deviation $\sigma$ and a cumulative point in the distribution 0 $\lt$ P $\lt$ 10 (typically a random number). cap is optional and limits the deviation from $\mu$ (max number of standard deviations)

lognorminv
(
$\mu$, $\sigma$, P, cap)

$\mu$ = Median value $\sigma$ = Standard deviation P = Cumulative point cap = Limit the deviation (Optional) Lognormal distribution quantile (inverse cumulative distribution function). The function returns a value in a lognormal distribution. exp($\mu$) is the median value in the distribution, $\sigma$ is the standard deviation of the variable's natural logarithm and 0 $\lt$ P $\lt$ 1 is a cumulative point in the distribution (typically a random number). cap is optional and limits the deviation from μ (max number of standard deviations)
Feedback of data
Curve, function and table
Data from curves, functions and tables defined by:
CURVE, FUNCTION, TABLE

crv
(
cid, x)

cid = Curve ID defined in CURVE x = Abscissa Returns the ordinata of curve cid at abscissa x

fcn
(
fid, x)

fid = Function ID defined in FUNCTION x = Abscissa (Optional) Returns a curve or function value

dfcn
(
fid)

fid = function ID Time derivative of fcn(fid)

table
(
tid, rid, cid)

tid = Table ID rid = Row cid = Column Returns the value at row and column (rid, cid) of table tid
Node
Data from nodes (node id as input)

xn
(
nid)

nid = Node ID Returns the xcoordinate of nid

yn
(
nid)

nid = Node ID Returns the ycoordinate of nid

zn
(
nid)

nid = Node ID Returns the zcoordinate of nid

vxn
(
nid)

nid = Node ID Returns the xvelocity of nid

vyn
(
nid)

nid = Node ID Returns the yvelocity of nid

vzn
(
nid)

nid = Node ID Returns the zvelocity of nid

vn
(
nid)

nid = Node ID Returns the resultant velocity of nid

dist_surf
(
xn(nid), yn(nid), zn(nid))

xn(nid) = xcoordinate yn(nid) = ycoordinate zn(nid) = zcoordinate Distance to material surface
Part
Data from parts defined by: PART

dxp
(
pid)

pid = Part ID Returns the xdisplacement of pid

dyp
(
pid)

pid = Part ID Returns the ydisplacement of pid

dzp
(
pid)

pid = Part ID Returns the zdisplacement of pid

vxp
(
pid)

pid = Part ID Returns the xvelocity of pid

vyp
(
pid)

pid = Part ID Returns the yvelocity of pid

vzp
(
pid)

pid = Part ID Returns the zvelocity of pid

rxp
(
pid)

pid = Part ID Returns the rotation around xaxis of pid

ryp
(
pid)

pid = Part ID Returns the rotation around yaxis of pid

rzp
(
pid)

pid = Part ID Returns the rotation around zaxis of pid

xmaxp
(
pid, xn, yn, zn)

pid = Part ID xn = xdirection yn = ydirection zn = zdirection Returns the maximum coordinate of part measure from (0, 0, 0) in direction (xn, yn, zn)

wip
(
pid)

pid = Part ID Returns the internal energy of pid

wkp
(
pid)

pid = Part ID Returns the kinetic energy of pid

mpp
(
pid)

pid = Part ID Returns the part mass (physical) of pid

mpa
(
pid)

pid = Part ID Returns the part mass (added) of pid

epsp_part
(
pid, option)

pid = Part ID option = See description Option = 0: Largest effective plastic strain
Option = 1: xcoordinate of integration point with largest effective plastic strain
Option = 2: ycoordinate of integration point with largest effective plastic strain
Option = 3: zcoordinate of integration point with largest effective plastic strain

pres_part
(
pid, option)

pid = Part ID option = See description Option = 0: Highest pressure
Option = 1: xcoordinate of integration point with highest pressure
Option = 2: ycoordinate of integration point with highest pressure
Option = 3: zcoordinate of integration point with highest pressure
Sensor
Data from sensor defined by: OUTPUT_SENSOR

xs_old
(
sid)

sid = Sensor ID Returns the xcoordinate (initial) of sid

ys_old
(
sid)

sid = Sensor ID Returns the ycoordinate (initial) of sid

zs_old
(
sid)

sid = Sensor ID Returns the zcoordinate (initial) of sid

xs
(
sid)

sid = Sensor ID Returns the xcoordinate (current) of sid

ys
(
sid)

sid = Sensor ID Returns the ycoordinate (current) of sid

zs
(
sid)

sid = Sensor ID Returns the zcoordinate (current) of sid

dxs
(
sid)

sid = Sensor ID Returns the xdisplacement of sid

dys
(
sid)

sid = Sensor ID Returns the ydisplacement of sid

dzs
(
sid)

sid = Sensor ID Returns the zdisplacement of sid

vxs
(
sid)

sid = Sensor ID Returns the xvelocity of sid

vys
(
sid)

sid = Sensor ID Returns the yvelocity of sid

vzs
(
sid)

sid = Sensor ID Returns the zvelocity of sid

axs
(
sid)

sid = Sensor ID Returns the xacceleration of sid

ays
(
sid)

sid = Sensor ID Returns the yacceleration of sid

azs
(
sid)

sid = Sensor ID Returns the zacceleration of sid

epsps
(
sid)

sid = Sensor ID Returns the effective plastic strain of sid

depsps
(
sid)

sid = Sensor ID Returns the effective plastic strain increment of sid

t_sensor
(
sid)

sid = Sensor ID Returns the pemperature of sid

ps
(
sid)

sid = Sensor ID Returns the pressure of sid

sig1s
(
sid)

sid = Sensor ID Returns the first principal stress of sid
Contact
Data from contacts defined by: CONTACT

fxc
(
cid)

cid = Contact ID Returns the total contact force in xdirection of cid

fyc
(
cid)

cid = Contact ID Returns the total contact force in ydirection of cid

fzc
(
cid)

cid = Contact ID Returns the total contact force in zdirection of cid

fc
(
cid)

cid = Contact ID Returns the resultant contact force of cid
Boundary condition
Data from boundary conditions defined by:
BC_MOTION, BC_SYMMETRY, BC_TELEPORT, BC_TEMPERATURE

fxr
(
bcid)

bcid = Boundary condition ID Returns the reaction force, xdirection of bcid

fyr
(
bcid)

bcid = Boundary condition ID Returns the reaction force, ydirection of bcid

fzr
(
bcid)

bcid = Boundary condition ID Returns the reaction force, zdirection of bcid

fr
(
bcid)

bcid = Boundary condition ID Returns the reaction force, resultant of bcid

txr
(
bcid)

bcid = Boundary condition ID Returns the torque around xaxis of bcid

tyr
(
bcid)

bcid = Boundary condition ID Returns the torque around yaxis of bcid

tzr
(
bcid)

bcid = Boundary condition ID Returns the torque around zaxis of bcid

tr
(
bcid)

bcid = Boundary condition ID Returns the resultant torque of bcid
Geometry
Data from geometries defined by:
GEOMETRY_BOX, GEOMETRY_COMPOSITE, GEOMETRY_EFP, GEOMETRY_PART, GEOMETRY_PIPE, GEOMETRY_SEED_COORDINATE, GEOMETRY_SEED_NODE, GEOMETRY_SPHERE

vol_geo
(
gid, tol, dir)

gid = Geometry ID tol = Tolerance dir = Direction (Optional) Volume enclosed by the element faces in geometry gid. tol is an optional dimensionless tolerance. Gaps in the surface will result in errors. If the estimated (relative) error is larger than tol then the function will return 0 (zero). The optional parameter dir is used to avoid the volume calculation in specific global directions (divergence theorem). This is necessary if the control volume is located on symmetry planes. The global xdirection is avoided if dir = 1, 4 or 6, the global ydirection is avoided if dir = 2, 4 or 5 and the global zdirection is avoided if dir = 3, 5 or 6

vol_geo0
(
gid, tol, dir)

gid = Geometry ID tol = Tolerance dir = Direction Initial volume enclosed by the element faces in geometry gid. The function arguments are the same as for function vol_geo()
Face set
Data from face sets defined by: SET_FACE

volfs
(
setid)

setid = Set ID Returns the volume enclosed by face set of set_id
Joint
Data from joints defined by: RIGID_BODY_JOINT

fxj
(
jid)

jid = Joint ID Returns the force in xdirection of jid

fyj
(
jid)

jid = Joint ID Returns the force in ydirection of jid

fzj
(
jid)

jid = Joint ID Returns the force in zdirection of jid

txj
(
jid)

jid = Joint ID Returns the torque around xaxis of jid

tyj
(
jid)

jid = Joint ID Returns the torque around yaxis of jid

tzj
(
jid)

jid = Joint ID Returns the torque around zaxis of jid

rxj
(
jid)

jid = Joint ID Returns the rotation around xaxis of jid

ryj
(
jid)

jid = Joint ID Returns the rotation around yaxis of jid

rzj
(
jid)

jid = Joint ID Returns the rotation around zaxis of jid

sxj
(
jid)

jid = Joint ID Returns the spin around xaxis of jid

syj
(
jid)

jid = Joint ID Returns the spin around yaxis of jid

szj
(
jid)

jid = Joint ID Returns the spin around zaxis of jid
Control flow
Conditional controls
Conditional statements are used to perform different actions based on different conditions. ~if and ~end_if are always required and can be complemented with ~else_if and/or ~end_if

~if
condition 
~if is used to specify a block of commands to execute if a condition is true. This operation requires a logical condition defined after the input. Multiple ~if statements can be nested.

~else_if
condition 
~else_if is used to specify a new condition if the previous condition is false. This operation requires a logical condition defined after the input.

~else

~else is used to specify a block of commands to execute if all previous conditions are false.

~end_if

~end_if is used to specify the end of a conditional block. If multiple ~if statements are defined, each one of them needs to be closed with ~end_if.
Iterative controls
Commands with iterative input can be defined in a repeat loop instead of being explicitly defined several times. An iterator is assigned for each ~repeat operation. This iterator is defined as a builtin variable named r1. If multiple ~repeat operations are nested, the second dimensioned iterator will be named r2, third r3, etc. Every iterator starts with the value 1 and increments until it reaches the number of specified iterations.

~repeat
iterations 
~repeat is used to specify a block of commands to execute X number of times. This operation requires a constant after the input defining the number of iterations.

~end_repeat

~end_repeat is used to specify the end of a control flow block. If multiple ~repeat operations are defined, each one of them needs to be closed with ~end_repeat.