There is an extensive list of math functions available in Simul8 through the Formula Editor in Visual Logic. These can be used as a part of a command that requires a Logic Flow rule before the function. You will need to use square brackets around the Object/distribution/parameter. For example:
IF [ABS[gbl_variable]] >10
Returns the absolute value of a number, i.e. converts a negative number to a positive number.
For example, ABS[-3] returns 3.
Returns Arc Tangent of the parameter.
Returns Cosine of the parameter.
Converts number from time to day 1-7 calculated from the Clock Properties.
Returns e to the power of the parameter (natural anti-log).
Converts number from time to hour 1-23.
Search through a series of numbers without the need to use multiple IF Statements.
This Command is case sensitive and must be in capital letters.
For example, IF gbl_variable INSET[1-5,9,12] tests if the
variable is equal to 1, 2, 3, 4, 5, 9, or 12.
Returns the natural logarithm of the parameter.
Converts number from time to minute 1-59.
Multiplies the number by -1.
Returns a random number between 1 and 0. The parameter entered must be zero.
Calculates the mod (remainder after divide) for real number, where \ is the mod operator.
For example, REALMOD[8\7.5] returns 0.5
Rounds a number to the nearest integer. If the number to be rounded is exactly halfway between two whole numbers, the result is always the even number. This method of rounding is often called "Banker's Rounding". If you wish to always round to the lower integer value, use the TRUNC function.
Gets a random value from a statistical distribution.
Converts text sheet columns Label to numbers, for example, column A = 1.
Returns the Sine of the parameter.
Returns the square root of the parameter.
Returns the tangent of the parameter.
Rounds number to integer by moving toward zero.
Converts number from time to week number 1, week number 2 etc. Calculated using Clock Properties.
Access advanced Work Items properties.