Harbour All Functions – S

SaveToken

SayScreen

Seconds
Secs

Select

Set

SetAtLike

SetDate

SetKey

SetMode

SetPrec

SetTime

SetTypeahead

Sign

Sin

SinH

Space

Sqrt

Str

StrDiff

StrFormat

StrSwap
StrTran
StrZero
SubStr

Harbour Math Functions

Abs

ACos

ASin

ATan

ATn2

Cos

CosH

DToR

Exp

Exponent 

Fact

Floor

GetPrec

hb_mathErBlock
hb_mathErMode
hb_mathGetErrMode
hb_mathGetHandler
hb_mathGetLastError
hb_mathIsMathErr
hb_mathResetError
hb_mathSetErrMode
hb_mathSetHandler

Infinity
Int
Log

Log10
Max

Mantissa
Min
Mod

Pi
Round

RToD

SetPrec

Sign

Sin

SinH
Sqrt

Tan

TanH

CT_SETPREC

 SETPREC()
 Sets the precision level for trigonometric functions
------------------------------------------------------------------------------
 Syntax

     SETPREC(<nPrecision>) --> cNull

 Argument

     <nPrecision>  Designates the number of places for computational
     precision in the range of 1 to 16.  The default value is 16.

 Returns

     SETPREC() always returns a null string.

 Description

     SET PRECISION
     
     Clipper Tools works with the default precision set at 16 places to
     the right of the decimal for trigonometric functions.  If you do not
     want this precision level, or you want a faster execution speed, reduce
     the number of places accordingly.  The following functions are affected:

     SIN()  COS()  TAN()  COT()  ASIN()  ACOS()  ATAN()  ATN2()

 Example

     Set a precision level of 10 places:

     SETPREC(10)         // Always returns a null string

See Also: GETPREC() SIN() COS() TAN() COT() ASIN() ACOS()

 

Introduction Mathematical Functions

 Introduction

     This chapter offers an array of interesting mathematical functions to
     implement in Clipper.  It includes trigonometric functions, finance-
     oriented math computations, and functions to determine the factorial,
     sign, or the next-largest integer of a value.

     SETPREC() is important for trigonometric functions.  With this function
     you can specify the precision as a number of places to the right of the
     decimal.  However, if it is less accurate, the speed is greater.

Tools — Mathematical Functions

Introduction Mathematical Functions
ACOS()    Computes the cosine arc
ASIN()    Computes the sine arc
ATAN()    Computes the tangent arc
ATN2()    Computes the angle size from the sine and cosine
CEILING() Rounds up to the next integer
COS()     Computes the cosine
COT()     Computes the cotangent
DTOR()    Converts from a degree to radian measure
FACT()    Computes the factorial
FLOOR()   Rounds down to the next integer
FV()      Computes future value of capital
GETPREC() Determines the level of precision that is set
LOG10()   Computes the common logarithm
PAYMENT() Computes the periodic payment amount
PERIODS() Computes number of payment periods necessary to repay a loan
PI()      Returns pi with the highest degree of accuracy
PV()      Computes the cash present value after interest charges
RATE()    Computes the interest rate for a loan
RTOD()    Converts from a radian to degree measure
SETPREC() Sets the precision level for trigonometric functions
SIGN()    Determines the mathematical sign of a number
SIN()     Computes the sine of a radian value
TAN()     Computes the tangent of a radian value