FUNCTIONS CORE

SetPrec()

Specify the computing precision for trigonometric functions

Syntax

Signature
SetPrec( nDecimalPlaces ) --> cNullString

Arguments

nDecimalPlaces

Example

SetPrec.prg
PROCEDURE Main()

   Check( 'SetPrec( 10 ) ', SetPrec( 10 ), "" )
   Check( 'GetPrec()     ', GetPrec(), 10 )
   Check( 'SetPrec( 99 ) ', SetPrec( 99 ), "" )
   Check( 'GetPrec()     ', GetPrec(), 10 )

RETURN

STATIC PROCEDURE Check( cTitle, xResult, xExpected )

   QOut( cTitle + IIF( xResult == xExpected, "OK", "ERROR" ) )

RETURN

Output

SetPrec( 10 ) OK
GetPrec()     OK
SetPrec( 99 ) OK
GetPrec()     OK