mathtrans.library Reference

Comprehensive function reference for mathtrans.library, synthesised from the AmigaOS NDK 3.2 Release 4 (Autodocs/AG/mathtrans).

This page documents 17 functions of mathtrans.library. Each function entry follows the canonical autodoc format. struct Name, union Name, enum Name are clickable links to the type definition in the types reference.

Function index


SPAcos()

SPAcos - obtain the arccosine of the floating point number

Synopsis

D0 fnum2 = SPAcos(D0.L fnum1)

FLOAT SPAcos( FLOAT parm );

Function

Accepts a floating point number representing the cosine of an angle and returns the value of said angle in radians

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPSin()


SPAsin()

SPAsin - obtain the arcsine of the floating point number

Synopsis

D0 fnum2 = SPAsin(D0.L fnum1)

FLOAT SPAsin( FLOAT parm );

Function

Accepts a floating point number representing the sine of an angle and returns the value of said angle in radians

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPCos()


SPAtan()

SPAtan - obtain the arctangent of the floating point number

Synopsis

D0 fnum2 = SPAtan(D0.L fnum1)

FLOAT SPAtan( FLOAT parm );

Function

Accepts a floating point number representing the tangent of an angle and returns the value of said angle in radians

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPTan()


SPCos()

SPCos - obtain the cosine of the floating point number

Synopsis

D0 fnum2 = SPCos(D0.L fnum1)

FLOAT SPCos( FLOAT parm );

Function

Accepts a floating point number representing an angle in radians and returns the cosine of said angle.

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPAcos()


SPCosh()

SPCosh - obtain the hyperbolic cosine of the floating point number

Synopsis

D0 fnum2 = SPCosh(D0.L fnum1)

FLOAT SPCosh( FLOAT parm );

Function

Accepts a floating point number representing an angle in radians and returns the hyperbolic cosine of said angle.

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPSinh()


SPExp()

SPExp - obtain the exponential (eX) of the floating point number**

Synopsis

D0 fnum2 = SPExp(D0.L fnum1)

FLOAT SPExp( FLOAT parm );

Function

Accepts a floating point number and returns the value of e raised to the fnum1 power

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPLog()


SPFieee()

SPFieee - convert single precision ieee to FFP number

Synopsis

D0 fnum = SPFieee(D0.L ieeenum)

FLOAT SPFieee( FLOAT parm );

Function

Accepts a standard single precision format returns the same number, converted to Motorola fast floating point number

Inputs

ieeenum - IEEE Single Precision Floating Point

Results

fnum - Motorola fast floating point number

Bugs

None

See also

SPTieee()


SPLog()

SPLog - obtain the natural logarithm of the floating point number

Synopsis

D0 fnum2 = SPLog(D0.L fnum1)

FLOAT SPLog( FLOAT parm );

Function

Accepts a floating point number and returns the natural logarithem (base e) of said number

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number If the argument is invalid, the V flag is set on on return.

Bugs

None

See also

SPExp()


SPLog10()

SPLog10 - obtain the naperian logarithm(base 10) of the floating point number

Synopsis

D0 fnum2 = SPLog10(D0.L fnum1)

FLOAT SPLog10( FLOAT parm );

Function

Accepts a floating point number and returns the naperian logarithm (base 10) of said number

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

 If the argument is invalid, the V flag is set on
 on return.

Bugs

None

See also

SPExp()


SPPow()

SPPow - raise a number to a power

Synopsis

D0 result = SPPow(D1.L fnum1, D0.L fnum2)

FLOAT SPPow( FLOAT power, FLOAT arg );

Function

Accepts two floating point numbers and returns the result of fnum2 raised to the fnum1 power

Inputs

fnum1 - Motorola fast floating point number fnum2 - Motorola fast floating point number

Results

result - Motorola fast floating point number

 On error, for example overflow, the V bit
 is set on return.

Bugs

None

See also

SPExp(), SPLog()


SPSin()

SPSin - obtain the sine of the floating point number

Synopsis

D0 fnum2 = SPSin(D0.L fnum1)

FLOAT SPSin( FLOAT parm );

Function

Accepts a floating point number representing an angle in radians and returns the sine of said angle.

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPAsin()


SPSincos()

SPSincos - obtain the sine and cosine of a number

Synopsis

D0 fnum3 = SPSincos(D1.L pfnum2, D0.L fnum1)

FLOAT SPSincos( FLOAT *cosResult, FLOAT parm );

Function

Accepts a floating point number (fnum1) representing an angle in radians and a pointer to another floating point number (pfnum2). It computes the cosine and places it in *pfnum2. It computes the sine and returns it as a result.

Inputs

fnum1 - Motorola fast floating point number pfnum2 - pointer to Motorola fast floating point number

Results

*pfnum2 - Motorola fast floating point number (cosine) fnum3 - Motorola fast floating point number (sine)

Bugs

None

See also

SPSin(), SPCos()


SPSinh()

SPSinh - obtain the hyperbolic sine of the floating point number

Synopsis

D0 fnum2 = SPSinh(D0.L fnum1)

FLOAT SPSinh( FLOAT parm );

Function

Accepts a floating point number representing an angle in radians and returns the hyperbolic sine of said angle.

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPCosh()


SPSqrt()

SPSqrt - obtain the square root of the floating point number

Synopsis

D0 fnum2 = SPSqrt(D0.L fnum1)

FLOAT SPSqrt( FLOAT parm );

Function

Accepts a floating point number and returns the square toot of said number

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPPow(), SPMul()


SPTan()

SPTan - obtain the tangent of the floating point number

Synopsis

D0 fnum2 = SPTan(D0.L fnum1)

FLOAT SPTan( FLOAT parm );

Function

Accepts a floating point number representing an angle in radians and returns the tangent of said angle.

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPAtan()


SPTanh()

SPTanh - obtain the hyperbolic tangent of the floating point number

Synopsis

D0 fnum2 = SPTanh(D0.L fnum1)

FLOAT SPTanh( FLOAT parm );

Function

Accepts a floating point number representing an angle in radians and returns the hyperbolic tangent of said angle.

Inputs

fnum1 - Motorola fast floating point number

Results

fnum2 - Motorola fast floating point number

Bugs

None

See also

SPSinh(), SPCosh()


SPTieee()

SPTieee - convert FFP number to single precision ieee

Synopsis

D0 ieeenum = SPTieee(D0.L fnum)

FLOAT SPTieee( FLOAT parm );

Function

Accepts a Motorola fast floating point number and returns the same number, converted into IEEE standard single precision format

Inputs

fnum - Motorola fast floating point number

Results

ieeenum - IEEE Single Precision Floating Point

Bugs

None

See also

SPFieee()