In addition to basic floating point arithmetic (addition, subtraction, multiplication, and division) and floating point comparisons, a number of exponential and transcendental functions are built in to IC . These are implemented with a public domain library of routines provided by Motorola.
Keep in mind that all floating point operations are quite slow; each takes one to several milliseconds to complete. If Interactive C's speed seems to be poor, extensive use of floating point operations is a likely cause.
float sin(float angle)
Returns sine of
angle. Angle is specified in
radians; result is in radians.
float cos(float angle)
Returns cosine of
angle.
Angle is specified in radians; result is in radians.
float tan(float angle)
Returns tangent of
angle.
Angle is specified in radians; result is in radians.
float atan(float angle)
Returns arc tangent of
angle.
Angle is specified in radians; result is in radians.
float sqrt(float num)
Returns square root of
num.
float log10(float num)
Returns logarithm of
num to
the base 10.
float log(float num)
Returns natural logarithm of
num.
float exp10(float num)
Returns 10 to the
num power.
float exp(float num)
Returns e to the
num power.
(float) a ^
(float) b
Returns
a to the
b
power.