Anonymous user
Numerical integration/Gauss-Legendre Quadrature: Difference between revisions
Numerical integration/Gauss-Legendre Quadrature (view source)
Revision as of 01:18, 7 April 2016
, 8 years ago→version 2: changed the wording in the REXX section header.
m (→version 2: changed the comments in the REXX section header.) |
m (→version 2: changed the wording in the REXX section header.) |
||
Line 1,627:
:::* displays the number of decimal digits that match the exact value
<br>The execution speed of this REXX program is largely dependent on the number of decimal digits in '''pi'''. <br>If faster speed is desired, the number of the decimal digits of
The use of "vertical bars" is one of the very few times to use leading comments, as there isn't that many
<br>situations where there exists nested '''do''' loops with different (grouped) sizable indentations, and
<br>where there's practically no space on the right side of the REXX source statements. It presents a good
<br>
<lang rexx>/*REXX program does numerical integration using an N-point Gauss─Legendre quadrature rule. */
pi=pi(); digs=length(pi)-1; numeric digits digs; reps=digs%2
|