iDevOS CALC "TANH" Command
Get the hyperbolic tangent of an angle.
Description
CALC( y, a, "TANH" ); // y = tanh(a) = hyperbolic tangent of a CALC( y, a, b, "TANH" ); // y = tanh(a) * b = hyperbolic tangent of a then multiplied by b
This command returns y
as the hyperbolic tangent of the angle a
. If the multiplier value b
is specified then the result is further multiplied by b
.
The angle y
by default is specified in Degrees. Angles used in trigonometric functions can be set globally to use Radians by the SYSTEM.angles
property.
Trigonometric functions: "COS"
, "SIN"
, "TAN"
, "ACOS"
, "ASIN"
, "ATAN"
, "ATAN2"
, "COSH"
, "SINH"
, "TANH"
, "ACOSH"
, "ASINH"
, "ATANH"
.
Parameters
y
- Calculation result.
Parameter type: entity name of numeric variable (S8, S32, FLT3 etc). a
andb
- Input values
Parameter type: immediate number, or entity name of numeric variable (S8, S32, FLT3 etc). "TANH"
- CALC command operator.
Parameter type: immediate string.
Examples
Example 1
VAR(df, 0.0, FLT4); // result VAR(af, 15.0, FLT4); // angle VAR(bf, 5, FLT4); // multiplier CALC(df, af, "TANH"); // df = 0.6558 CALC(df, af, bf, "TANH"); // df = 3.2790