Jiuzhang Suanshu Chapter 9 - Gou Gu

**Translation and explanatory notes by Tao Steven Zheng (鄭濤)**

**劉徽注**
[1] 以御高深廣遠。

**Liu Hui's Commentary**
[1] To determine heights, depths, widths, and distances.

## **Problems 9.01 - 9.03**

荅曰：五尺。
〔二〕今有弦五尺，句三尺，問︰為股幾何？

荅曰：四尺。
〔三〕今有股四尺，弦五尺，問︰為句幾何？

荅曰：三尺。
句股術曰[1]：句股各自乘，並，而開方除之，即弦。[2]

又，股自乘，以減弦自乘，其餘，開方除之，即句。[3]

又，句自乘，以減弦自乘，其餘，開方除之，即股。[4]

**劉徽注**
[1] 短面曰句，長面曰股，相與結角曰弦。句短其股，股短其弦。將以施於諸率，故先具此術以見其原也。

[2] 句自乘為朱方，股自乘為青方。今出入相補，各從其類，因就其餘不移動也，合成弦方之冪。開方除之，即弦也。

[4] 按：句、股冪合以成弦冪，今去其一，則餘者皆可得而知之。
**李淳風注**
[3] 臣淳風等謹按：此術以句、股冪合成弦冪。句方於內，即句短於股。令股自乘，以減弦自乘，餘者即句冪也。故開方除之，即句也。

Answer: 5 *chi*.
[9.02] Suppose the *xian* is 5 *chi* and the *gou* is 3 *chi*. Question: What is [the length of] the *gu*?

Answer: 4 *chi*.
[9.03] Suppose the *gu* is 4 *chi* and the *xian* is 5 *chi*. Question: What is [the length of] the *gou*?

Answer: 3 *chi*.
*Gou gu* method (句股術 *gou gu shu*) [1]: Square each the *gou* and the *gu*, then add them. Extracting the square root [of the sum] gives the *xian*. [2]

Also, take the *gu* squared and subtract it from the the *xian* squared. Extracting the square root of the remainder (餘 *yu*) gives the *gou*. [3]

Also, take the *gou* squared and subtract it from the the *xian* squared. Extracting the square root of the remainder gives the *gu*. [4]

**Liu Hui's Commentary**
[1] The short side is called *gou*, the long side is called *gu*, and the side that forms angles [with the *gou* and *gu*] is called the *xian*. The *gou* is shorter than *gu*, and the *gu* is shorter than the *xian*. Since these [three quantities] apply to all the rates [in this chapter]; hence, this method is explicated at the beginning.

[2] Let *gou* squared be the vermillion square (朱方 *zhu fang*), and let *gu* squared be the cyan square (青方 *qing fang*). The outside and inside parts complement each other (出入相補 *chu ru xiang bu*) according to its shape (類 *lei*). Because the other parts do not move, together combine to form the *xian* square. Extract the square root gives the *xian*.

[4] The areas of the *gou* [square] and the *gu* [square] is area of the *xian* [square]. If one of them is missing, the remaining one can be determined from the rest.
**Li Chunfeng's Commentary**
[3] Li Chunfeng and associates comment: This method uses the fact that the areas (冪 *mi*) of the *gou* square and *gu* square together comprise the area of the *xian* square. The *gou* square is inside the *gu* square because the *gou* is less than the *gu*. Subtracting the *gu* squared from the *xian* squared gives the area of the *gou* square. Thus, extracting the square root gives the *gou*.

### **Explanatory Notes**

**Terminology**

(1) 句股 gōu gǔ: In the Chinese mathematical tradition, the right triangle is called *gou gu* (句股) . *Gou* (句, "hook") and *gu* (股, "thigh") refers to the two perpendicular sides of a right triangle, where the *gou* is always shorter than the *gu*. The hypotenuse of the right triangle is called *xian* (弦, "chord").

(2) 自乘 zì chéng: This term literally translates to "self-multiply", which is equivalent to squaring a number.

(3) 餘 yú: This term literally translates to "remainder" as a result of subtraction.

**Principles**

(1) Chinese astronomers and mathematicians were aware of the *gou gu* method (Pythagorean theorem) possibly as early as 1000 BC. The earliest exposition of this theorem is found in Chapter 1 of the *Zhoubi Suanjing*, which details the conversation between the Duke of Zhou (周公, fl. 11th century BC) and his chief astronomer Shang Gao（商高, fl. 11th century BC). The *Jiuzhang Suanshu* presents the *gou gu* method as three separate formulas:

c

=

a
2

b
2

a

=

c
2

−

b
2

b

=

c
2

−

a
2

{\displaystyle \begin{align}
c &= \sqrt{a^2 + b^2} \\
a &= \sqrt{c^2 - b^2} \\
b &= \sqrt{c^2 - a^2} \\

\end{align}}

where

a
,
b
,
c

{\displaystyle a,b,c}

denotes the *gou*, *gu*, and *xian* respectively.

(2) Liu Hui describes his proof of the *gou gu* method in words by applying the “out-in complementary principle" (Figure 1). Liu Hui's proof begins with two squares: the vermillion square (朱方 *zhu fang*) formed by squaring the *gou*, and the cyan square (青方 *qing fang*) formed by squaring the *gu*. A third square, with its side being the *xian*, cuts the vermillion square and cyan square. The fragments of the vermillion square and cyan square outside the *xian* square are used to fill in the congruent areas within the *xian* square that are external to both the vermillion square and cyan square.

**Solutions**

For the following solutions, let

a

{\displaystyle a}

be the *gou*,

b

{\displaystyle b}

be the *gu*, and

c

{\displaystyle c}

be the *xian*.

[9.01]

c

=

a
2

b
2

=

3
2

4
2

=
5

{\displaystyle \begin{align}
c &= \sqrt{a^2 + b^2} \\
&= \sqrt{3^2 + 4^2} \\
&= 5
\end{align}}

[9.02]

b

=

c
2

−

a
2

=

5
2

−

3
2

=
4

{\displaystyle \begin{align}
b &= \sqrt{c^2 - a^2} \\
&= \sqrt{5^2 - 3^2} \\
&= 4 \\

\end{align}}

[9.03]

a

=

c
2

−

b
2

=

5
2

−

4
2

=
3

{\displaystyle \begin{align}
a &= \sqrt{c^2 - b^2} \\
&= \sqrt{5^2 - 4^2} \\
&= 3 \\

\end{align}}

## **Problem 9.04**

荅曰：二尺四寸。
術曰：令徑二尺五寸自乘，以七寸自乘減之，其餘，開方除之，即廣。[1]

**劉徽注**
[1] 此以圓徑二尺五寸為弦，版厚七寸為句，所求廣為股也。
Answer: *2 chi* 4 *cun*.
Method: Let the diameter be 2 *chi* 5 *cun* and square it, then subtract the square of 7 *cun* from it. Extract the square root of the remainder gives the width. [1]

**Liu Hui's Commentary**
[1] Here, take the diameter 2 *chi* 5 *cun* as the *xian*, the thickness of the plank 7 *cun* as the *gou*, and the width to be found as the *gu*.

### **Explanatory Notes**

**Terminology**

(1) 長 cháng: This term means "long", however, since the tree in problem [9.04] is vertical, 長 refers to the height.

**Principles**

**Solutions**

For the following solutions, let

a

{\displaystyle a}

be the *gou*,

b

{\displaystyle b}

be the *gu*, and

c

{\displaystyle c}

be the *xian*.

[9.04]

Figure 2 shows the cross-section of the circular log. According to the problem, the diameter of the circle is 2 *chi* 5 *cun*, or 25 *cun*. The thickness of the plank to be made is 7 *cun*.

Hence,

b

=

c
2

−

a
2

=

25
2

−

7
2

=
24

{\displaystyle \begin{align}
b &= \sqrt{c^2 - a^2} \\
&= \sqrt{25^2 - 7^2} \\
&= 24 \\

\end{align}}

 Since 1 *zhang* equals 10 *chi*, it thus follows that 24 *chi* is equal to 2 *zhang* 4 *chi*. Therefore, the width of the plank is 2 *zhang* 9 *chi*.

## **Problem 9.05**

荅曰：二丈九尺。
術曰：以七周乘三尺為股，木長為句，為之求弦。弦者，葛之長。[1]

**劉徽注**
[1] 據圍廣，求從為木長者其形葛卷裹袤。以筆管青線宛轉，有似葛之纏木。

解而觀之，則每周之間自有相間成句股弦。則其間葛長，弦。七周乘圍，並合眾 句以為一句；木長而股，短，術雲木長謂之股，言之倒。句與股求弦，亦無圍。

弦之自乘冪出上第一圖。句、股冪合為弦冪，明矣。然二冪之數謂倒在於弦冪之中而已。可更相表裡，居里者則成方冪，其居表者則成矩冪。二表裡形訛而數均。

又按：此圖句冪之矩青，卷白表，是其冪以股弦差為廣，股弦並為袤，而股冪方其里。股冪之矩青，卷白表，是其冪以句弦差為廣，句弦並為袤，而句冪方其里。

是故差之與並，用除之，短、長互相乘也。

Answer: 2 *zhang* 9 *chi*.

Method: Let 7 coils multiplied by the circumference 3 *chi* be the *gu*, let the height of the tree be *gou*, and determine the corresponding *xian*. The *xian* is length of the vine. [1]
**Liu Hui's Commentary**
[1] Use the circumference as the width, and height of the tree as the length, to obtain the length of the vine wrapped around the tree. Take a cyan string and wind it around a pen, this resembles the vine coiling up the tree.

Straighten [the string] and observing this, it is clear that between each coil there is a *gou*, *gu*, and *xian*. Thus, the space between them is the length of the vine, the *xian*. Multiply the 7 coils by the circumference means combining all *gou* into one [large] *gou*; the height of the tree is the *gu*, which is shorter [than the *gou*]. The method says that the height of the tree is the *gu*, but saying this reverses the [*gou* and the *gu*]. Then use the *gou* and *gu* to to find the *xian*, as if there are no coils.

The area (冪 *mi*) formed by squaring the *xian* is shown in the first diagram above. It is obvious that the combined areas of the *gou* [square] and the *gu* [square] is the *xian* [square]. Thus, the quantitative values (數 *shu*) of the two areas are said to be inside the *xian* area. Each can mutually change into either the interior or on the exterior. If put in the interior, it is a square area (方冪 *fang mi*); if put on the exterior it becomes a gnomon area (矩冪 *ju mi*). Each case differs in shape but the quantitative values [of the areas] are the same.

Another comment: In the diagram, the cyan gnomon, whose area is equal to the square on *gou*, extends around the area of the white [area of the *gu*]. its area is equal to the area [of a rectangle] the with *gu-xian* difference as the width, the length the *gu-xian* sum as the length, and the *gu* square placed in the interior. If the cyan gnomon, whose area is equal to the *gu* square, is placed in the exterior, its area is also equal to a rectangle with the *gou-xian* difference as the width, the length the *gou-xian* sum as the length, and the *gou* square placed in the interior.

Hence, the differences and sums are used to divide, and the shorter and longer lengths are multiplied together.

### **Explanatory Notes**

**Terminology**

   **Principles**
(1) Liu Hui illustrates four formulas using the square-gnomon diagram. According his commentary, the area of the cyan gnomon surrounding the *gu* square is equal to the area of the *gou* square. This is equivalent to the equation

a
2

=
c
(
c
−
b
)
b
(
c
−
b
# )
(
c
b
)
(
c
−
b
)

{\displaystyle a^2 = c(c-b) + b(c-b) = (c+b)(c-b)}

, where

c
b

{\displaystyle c+b}

is the *gu-xian* sum and

c
−
b

{\displaystyle c-b}

is the *gu-xian* difference.

c
−
# a

(
c
−
a
)
(
c
a
)

c
a

=

c
2

−

a
2

c
a

c
# a

(
c
−
a
)
(
c
a
)

c
−
a

=

c
2

−

a
2

c
−
a

c
−
# b

(
c
−
b
)
(
c
b
)

c
b

=

c
2

−

b
2

c
b

c
# b

(
c
−
b
)
(
c
b
)

c
−
b

=

c
2

−

b
2

c
−
b

{\displaystyle \begin{align}
c-a = \frac{(c-a)(c+a)}{c+a} = \frac{c^2-a^2}{c+a}\\[5 pt]
c+a = \frac{(c-a)(c+a)}{c-a} = \frac{c^2-a^2}{c-a}\\[5 pt]
c-b = \frac{(c-b)(c+b)}{c+b} = \frac{c^2-b^2}{c+b}\\[5 pt]
c+b = \frac{(c-b)(c+b)}{c-b} = \frac{c^2-b^2}{c-b}
\end{align}}

[9.05] This problem uses the *gou gu* method (Pythagorean theorem) to compute the length of a helical vine. As shown in the Figure 3, let

a

{\displaystyle a}

 be the height of the tree,

b

{\displaystyle b}

 be the circumference of the tree multiplied by the number of coils of the tree, and

c

{\displaystyle c}

 be the length of the vine. It is known that the height of the tree is 2 *zhang*, or 20 *chi*. The base of the right triangle is 7 times the circumference of the tree. Since the circumference of the tree is 3 *chi*, the base is 21 *chi*. When unwound, the length of the vine is the hypotenuse of the right triangle.

Hence,

c

=

a

2

b

2

=

20

2

21

2

=
29

{\displaystyle
\begin{align}
c &= \sqrt{{a}^{2} + {b}^{2}} \\
 &= \sqrt{{20}^{2} + {21}^{2}} \\
 &= 29
\end{align}
}

Since 1 *zhang* equals 10 *chi*, it thus follows that 29 *chi* is equal to 2 *zhang* 9 *chi*. Therefore, the vine measures 2 *zhang* 9 *chi* in length.

## **Problem 9.06**

荅曰：水深一丈二尺；葭長一丈三尺。
術曰：半池方自乘，[1] 以出水一尺自乘，減之，[2] 餘，倍出水除之，即得水深。[3] 加出水數，得葭長。[4]

**劉徽注**
[1] 此以池方半之，得五尺為句，水深為股，葭長為弦。以句、弦見股，故令句自乘，先見矩冪也。

[2] 出水者，股弦差。減此差冪於矩冪則除之。

[3] 差為矩冪之廣，水深是股。令此冪得出水一尺為長，故為矩而得葭長也。
**李淳風注**
[4] 臣淳風等謹按：此葭本出水一尺，既見水深，故加出水尺數而得葭長也。

Answer: the depth of the water is 1 *zhang* 2 *chi*; the length of the reed is 1 *zhang* 3 *chi*.

Method: Square half the side of the pond, [1] and subtract the square of 1 chi, the height above the water. [2] Divide the remainder by double the height above the water to get the depth of the water. [3] Add the height above the water [to the result] to obtain the length of the reed.
**Liu Hui's Commentary**
[1] Here take half the side of the pond, 5 chi, as the *gou*, the depth of the water as the *gu*, and the length of the reed as the *xian*. Use the *gou* and the *xian* to find the *gu*. Therefore, square the *gou* to get the area of the gnomon (矩冪 *ju mi*).
[2] The height above the water is the difference between gu and the hypotenuse. Subtract the square of this difference from that of the area of the gnomon; take the remainder.
[3] Let the difference between the width of the gnomon and the depth of the water be gu. Therefore construct [a rectangle] with a width of 2 chi, twice the height above the water. Its length is the depth of water to be found.
**Li Chunfeng's Commentary**
[4]

### **Explanatory Notes**

**Terminology**

**Principles**

**Solutions**

## **Problem 9.07**

　　术曰：以去本自乘， 〔此以去本八尺为句，所求索者，弦也。引而索尽、开门去阃者，句及股弦 差，同一术。去本自乘者，先张矩幂。〕 令如委数而一。
　　〔委地者，股弦差也。以除矩幂，即是股弦并也。〕 所得，加委地数而半之，即索长。
　　〔子不可半者，倍其母。加差者并，则两长。故又半之。其减差者并，而半 之，得木长也。〕

**劉徽注**
[1] 按：此以池方半之，得五尺为句；水深为股；葭长为弦。以句、弦见股，故令 句自乘，先见矩幂也。

[2] 出水者，股弦差。减此差幂于矩幂则除之。

[3] 差为矩幂之广，水深是股。令此幂得出水一尺为长，故为矩而得葭长也。

[4] 淳风等按：此葭本出水一尺，既见水深，故加出水尺数而得葭长也。

Answer: 1 zhang 2 1 6 chi.
Method: Square the distance from the foot,L1 divide by the length of the end lying on the ground,L2 add the result to the length of the end. Halve it, giving the length of the rope.L3**Liu Hui's Commentary**
[1] L1: Here consider the distance from the foot, 8 chi, as gou, the length of the string as the hypotenuse. The Problem of “the string tightly stretched” is the same type as that of “the gate away from the threshold”, i.e. given the gou and the difference between gu and the hypotenuse, find gu and the hypotenuse. Square the distance to get the area of the gnomon. L2: The end of the string lying on the ground is the difference between the hypotenuse and gu; take it to divide the area of the gnomon to obtain the sum of the hypotenuse and the gu. L3: If the numerator cannot be halved, double the denominator. The sum added to the difference is twice the length of the string. So halve the result. Subtract the difference from the sum and halve it to get the height of the pole.

### **Explanatory Notes**

**Terminology**

**Principles**

**Solutions**