[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 SQRT()
 Return the square root of a positive number
------------------------------------------------------------------------------
 Syntax

     SQRT(<nNumber>) --> nRoot

 Arguments

     <nNumber> is a positive number for which the square root is to be
     computed.

 Returns

     SQRT() returns a numeric value calculated to double precision.  The
     number of decimal places displayed is determined solely by SET DECIMALS
     regardless of SET FIXED.  A negative <nNumber> returns zero.

 Description

     SQRT() is a numeric function used anywhere in a numeric calculation to
     compute a square root (e.g., in an expression that calculates standard
     deviation).

 Examples

     .  These examples show various results of SQRT():

        SET DECIMALS TO 5
        //
        ? SQRT(2)                 // Result: 1.41421
        ? SQRT(4)                 // Result: 2.00000
        ? SQRT(4) ** 2            // Result: 4.00000
        ? SQRT(2) ** 2            // Result: 2.00000

 Files   Library is CLIPPER.LIB.


See Also: SET DECIMALS SET FIXED
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson