Browse Source

Add examples of scientific notation input to the manuals

signals
Gavin Howard 4 years ago
parent
commit
1d57db92d9
Signed by untrusted user who does not match committer: gavin
GPG Key ID: C08038BDF280D33E
  1. 2
      manuals/bc.1
  2. 5
      manuals/bc.1.ronn
  3. 2
      manuals/dc.1
  4. 5
      manuals/dc.1.ronn

2
manuals/bc.1

@ -182,7 +182,7 @@ In addition, if bc(1) was built with the extra math option, it accepts numbers i
Using scientific notation is an error or warning if the \fB\-s\fR or \fB\-w\fR, respectively, command\-line options (or equivalents) are given\.
.
.P
\fBWARNING\fR: Both the number and the exponent in scientific notation are interpreted according to the current \fBibase\fR, but the number is still multiplied by \fB10^exp\fR regardless of the current \fBibase\fR\.
\fBWARNING\fR: Both the number and the exponent in scientific notation are interpreted according to the current \fBibase\fR, but the number is still multiplied by \fB10^exponent\fR regardless of the current \fBibase\fR\. For example, if \fBibase\fR is \fB16\fR and bc(1) is given the number string \fB"FFeA"\fR, the resulting decimal number will be \fB2550000000000\fR, and if bc(1) is given the number string \fB"10e\-4"\fR, the resulting decimal number will be \fB0\.0016\fR\.
.
.P
Scientific notation is a non\-portable extension\.

5
manuals/bc.1.ronn

@ -190,7 +190,10 @@ respectively, command-line options (or equivalents) are given.
**WARNING**: Both the number and the exponent in scientific notation are
interpreted according to the current `ibase`, but the number is still multiplied
by `10^exp` regardless of the current `ibase`.
by `10^exponent` regardless of the current `ibase`. For example, if `ibase` is
`16` and bc(1) is given the number string `"FFeA"`, the resulting decimal number
will be `2550000000000`, and if bc(1) is given the number string `"10e-4"`, the
resulting decimal number will be `0.0016`.
Scientific notation is a non-portable extension.

2
manuals/dc.1

@ -63,7 +63,7 @@ Single\-character numbers (i\.e\., \fBA\fR) take the value that they would have
In addition, if dc(1) was built with the extra math option, it accepts numbers in scientific notation\. For dc(1), an example is \fB1\.89237e9\fR, which is equal to \fB1892370000\fR\. Negative exponents are also allowed, so \fB4\.2890e_3\fR is equal to \fB0\.0042890\fR\.
.
.P
\fBWARNING\fR: Both the number and the exponent in scientific notation are interpreted according to the current \fBibase\fR, but the number is still multiplied by \fB10^exp\fR regardless of the current \fBibase\fR\.
\fBWARNING\fR: Both the number and the exponent in scientific notation are interpreted according to the current \fBibase\fR, but the number is still multiplied by \fB10^exponent\fR regardless of the current \fBibase\fR\. For example, if \fBibase\fR is \fB16\fR and dc(1) is given the number string \fB"FFeA"\fR, the resulting decimal number will be \fB2550000000000\fR, and if dc(1) is given the number string \fB"10e_4"\fR, the resulting decimal number will be \fB0\.0016\fR\.
.
.P
Scientific notation is a non\-portable extension\.

5
manuals/dc.1.ronn

@ -90,7 +90,10 @@ in scientific notation. For dc(1), an example is `1.89237e9`, which is equal to
**WARNING**: Both the number and the exponent in scientific notation are
interpreted according to the current `ibase`, but the number is still multiplied
by `10^exp` regardless of the current `ibase`.
by `10^exponent` regardless of the current `ibase`. For example, if `ibase` is
`16` and dc(1) is given the number string `"FFeA"`, the resulting decimal number
will be `2550000000000`, and if dc(1) is given the number string `"10e_4"`, the
resulting decimal number will be `0.0016`.
Scientific notation is a non-portable extension.

Loading…
Cancel
Save