Manual
Math Package for
W
INTERPRET
(T
7
833)
PD
- 7
043
March, 06
5
ROOT1 = (
-
B + SQRT(B^2
-
4*A*C)) / (2*A)
The exponentiation operato
r (
Y^X
) can only raise
Y
to an
integer power
X
. If you need to calculate
Y
X
for non
-
integer
values of
X
you can use the
LN(X)
and
EXP(X)
functions as
shown below.
Y_2_THE_X = EXP(X*LN(Y))
Conditional Statements
The statements available in the floating point math let you
alter program flow based on testing of conditions.
IF, ELSE, and ENDIF
The IF statement is used to make a decision regarding
program flow based on the result returned by an expression.
The expression can include mathematical and logical
operators. The use of ELSE within the lines controlled by the
IF statement is optional.
Syntax:
IF expression
•
•
ELSE (optional)
•
•
ENDIF
IF, ELSE, and ENDIF statements must not
be combined on
the same line.
WHILE and ENDW
The WHILE statement executes a series of statements in a
loop as long as the expression is true. The expression can
include mathematical and logical operators.
Syntax:
WHILE expression
•
•
loop statement
Note: