Radio Shack CTR-118 User Manual Page 91

  • Download
  • Add to my manuals
  • Print
  • Page
    / 196
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 90
7-3
EXP
(x)
Returns the "natural exponential" of X, that is,
ex.
This is the inverse of the
LOG function, so X=EXP(LOG(X)).
100 PRINT EXP(-X)
FIX
(x)
Returns a truncated representation of the argument. All digits to the right of
the decimal point are simply chopped off, so the resultant value is an integer.
For non-negative X, FIX(X)=lNT(X). For negative values of X,
FIX(X)=INT(X)+1. For example, FIX(2.2) returns 2, and FIX(-2.2) returns -2.
100 Y=ABS(A-FIX(A))
This statement gives Y the value of the fractional portion of A.
INT
(x)
Returns an integer representation of the argument, using the largest whole
number that is not greater than the argument. Argument is not limited to the
range -32768 to +32767. The result is stored internally as a single-precision
whole number. INT(2.5) returns 2; INT(-2.5) returns -3; and INT(1000101.23)
returns 10000101.
100 Z=INT(A*100+.5)/100
Gives Z the value of A rounded to two decimal places (for nonnegative A).
LOG
(x)
Returns the natural logarithm of the argument, that is,
log
e
(argument ). This
is the inverse of the EXP function, so X=LOG(EXP (X)). To find the logarithm
of a number to another base b, use the formula log
b
(X) = log
e
(X)/log
e
(b). For
example, LOG(32767)/LOG(2) returns the logarithm to base 2 of 32767.
100 PRINT LOG(3.3*X)
Page view 90
1 2 ... 86 87 88 89 90 91 92 93 94 95 96 ... 195 196

Comments to this Manuals

No comments