Home KnowledgeBase CANCapture and ECOM Knowledgebase Math functions in scripting library
Math functions in scripting library
Version 1.6 adds support for various math functions in the CANCapture script blocks.

The following functions are now available:


// Trigonometric functions

float cos(float);

float sin(float);

float tan(float);

float acos(float);

float asin(float);

float atan(float);

 

// Hyberbolic functions

float cosh(float);

float sinh(float);

float tanh(float);

 

// Exponential and logarithmic functions

float log(float);

float log10(float);

 

// Power functions

float pow(float, float);

float sqrt(float);

 

// Nearest integer, absolute value, and remainder functions

float ceil(float);

float abs(float);

float floor(float);

float fraction(float);