User manual
608
mikoBasic PRO for PIC32
MikroElektronika
Prototype
sub function acos(dim x as oat) as oat
Description Function returns the arc cosine of parameter x; that is, the value whose cosine is x. The input parameter
x must be between -1 and 1 (inclusive). The return value is in radians, between 0 and Π (inclusive).
Example
res = acos(0.5) ‘ res = 1.047198
Prototype
sub function asin(dim x as oat) as oat
Description Function returns the arc sine of parameter x; that is, the value whose sine is x. The input parameter
x must be between -1 and 1 (inclusive). The return value is in radians, between -Π/2 and Π/2
(inclusive).
Example
res = asin(0.5) ‘ res = 5.235987e-1
Prototype
sub function atan(dim arg as oat) as oat
Description Function computes the arc tangent of parameter f; that is, the value whose tangent is f. The return
value is in radians, between -Π/2 and Π/2 (inclusive).
Example
res = atan(1.0) ‘ res = 7.853982e-1
Prototype
sub function atan2(dim y as oat, dim x as oat) as oat
Description This is the two-argument arc tangent function. It is similar to computing the arc tangent of y/x, except
that the signs of both arguments are used to determine the quadrant of the result and x is permitted to
be zero. The return value is in radians, between -Π and Π (inclusive).
Example
res = atan2(2., 1.) ‘ res = 4.636475e-1
Prototype
sub function ceil(dim x as oat) as oat
Description Function returns value of parameter x rounded up to the next whole number.
Example
res = ceil(0.5) ‘ res = 1.000000
Prototype
sub function cos(dim arg as oat) as oat
Description Function returns the cosine of f in radians. The return value is from -1 to 1.
Example
res = cos(PI/3.) ‘ res = 0.500008
acos
asin
atan
atan2
ceil
cos