Liu Hui's π algorithm

Liu Hui's π algorithm

Liu Hui's π algorithm is a mathematical algorithm invented by Liu Hui (fl. 3rd century), a mathematician of Wei Kingdom. Before his time, the ratio of the circumference of a circle to diameter was often taken experimentally as 3 in China, while Zhang Heng (78–139) rendered it as 3.1724 (from the proportion of the celestial circle to the diameter of the earth, frac{736}{232}) or as pi=sqrt10=3.162. Liu Hui was not satisfied with pi=sqrt10; he commented that it was too large and overshot the mark. Another mathematician Wan Fan (219–257) provided pi= frac{142}{45}=3.156 [Schepler, Herman C. (1950), “The Chronology of PI”, Mathematics Magazine 23 (3): 165–170, ISSN 0025-570X] . All these empirical π values were accurate to 2 digits (ie. 1 decimal place). Liu Hui was the first Chinese mathematician to provide a rigorous algorithm for calculation of π to any accuracy. Liu Hui's own calculation with a 96-gon provided an accuracy of 5 digits: π ≈ 3.1416.

Liu Hui remarked in his commentary to the The Nine Chapters on the Mathematical Art [Needham, Volume 3, 66. ] , that the ratio of the circumference of an inscribed hexagon to the diameter of the circle was 3, hence π must be greater than 3. He went on to provide a detailed step-by-step description of an iterative algorithm to calculate π to any required accuracy based on bisecting polygons; he calculated π to between 3.141024 and 3.142708 with a 96-gon; he suggested that 3.14 was a good enough approximation, and expressed π as 157/50; he admitted that this number was a bit small. Later he invented an ingenious quick method to improve on it, and obtained π ≈ 3.1416 with only a 96-gon, with an accuracy comparable to that from a 1526-gon. His most important contribution in this area was his simple iterative π algorithm.

Area of a circle

Liu Hui argued:

"Multiply one side of a hexagon by radius, then multiply by 3, yields the area of dodecagon; if we cut a hexagon into dodecagon, mulitply its side with radius, then again multiply by 6, yields the area of 24-gon; the finer we cut the smaller the loss with respect to the area of circle, thus with further cut after cut, the area of the resulting polygon will coincide and become one with the circle, there will be no loss".

Apparently Liu Hui had already mastered the concept of limit [First noted by Japanese mathematician Yoshio Mikami] .: lim_{N o infty} area of N-gon longrightarrow area of circle.

Further, Liu Hui proved the area of circle = half of circumference multiplied by radius. He said

"Between a polygon and a circle, there are excess radius. Multiply the excess radius with a side of polygon. The resulting area exceeds the boundary of circle".

In the diagram "d" = excess radius. Multiplying "d" with one side results in oblong "ABCD" which exceeds the boundary of circle. If a side of polygon is so small (i.e. there is a very large number of sides) then there will be no more excess radius, hence no nore excess area.

As in the diagram, when "N" longrightarrowinfinity, "d" longrightarrow 0, and "ABCD" longrightarrow 0.

"Multiply a side of polygon with radius, the area doubles, hence multiply half circumference with radius, yields the area of circle"."

When "N" longrightarrow infinity, half the circumference of "N"-gon approaches a semicircle, thus half a circumference of circle multiply by radius longrightarrow area of circle.Liu Hui did not explain in detail this deduction. However this is self-evident by using Liu Hui's In-out complement principle he provided elsewhere in "The Nine Chapters on the Mathematical Art": Cut up a geometric diagram into parts, move the parts like a jigsaw puzzle around to form another diagram, the area of the two diagrams will be identical.

Thus move around the 6 green triangles 3 blue triangles and 3 red triangles into an oblong, with width = 3"L", and height "R",

:hence the area of dodecagon = 3 imes R imes L;

In general, multiplying half of the circumference of "N"-gon with radius yields area of 2"N"-gon. He used this result repetitively in his π algorithm.

Liu Hui's π inequality

Liu Hui went one step forward, and proved a π inequality with only one inscribed 2N polygon ::In the diagram, yellow area represents area of N-gonA_{N}:Yellow area+ green area represents area of 2N-gon:A_{2N}:Green area represents difference between 2N_gon and N-gon:D_{2N}=A_{2N}-A_{N}:Red area = green area = D_{2N}

(Yellow area+ green area )+ red area= A_{2N} + D_{2N}:Let C represents area of circle:Then :A_{2N} < C < A_{2N} + D_{2N}

:If radius of circle =1,:Liu Hui's π inequality:: A_{2N} < pi < A_{2N} + D_{2N}

Iterative algorithm

Lui Hui began with an inscribed hexagon. Let "M" be the length of one side "AB" of hexagon, "r" is the radius of circle.

Bisect "AB" with line "OPC", "AC" becomes one side of dodecagon, let its length be "m".

"AOP", "APC" are two right angle triangles. Liu Hui used Gou Gu theorem repetitively:

: {} G^2 = r^2 - left( frac{M}{2} ight)^2: {}G= sqrt{r^2- frac{M^2}{4: {} j= r - G = r - sqrt{r^2- frac{M^2}{4: {}m^2= left( frac{M}{2} ight)^2 + j^2: {}m=sqrt{m^2}

With "R" = 10 units, he obtained

: area of 96-gon {}A_{96} = 313 {584 over 625} : area of 192-gon {}A_{192}= 314 {64 over 625} : Difference of 192-gon and 96-gon:

:{}D_{192} = 314frac{64}{625} - 313frac{584}{625}=frac{105}{625}

:from Liu Hui's π inequality:

: A_{2N} < C < A_{2N} + D_{2N}

:Since r= 10, C = 100 imes pi:therefore::{}314frac{64}{625}<100 imes pi <314 frac{64}{625} +frac{105}{625}::{}314frac{64}{625}<100 imes pi <314 frac{169}{625}:{} 3.141024 < pi < 3.142704.

He never took π as the average of the lower limit 3.141024 and upper limit 3.142704. Instead he suggested that 3.14 was a good enough approximation for π , and expressed it as a fraction frac{157}{50}; he pointed out this number is slightly less then the real thing.

Liu Hui carried out his calculation with rod calculus, and expressed his results with fractions. However, the iterative nature of Liu Hui's π algorithm is quite clear:

: 2-m^2 =sqrt{2+(2-M^2)}, ,

in which "m" is the length of one side of next order polygon bisected from "M", then repeat the same calculation, each step required only one addition, one square root extraction.

Begin with m_{6}=M=1 for hexagon:

Length of one side of successive polygons:: {} m_{12} = sqrt{2- sqrt{2+1 : {} m_{24} = sqrt{2-sqrt{2+ sqrt{2+1} : {} m_{48} = sqrt{2-sqrt{2+sqrt{2+ sqrt{2+1 : {} m_{96} = sqrt{2-sqrt{2+sqrt{2+sqrt{2+ sqrt{2+1}

Area of successive polygons inscribed in a circle with radius=1.:{}piapprox A_{24} =m_{12}cdot 6 =sqrt{2- sqrt{2+1cdot 6 :{}piapprox A_{48} =m_{24}cdot 12 =sqrt{2-sqrt{2+ sqrt{2+1}cdot 12:{}piapprox A_{96} =m_{48}cdot 24 =sqrt{2-sqrt{2+sqrt{2+sqrt{2+1cdot24:{}piapprox A_{192} =m_{96}cdot 48 =sqrt{2-sqrt{2+sqrt{2+sqrt{2+sqrt{2+1}cdot 48

Liu Hui's π algorithm can be carried through to higher order polygons to any accuracy. However, an ordinary computer spreedsheet or table top calculator has only an accuracy of 15 digits, hence it is possible at most to calculate up to 49152-gon. For example: : egin{align}pi approx A_{3072} & {} = 768 sqrt{2 - sqrt{2 + sqrt{2 + sqrt{2 + sqrt{2 + sqrt{2 + sqrt{2 + sqrt{2 + sqrt{2+1} \& {} approx 3.141590463236763.end{align}

:pi approx A_{12288} approx 3.141592516588156:pi approx A_{49152} approx 3.141592645321216

However, with a high precision math package (accuracy up to 1000 digits), it is easy to calculate π to higher accuracy, for example:

:pi approx A_{786432} approx 3.1415926535892710:pi approx A_{25165824} approx 3.14159265358927911985288:pi approx A_{3221225472} approx 3.14159265358979323833813570721:pi approx A_{103079215104} approx 3.1415926535897932384625217937520959553073527937237595

With with 1000th iteration to 6*2^1000-gon, π can be calculated to 595 digits with Liu Hui's algorithm:

A_{6*21000}gon(6.4290516431 x10^301-gon)::pi approx :3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348:253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055:596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486:104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903:600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185:480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247:37190702179860943702770539217176293176752384674818467669

Quick method

Calculation of square roots of irrational numbers was not an easy task in the third century with
counting rods. Liu Hui discovered a short cut by comparing the area differentials of polygons, and found that the proportion of the difference in area of successive order polygons was approximately 1/4. [Yoshio Mikami: Ph.D. Dissertation 1932]

Let "D""N" denotes the difference in areas of "N"-gon and ("N"/2)-gon

: D_N = A_N - A_{N/2},

He found:

:D_{96} approx frac{1}{4} D_{48}

:D_{192} approx frac{1}{4} D_{96} fn|1

Hence:

:egin{align}D_{384} & {} approx frac{1}{4} D_{192} \D_{768} & {} approx left( frac{1}{4} ight)^2 D_{192} \D_{1536} & {} approx left( frac{1}{4} ight)^3 D_{192} \D_{3072} & {} approx left( frac{1}{4} ight)^4 D_{192} \& {} vdotsend{align}

Area of unit radius circle= {}pi = A_{192} + D_{384} + D_{768}+D_{1536}+D_{3072} + cdots approx A_{192} + F cdot D_{192}.

In which

: F = frac{1}{4} + left( frac{1}{4} ight)^2 + left( frac{1}{4} ight)^3 + left( frac{1}{4} ight)^4 + cdots = frac{1}{3}.

That is all the subsequent excess areas add up amount to one third of the D_{192}

: area of unit circle {}=pi approx A_{192} + left( frac{1}{3} ight)D_{192} approx {3927 over 1250} approx 3.1416.,fn|2

Liu Hui was quite happy with this result; he said he got the same result by calculation to 1536-gon and obtained the area of 3072-gon.

This explained four questions:

1) Why he stopped short at "A"192 in his presentation of his algorithm. Because he discovered a quick method of improving the accuracy of "π", achieving same result of 1536-gon with only 96-gon. After all calculation of square roots was not a simple task with rod calculus. With the quick method, he only needed to perform one more subtraction, one more division (by 3) and one more addition, instead of four more square root extractions.

2) Why he preferred to calculate "π" through calculation of areas instead of circumferences of successive polygons, because the quick method required information about the difference in areas of successive polygons.

3) Who was the true author of the paragraph containing calculation of

: pi = {3927 over 1250}.

That famous paragraph began with "A Han dynasty bronze container in the military warehouse of Jin dynasty....".

Many scholars, among them Yoshio Mikami and Joseph Needham, believed that the "Han dynasty bronze container" paragraph was the work of Liu Hui and not Zu Chongzhi as other believed, because of the strong correlation of the two methods through area calculation, and because there was not a single word mentioning Zu's 3.1415926 < π < 3.1415927 result obtained through 12288-gon.

Later developments

Liu Hui established a solid algorithm for calculation of π to any accuracy.
*Zu Chongzhi was familiar with Liu Hui's work, and obtained greater accuracy by applying his algorithm to a 12288-gon.

:From Liu Hui's formula for 2N-gon:: A_{2N} = m_{N} imes r:For 12288-gon inscribed in a unit radius circle:: A_{24576}=3.14159261864 < pi .

:From Liu Hui's π inequality:: A_{24576} < pi < A_{24576} +D_{24576}:In which D_{24576}=A_{24576}- A_{12288}=0.0000001021: A_{24576}=3.14159261864 < pi <3.14159261864 +0.0000001021.:Therefore:3.14159261864 < pi <3.141592706934Truncated to eight significant digits:: 3.1415926 < pi <3.1415927.That was the famous Zu Chongzhi π inequality.

Zu Chongzhi then used He Chengtian's interplolation formula and obtained an approximating fraction: pi approx {355 over 113}.
*Yuan dynasty mathematician Zhao Yu Xin worked on a variation of Liu Hui's π algorithm, by bisecting an inscribed square instead of a hexagon.

ignificance of Liu Hui's π algorithm

Liu Hui's π algorithm was one of his most important contributions to ancient Chinese mathematics. It was based on calculation of N-gon area, in contrast to the Archimedean algorithm based on polygon circumference. Archimedes used a circumscribed 96-gon to obtain an upper limit pi < frac{22}{7}=3.142857, and an inscribed 96-gon to obtain the lower limit frac{223}{71}=3.140845. Liu Hui was able to obtain both his upper limit 3.142704 and lower limit 3.141024 with only an inscribed 96-gon; furthermore, both the Liu Hui limits were tighter than Achimedes's:

: 3.140845 < 3.141024 .

Liu Hui's method was more elegant and intuitive. Using it, Zu Chongzhi obtained the result: 3.1415926 < pi <3.1415927, which held the world record for the most accurate value of π for one thousand years.

Notes

:fnb|1 Check with spreadsheet::D_{192}=0.0016817478:D_{96}=0.0067215898:D_{192} / D_{96}=0.2502009052 approxeq 0.25

:fnb|2 double check with spreadsheet::A_{192}= 3.1410319509:D_{192}=0.0016817478

:pi approx A_{192}+ frac{1}{3} D_{192}approxeq 3.1410319509 +0.0016817478/3

:pi approx 3.1410319509 +0.0005605826

:pi approx 3.1415925335. Off only 0.0000001201 with "Π". Liu Hui's quick method was indeed excellent, potentially able to deliver almost the same result of 12288-gon(3.141492516588) with only 96-gon.

References

*Needham, Joseph (1986). Science and Civilization in China: Volume 3, Mathematics and the Sciences of the Heavens and the Earth. Taipei: Caves Books, Ltd.

* Wu Wenjun ed, History of Chinese Mathematics Vol III (in Chinese) ISBN 7-303-04557-0/O


Wikimedia Foundation. 2010.

Игры ⚽ Поможем сделать НИР

Look at other dictionaries:

  • Liu Hui — (zh tsp|t=劉徽|s=刘徽|p=Liú Huī, fl. 3rd century) was a Chinese mathematician who lived in the Wei Kingdom. In 263 he edited and published a book with solutions to mathematical problems presented in the famous Chinese book of mathematics known as The …   Wikipedia

  • Liu Hui — ▪ Chinese mathematician flourished c. 263 CE, China       Chinese mathematician.       All that is known about the life of Liu Hui is that he lived in the northern Wei kingdom (see Three Kingdoms) during the 3rd century CE. His fame rests on the… …   Universalium

  • Chinese mathematics — Mathematics in China emerged independently by the 11th century BC.[1] The Chinese independently developed very large and negative numbers, decimals, a place value decimal system, a binary system, algebra, geometry, and trigonometry. Many[who?]… …   Wikipedia

  • 3,14 — Pi Pour les articles homonymes, voir Pi (homonymie) …   Wikipédia en Français

  • 3.14 — Pi Pour les articles homonymes, voir Pi (homonymie) …   Wikipédia en Français

  • Le nombre pi — Pi Pour les articles homonymes, voir Pi (homonymie) …   Wikipédia en Français

  • Nombre Pi — Pi Pour les articles homonymes, voir Pi (homonymie) …   Wikipédia en Français

  • Pi (nombre) — Pi Pour les articles homonymes, voir Pi (homonymie) …   Wikipédia en Français

  • Π (nombre) — Pi Pour les articles homonymes, voir Pi (homonymie) …   Wikipédia en Français

  • List of topics related to π — Part of a series of articles on the mathematical constant π …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”