Radio Shack CTR-118 User Manual Page 89

  • Download
  • Add to my manuals
  • Print
  • Page
    / 196
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 88
7-1
7 / Arithmetic Functions
LEVEL II BASIC offers a wide variety of intrinsic ("built-in")
functions for performing arithmetic and special operations.
The special-operation functions are described in the next
chapter.
All the common math functions described in this chapter
return single-precision values
accurate to six decimal
places.
ABS, FIX and INT return values whose precision
depends on the precision of the argument.
The conversion functions (LINT, CDBL, etc.) return values
whose precision depends on the particular function. Trig
functions use or return radians, not degrees. A radian-degree
conversion is given for each of the functions.
For all the functions, the argument must be enclosed in
parentheses. The argument may be either a numeric variable,
expression or constant.
Functions described in this chapter:
ABS COS INT SGN
ATN CSNG LOG SIN
CDBL EXP RANDOM SQR
CINT FIX RND TAN
ABS
(x)
Returns the absolute value of the argument. ABS(X)=X for X greater than or
equal to zero, and ABS(X)=-X for X less than zero.
100 IF ABS(X)<1E-6 PRINT "TOO SMALL"
ATN
(x)
Returns the arctangent (in radians) of the argument; that is, ATN(X) returns
"the angle whose tangent is X". To get arctangent in degrees, multiply
ATN(X) by 57.29578.
100 Y=ATN(B/C)
Page view 88
1 2 ... 84 85 86 87 88 89 90 91 92 93 94 ... 195 196

Comments to this Manuals

No comments