User manual
687
mikoPascal PRO for dsPIC30/33 and PIC24
MikroElektronika
exp
Prototype
function exp(x : real) : real;
Description Function returns the value of e — the base of natural logarithms — raised to the power x (i.e. e
x
).
Example
res := exp(0.5); // res := 1.648721
fabs
Prototype
function fabs(d : real) : real;
Description Function returns the absolute (i.e. positive) value of d.
Example
res := fabs(-1.3); // res := 1.3
oor
Prototype
function oor(x : real) : real;
Description Function returns the value of parameter x rounded down to the nearest integer.
Example
res := oor(15.258); // res := 15.000000
frexp
Prototype
function frexp(value : real; var eptr : integer) : real;
Description The function splits a oating-point value value into a normalized fraction and an integral power of 2.
The return value is a normalized fraction and the integer exponent is stored in the object pointed to by
eptr.
ldexp
Prototype
function ldexp(value : real; newexp : integer) : real;
Description Function returns the result of multiplying the oating-point number num by 2 raised to the power n (i.e.
returns x * 2
n
).
Example
res := ldexp(2.5, 2); // res := 10
log
Prototype
function log(x : real) : real;
Description Function returns the natural logarithm of x (i.e. log
e
(x)).
Example
res := log(10); // res := 2.302585E