User Tools

Site Tools

한국어

cubloc:math_functions:index

Math Functions

Sin, Cos, Tan

Return sine, cos ine, and tangent values. Cubloc uses radians as units. Use a Single for most precise results.

A=Sin B         ' Return the sine of B.
A=Cos B         ' Return the cosine of B.
A=Tan B         ' Return the tangent of B.

ASin, ACos, ATan

Return arc sine, arc cosine, and arc tangent values. Cubloc uses radians as units. Use a Single for the most precise results.

A=ASin B        ' Return the arc sine of B.
A=ACos B        ' Return the arc cosine of B.
A=ATan B        ' Return the arc tangent of B.

Sinh, Cosh, Tanh

Return hyperbolic sine, hyperbolic cosine, and hyperbolic tangent values.

A=Sinh B        ' Return the hyperbolic sine of B.
A=Cosh B        ' Return the hyperbolic cosine of B.
A=Tanh B        ' Return the hyperbolic tangent of B.

Sqr

Return Square Root of a value.

A=Sqr B        ' Return the square root of B

Exp

Return eX.

A=Exp X        'Returns eX.

Log, Log10

Return Log or Log10 of a value.

A=Log B 
A=Log10 B

For the natural logarithm (Ln), simply do: A=Log B

Abs

Return the absolute value of a Long.

Dim A As Long, B As Long
B = -1234
A=Abs B           ' Return |B|.
Debug Dec A       ' Print 1234

FAbs

Return the absolute value of a Single.

Dim A As Single, B As Single
B=-1234.0
A=Fabs B          ' Return |B|.
Debug Float A     ' Print 1234.00

Floor

Round down to the nearest whole number.

Dim A As Single, B As Single
B = 3.5
A=Floor B         ' Floor 3.5 gives 3.
Debug Float A     ' Print 3.0

Go CUBLOC home

cubloc/math_functions/index.txt · Last modified: 2016/04/14 11:07 (external edit)