Directives 

FLOATINGPOINT

Switch to Scientific Notation

Format

FLOATINGPOINT

Description

Use the FLOATINGPOINT directive to have PxPlus start using scientific notation with all numeric data. In scientific notation, a number is represented as a fraction times 10 to some power (e.g. .nnnnn*10^xx is displayed as .nnnnnExx).

In FLOATINGPOINT mode, no rounding is done on numeric calculations. If the numeric output is unformatted, PxPlus uses scientific notation (e.g. .314159E+01). Use the PRECISION directive to end FLOATINGPOINT mode.

Note:
FLOATINGPOINT notation is reset to standard decimal notation during a RESET operation; however, prior to version 5, it was left On.

See Also

BEGIN Reset Files and Variables
CLEAR Reset Variables
PRC Precision Currently in Effect
PRC( ) Round Number to Precision
PRECISION Change Current Precision
RESET Reset Program State

Example

floating point
A=5/3
print A

->run
.166666666666667E+01

precision 2 ! Sets precision to two
round on ! Sets rounding default mode
A=5/3
floating point
print A

->run
.167E+01