PRECISION INDEX

PRECISION _ _ _ _ _ _ _ _ _ _ _ _ declaration

The precision declaration sets the number of decimal places used when rounded is on. Default is system dependent, and normal ly about 12.

syntax:

precision(<integer>) or precision <integer>

<integer> must be a positive integer. When <integer> is 0, the current precision is displayed, but not changed. There is no upper limit, but precision of greater than several hundred causes unpleasantly slow operation on numeric calculations.

examples:


on rounded; 

7/9; 

  0.777777777778 


precision 20; 

  20 


7/9; 

  0.77777777777777777778 


sin(pi/4); 

  0.7071067811865475244

Trailing zeroes are dropped, so sometimes fewer than 20 decimal pl aces are printed as in the last example. Turn on the switch fullprec if you want to print all significant digits. The rounded mode carries calculations to two more places than given by precision, and rounds off.