# Pythagorean theorem

Pythagorean theorem Pythagorean theorem Type Theorem Field Euclidean geometry Statement The sum of the areas of the two squares on the legs (a and b) equals the area of the square on the hypotenuse (c). Symbolic statement {style d'affichage a^{2}+b^{2}=c^{2}} Generalizations Law of cosines Solid geometry Non-Euclidean geometry Differential geometry Consequences Pythagorean triple Reciprocal Pythagorean theorem Complex number Euclidean distance Pythagorean trigonometric identity Geometry Projecting a sphere to a plane OutlineHistory show Branches hide ConceptsFeatures Dimension Straightedge and compass constructions AngleCurveDiagonalOrthogonality (Perpendicular)ParallelVertex CongruenceSimilaritySymmetry show Zero-dimensional show One-dimensional show Two-dimensional show Three-dimensional show Four- / other-dimensional Geometers show by name show by period vte In mathematics, the Pythagorean theorem, or Pythagoras' theorem, is a fundamental relation in Euclidean geometry among the three sides of a right triangle. It states that the area of the square whose side is the hypotenuse (the side opposite the right angle) is equal to the sum of the areas of the squares on the other two sides. This theorem can be written as an equation relating the lengths of the legs a, b and the hypotenuse c, often called the Pythagorean equation:[1] {style d'affichage a^{2}+b^{2}=c^{2},} The theorem is named for the Greek philosopher Pythagoras, born around 570 avant JC. Although it was attributed to him in classical antiquity, there is evidence that aspects of the theorem were known in earlier cultures; modern scholarship has also questioned whether Pythagoras himself was aware of it. The theorem has been proven numerous times by many different methods – possibly the most for any mathematical theorem. The proofs are diverse, including both geometric proofs and algebraic proofs, with some dating back thousands of years.

The theorem can be generalized in various ways: to higher-dimensional spaces, to spaces that are not Euclidean, to objects that are not right triangles, and to objects that are not triangles at all but n-dimensional solids. The Pythagorean theorem has attracted interest outside mathematics as a symbol of mathematical abstruseness, mystique, or intellectual power; popular references in literature, plays, musicals, songs, stamps, and cartoons abound.

Contenu 1 Other forms of the theorem 2 Proofs using constructed squares 2.1 Rearrangement proofs 2.2 Algebraic proofs 3 Other proofs of the theorem 3.1 Proof using similar triangles 3.2 Euclid's proof 3.3 Proofs by dissection and rearrangement 3.4 Einstein's proof by dissection without rearrangement 3.5 Proof by area-preserving shearing 3.6 Algebraic proofs 3.7 Proof using differentials 4 Converser 5 Consequences and uses of the theorem 5.1 Pythagorean triples 5.2 Inverse Pythagorean theorem 5.3 Incommensurable lengths 5.4 Complex numbers 5.5 Euclidean distance 5.6 Euclidean distance in other coordinate systems 5.7 Pythagorean trigonometric identity 5.8 Relation to the cross product 6 Généralisations 6.1 Similar figures on the three sides 6.2 Law of cosines 6.3 Arbitrary triangle 6.4 General triangles using parallelograms 6.5 Solid geometry 6.6 Inner product spaces 6.7 Sets of m-dimensional objects in n-dimensional space 6.8 Non-Euclidean geometry 6.8.1 Spherical geometry 6.8.2 Hyperbolic geometry 6.8.3 Very small triangles 6.9 Géométrie différentielle 7 Histoire 8 Voir également 9 Notes and references 9.1 Remarques 9.2 Références 9.3 Works cited 10 External links Other forms of the theorem If c denotes the length of the hypotenuse and a and b denote the two lengths of the legs of a right triangle, then the Pythagorean theorem can be expressed as the Pythagorean equation: {style d'affichage a^{2}+b^{2}=c^{2}.} If only the lengths of the legs of the right triangle are known but not the hypotenuse, then the length of the hypotenuse can be calculated with the equation {displaystyle c={sqrt {un ^{2}+b^{2}}}.} If the length of the hypotenuse and of one leg is known, then the length of the other leg can be calculated as {displaystyle a={sqrt {c^{2}-b^{2}}}} ou {displaystyle b={sqrt {c^{2}-un ^{2}}}.} A generalization of this theorem is the law of cosines, which allows the computation of the length of any side of any triangle, given the lengths of the other two sides and the angle between them. If the angle between the other sides is a right angle, the law of cosines reduces to the Pythagorean equation.

Proofs using constructed squares Rearrangement proof of the Pythagorean theorem. Rearrangement proofs In one rearrangement proof, two squares are used whose sides have a measure of {displaystyle a+b} and which contain four right triangle whose sides are a, b and c, with c being the hypotenuse. In the first square, the triangles are placed such that the corners of the square correspond to the corners of the right angle in the triangles, forming a square in the center whose sides are length c. Each square has an area of both {style d'affichage (a+b)^{2}} et {displaystyle 2ab+c^{2}} , avec {displaystyle 2ab} representing the area of the four triangles. In the second square, la 4 triangles are formed into two rectangles with sides lengths a and b and placed such that a square of side length a is formed in one corner and a square of b is formed in the other. The second square will have a area of {style d'affichage (a+b)^{2}} et {displaystyle 2ab+a^{2}+b^{2}} . Since both squares have the area of {style d'affichage (a+b)^{2}} it follows that the other measure of the square area also equal each other such that {displaystyle 2ab+c^{2}} = {displaystyle 2ab+a^{2}+b^{2}} . With the area of the four triangles removed from both side of the equation what remains is {style d'affichage a^{2}+b^{2}=c^{2}.} [2] In another proof rectangles in the second box can also be placed such that both have one corner that correspond to consecutive corners of the square. In this way they also form two boxes, this time in consecutive corners, with areas {style d'affichage a^{2}} et {style d'affichage b^{2}} which will again lead to a second square of with the area {displaystyle 2ab+a^{2}+b^{2}} .

English mathematician Sir Thomas Heath gives this proof in his commentary on Proposition I.47 in Euclid's Elements, and mentions the proposals of German mathematicians Carl Anton Bretschneider and Hermann Hankel that Pythagoras may have known this proof. Heath himself favors a different proposal for a Pythagorean proof, but acknowledges from the outset of his discussion "that the Greek literature which we possess belonging to the first five centuries after Pythagoras contains no statement specifying this or any other particular great geometric discovery to him."[3] Recent scholarship has cast increasing doubt on any sort of role for Pythagoras as a creator of mathematics, although debate about this continues.[4] Algebraic proofs The theorem can be proved algebraically using four copies of the same triangle arranged symmetrically around a square with side c, as shown in the lower part of the diagram.[5] This results in a larger square, with side a + b and area (un + b)2. The four triangles and the square side c must have the same area as the larger square, {style d'affichage (b+a)^{2}=c^{2}+4{frac {un B}{2}}=c^{2}+2un B,} giving {displaystyle c^{2}=(b+a)^{2}-2ab=b^{2}+2ab+a^{2}-2ab=a^{2}+b^{2}.} A similar proof uses four copies of a right triangle with sides a, b and c, arranged inside a square with side c as in the top half of the diagram.[6] The triangles are similar with area {style d'affichage {tfrac {1}{2}}un B} , while the small square has side b − a and area (b − a)2. The area of the large square is therefore {style d'affichage (b-a)^{2}+4{frac {un B}{2}}=(b-a)^{2}+2ab=b^{2}-2ab+a^{2}+2ab=a^{2}+b^{2}.} But this is a square with side c and area c2, alors {displaystyle c^{2}=un^{2}+b^{2}.} Other proofs of the theorem This theorem may have more known proofs than any other (the law of quadratic reciprocity being another contender for that distinction); the book The Pythagorean Proposition contains 370 proofs.[7] Proof using similar triangles Proof using similar triangles This proof is based on the proportionality of the sides of three similar triangles, C'est, upon the fact that the ratio of any two corresponding sides of similar triangles is the same regardless of the size of the triangles.

Let ABC represent a right triangle, with the right angle located at C, as shown on the figure. Draw the altitude from point C, and call H its intersection with the side AB. Point H divides the length of the hypotenuse c into parts d and e. The new triangle, ACH, is similar to triangle ABC, because they both have a right angle (by definition of the altitude), and they share the angle at A, meaning that the third angle will be the same in both triangles as well, marked as θ in the figure. By a similar reasoning, the triangle CBH is also similar to ABC. The proof of similarity of the triangles requires the triangle postulate: The sum of the angles in a triangle is two right angles, and is equivalent to the parallel postulate. Similarity of the triangles leads to the equality of ratios of corresponding sides: {style d'affichage {frac {avant JC}{UN B}}={frac {BH}{avant JC}}{texte{ et }}{frac {CA}{UN B}}={frac {Ah}{CA}}.} The first result equates the cosines of the angles θ, whereas the second result equates their sines.

These ratios can be written as {displaystyle BC^{2}=ABtimes BH{texte{ et }}AC^{2}=ABtimes AH.} Summing these two equalities results in {displaystyle BC^{2}+AC^{2}=ABtimes BH+ABtimes AH=AB(AH+BH)=AB^{2},} qui, after simplification, demonstrates the Pythagorean theorem: {displaystyle BC^{2}+AC^{2}=AB^{2}.} The role of this proof in history is the subject of much speculation. The underlying question is why Euclid did not use this proof, but invented another. One conjecture is that the proof by similar triangles involved a theory of proportions, a topic not discussed until later in the Elements, and that the theory of proportions needed further development at that time.[8][9] Euclid's proof Proof in Euclid's Elements In outline, here is how the proof in Euclid's Elements proceeds. The large square is divided into a left and right rectangle. A triangle is constructed that has half the area of the left rectangle. Then another triangle is constructed that has half the area of the square on the left-most side. These two triangles are shown to be congruent, proving this square has the same area as the left rectangle. This argument is followed by a similar version for the right rectangle and the remaining square. Putting the two rectangles together to reform the square on the hypotenuse, its area is the same as the sum of the area of the other two squares. The details follow.

Soit A, B, C be the vertices of a right triangle, with a right angle at A. Drop a perpendicular from A to the side opposite the hypotenuse in the square on the hypotenuse. That line divides the square on the hypotenuse into two rectangles, each having the same area as one of the two squares on the legs.

For the formal proof, we require four elementary lemmata: If two triangles have two sides of the one equal to two sides of the other, each to each, and the angles included by those sides equal, then the triangles are congruent (side-angle-side). The area of a triangle is half the area of any parallelogram on the same base and having the same altitude. The area of a rectangle is equal to the product of two adjacent sides. The area of a square is equal to the product of two of its sides (follows from 3).

Prochain, each top square is related to a triangle congruent with another triangle related in turn to one of two rectangles making up the lower square.[10] Illustration including the new lines Showing the two congruent triangles of half the area of rectangle BDLK and square BAGF The proof is as follows: Let ACB be a right-angled triangle with right angle CAB. On each of the sides BC, UN B, and CA, squares are drawn, CBDE, BAGF, and ACIH, in that order. The construction of squares requires the immediately preceding theorems in Euclid, and depends upon the parallel postulate.[11] From A, draw a line parallel to BD and CE. It will perpendicularly intersect BC and DE at K and L, respectivement. Join CF and AD, to form the triangles BCF and BDA. Angles CAB and BAG are both right angles; therefore C, UN, and G are collinear. Angles CBD and FBA are both right angles; therefore angle ABD equals angle FBC, since both are the sum of a right angle and angle ABC. Since AB is equal to FB, BD is equal to BC and angle ABD equals angle FBC, triangle ABD must be congruent to triangle FBC. Since A-K-L is a straight line, parallel to BD, then rectangle BDLK has twice the area of triangle ABD because they share the base BD and have the same altitude BK, c'est à dire., a line normal to their common base, connecting the parallel lines BD and AL. (lemma 2) Since C is collinear with A and G, and this line is parallel to FB, then square BAGF must be twice in area to triangle FBC. Par conséquent, rectangle BDLK must have the same area as square BAGF = AB2. By applying steps 3 à 10 to the other side of the figure, it can be similarly shown that rectangle CKLE must have the same area as square ACIH = AC2. Adding these two results, AB2 + AC2 = BD × BK + KL × KC Since BD = KL, BD × BK + KL × KC = BD(BK + KC) = BD × BC Therefore, AB2 + AC2 = BC2, since CBDE is a square.

This proof, which appears in Euclid's Elements as that of Proposition 47 dans le livre 1, demonstrates that the area of the square on the hypotenuse is the sum of the areas of the other two squares.[12][13] This is quite distinct from the proof by similarity of triangles, which is conjectured to be the proof that Pythagoras used.[9][14] Proofs by dissection and rearrangement Another by rearrangement is given by the middle animation. A large square is formed with area c2, from four identical right triangles with sides a, b and c, fitted around a small central square. Then two rectangles are formed with sides a and b by moving the triangles. Combining the smaller square with these rectangles produces two squares of areas a2 and b2, which must have the same area as the initial large square.[15] Diagram of the two algebraic proofs The third, rightmost image also gives a proof. The upper two squares are divided as shown by the blue and green shading, into pieces that when rearranged can be made to fit in the lower square on the hypotenuse – or conversely the large square can be divided as shown into pieces that fill the other two. This way of cutting one figure into pieces and rearranging them to get another figure is called dissection. This shows the area of the large square equals that of the two smaller ones.[16] Animation showing proof by rearrangement of four identical right triangles Animation showing another proof by rearrangement Proof using an elaborate rearrangement Einstein's proof by dissection without rearrangement Right triangle on the hypotenuse dissected into two similar right triangles on the legs, according to Einstein's proof Albert Einstein gave a proof by dissection in which the pieces do not need to be moved.[17] Instead of using a square on the hypotenuse and two squares on the legs, one can use any other shape that includes the hypotenuse, and two similar shapes that each include one of two legs instead of the hypotenuse (see Similar figures on the three sides). In Einstein's proof, the shape that includes the hypotenuse is the right triangle itself. The dissection consists of dropping a perpendicular from the vertex of the right angle of the triangle to the hypotenuse, thus splitting the whole triangle into two parts. Those two parts have the same shape as the original right triangle, and have the legs of the original triangle as their hypotenuses, and the sum of their areas is that of the original triangle. Because the ratio of the area of a right triangle to the square of its hypotenuse is the same for similar triangles, the relationship between the areas of the three triangles holds for the squares of the sides of the large triangle as well.

Proof by area-preserving shearing Visual proof of the Pythagorean theorem by area-preserving shearing.

As shown in the accompanying animation, area-preserving shear mappings and translations can transform the squares on the sides adjacent to the right-angle onto the square on the hypotenuse, together covering it exactly.[18] Each shear leaves the base and height unchanged, thus leaving the area unchanged too. The translations also leave the area unchanged, as they do not alter the shapes at all. Each square is first sheared into a parallelogram, and then into a rectangle which can be translated onto one section of the square on the hypotenuse.

Algebraic proofs A related proof was published by future U.S. President James A. Garfield (then a U.S. Representative) (voir schéma).[19][20][21] Instead of a square it uses a trapezoid, which can be constructed from the square in the second of the above proofs by bisecting along a diagonal of the inner square, to give the trapezoid as shown in the diagram. The area of the trapezoid can be calculated to be half the area of the square, C'est {style d'affichage {frac {1}{2}}(b+a)^{2}.} The inner square is similarly halved, and there are only two triangles so the proof proceeds as above except for a factor of {style d'affichage {frac {1}{2}}} , which is removed by multiplying by two to give the result.

Proof using differentials One can arrive at the Pythagorean theorem by studying how changes in a side produce a change in the hypotenuse and employing calculus.[22][23][24] The triangle ABC is a right triangle, as shown in the upper part of the diagram, with BC the hypotenuse. At the same time the triangle lengths are measured as shown, with the hypotenuse of length y, the side AC of length x and the side AB of length a, as seen in the lower diagram part.

Diagram for differential proof If x is increased by a small amount dx by extending the side AC slightly to D, then y also increases by dy. These form two sides of a triangle, CDE, qui (with E chosen so CE is perpendicular to the hypotenuse) is a right triangle approximately similar to ABC. Par conséquent, the ratios of their sides must be the same, C'est: {style d'affichage {frac {mourir}{dx}}={frac {X}{y}}.} This can be rewritten as {style d'affichage y,dy=x,dx} , which is a differential equation that can be solved by direct integration: {displaystyle int y,dy=int x,dx,,} giving {displaystyle y^{2}=x^{2}+C} The constant can be deduced from x = 0, y = a to give the equation {displaystyle y^{2}=x^{2}+un ^{2}.} This is more of an intuitive proof than a formal one: it can be made more rigorous if proper limits are used in place of dx and dy.

Converse The converse of the theorem is also true:[25] For any three positive numbers a, b, and c such that a2 + b2 = c2, there exists a triangle with sides a, b and c, and every such triangle has a right angle between the sides of lengths a and b.

An alternative statement is: For any triangle with sides a, b, c, if a2 + b2 = c2, then the angle between a and b measures 90°.

This converse also appears in Euclid's Elements (Book I, Proposition 48):[26] "If in a triangle the square on one of the sides equals the sum of the squares on the remaining two sides of the triangle, then the angle contained by the remaining two sides of the triangle is right."

It can be proven using the law of cosines or as follows: Let ABC be a triangle with side lengths a, b, and c, with a2 + b2 = c2. Construct a second triangle with sides of length a and b containing a right angle. By the Pythagorean theorem, it follows that the hypotenuse of this triangle has length c = √a2 + b2, the same as the hypotenuse of the first triangle. Since both triangles' sides are the same lengths a, b and c, the triangles are congruent and must have the same angles. Par conséquent, the angle between the side of lengths a and b in the original triangle is a right angle.

The above proof of the converse makes use of the Pythagorean theorem itself. The converse can also be proven without assuming the Pythagorean theorem.[27][28] A corollary of the Pythagorean theorem's converse is a simple means of determining whether a triangle is right, obtuse, or acute, as follows. Let c be chosen to be the longest of the three sides and a + b > c (otherwise there is no triangle according to the triangle inequality). The following statements apply:[29] If a2 + b2 = c2, then the triangle is right. If a2 + b2 > c2, then the triangle is acute. If a2 + b2 < c2, then the triangle is obtuse. Edsger W. Dijkstra has stated this proposition about acute, right, and obtuse triangles in this language: sgn(α + β − γ) = sgn(a2 + b2 − c2), where α is the angle opposite to side a, β is the angle opposite to side b, γ is the angle opposite to side c, and sgn is the sign function.[30] Consequences and uses of the theorem Pythagorean triples Main article: Pythagorean triple A Pythagorean triple has three positive integers a, b, and c, such that a2 + b2 = c2. In other words, a Pythagorean triple represents the lengths of the sides of a right triangle where all three sides have integer lengths.[1] Such a triple is commonly written (a, b, c). Some well-known examples are (3, 4, 5) and (5, 12, 13). A primitive Pythagorean triple is one in which a, b and c are coprime (the greatest common divisor of a, b and c is 1). The following is a list of primitive Pythagorean triples with values less than 100: (3, 4, 5), (5, 12, 13), (7, 24, 25), (8, 15, 17), (9, 40, 41), (11, 60, 61), (12, 35, 37), (13, 84, 85), (16, 63, 65), (20, 21, 29), (28, 45, 53), (33, 56, 65), (36, 77, 85), (39, 80, 89), (48, 55, 73), (65, 72, 97) Inverse Pythagorean theorem Given a right triangle with sides {displaystyle a,b,c} and altitude {displaystyle d} (a line from the right angle and perpendicular to the hypotenuse {displaystyle c} ). The Pythagorean theorem has, {displaystyle a^{2}+b^{2}=c^{2}} while the inverse Pythagorean theorem relates the two legs {displaystyle a,b} to the altitude {displaystyle d} ,[31] {displaystyle {frac {1}{a^{2}}}+{frac {1}{b^{2}}}={frac {1}{d^{2}}}} The equation can be transformed to, {displaystyle {frac {1}{(xz)^{2}}}+{frac {1}{(yz)^{2}}}={frac {1}{(xy)^{2}}}} where {displaystyle x^{2}+y^{2}=z^{2}} for any non-zero real {displaystyle x,y,z} . If the {displaystyle a,b,d} are to be integers, the smallest solution {displaystyle a>b>d} is then {style d'affichage {frac {1}{20^{2}}}+{frac {1}{15^{2}}}={frac {1}{12^{2}}}} using the smallest Pythagorean triple {style d'affichage 3,4,5} . The reciprocal Pythagorean theorem is a special case of the optic equation {style d'affichage {frac {1}{p}}+{frac {1}{q}}={frac {1}{r}}} where the denominators are squares and also for a heptagonal triangle whose sides {style d'affichage p,q,r} are square numbers.

Incommensurable lengths The spiral of Theodorus: A construction for line segments with lengths whose ratios are the square root of a positive integer One of the consequences of the Pythagorean theorem is that line segments whose lengths are incommensurable (so the ratio of which is not a rational number) can be constructed using a straightedge and compass. Pythagoras' theorem enables construction of incommensurable lengths because the hypotenuse of a triangle is related to the sides by the square root operation.

The figure on the right shows how to construct line segments whose lengths are in the ratio of the square root of any positive integer.[32] Each triangle has a side (labeled "1") that is the chosen unit for measurement. In each right triangle, Pythagoras' theorem establishes the length of the hypotenuse in terms of this unit. If a hypotenuse is related to the unit by the square root of a positive integer that is not a perfect square, it is a realization of a length incommensurable with the unit, such as √2, √3, √5 . For more detail, see Quadratic irrational.

Incommensurable lengths conflicted with the Pythagorean school's concept of numbers as only whole numbers. The Pythagorean school dealt with proportions by comparison of integer multiples of a common subunit.[33] According to one legend, Hippasus of Metapontum (ca. 470 B.C.) was drowned at sea for making known the existence of the irrational or incommensurable.[34][35] Complex numbers The absolute value of a complex number z is the distance r from z to the origin For any complex number {displaystyle z=x+iy,} the absolute value or modulus is given by {displaystyle r=|z|={sqrt {x^{2}+y ^{2}}}.} So the three quantities, r, x and y are related by the Pythagorean equation, {style d'affichage r^{2}=x^{2}+y ^{2}.} Note that r is defined to be a positive number or zero but x and y can be negative as well as positive. Geometrically r is the distance of the z from zero or the origin O in the complex plane.

This can be generalised to find the distance between two points, z1 and z2 say. The required distance is given by {style d'affichage |z_{1}-z_{2}|={sqrt {(X_{1}-X_{2})^{2}+(y_{1}-y_{2})^{2}}},} so again they are related by a version of the Pythagorean equation, {style d'affichage |z_{1}-z_{2}|^{2}=(X_{1}-X_{2})^{2}+(y_{1}-y_{2})^{2}.} Euclidean distance Further information: Euclidean distance The distance formula in Cartesian coordinates is derived from the Pythagorean theorem.[36] Si (x1, y1) et (x2, y2) are points in the plane, then the distance between them, also called the Euclidean distance, est donné par {style d'affichage {sqrt {(X_{1}-X_{2})^{2}+(y_{1}-y_{2})^{2}}}.} Plus généralement, in Euclidean n-space, the Euclidean distance between two points, {style d'affichage A,=,(un_{1},un_{2},des points ,un_{n})} et {style d'affichage B,=,(b_{1},b_{2},des points ,b_{n})} , est défini, by generalization of the Pythagorean theorem, comme: {style d'affichage {sqrt {(un_{1}-b_{1})^{2}+(un_{2}-b_{2})^{2}+cdots +(un_{n}-b_{n})^{2}}}={sqrt {somme _{je=1}^{n}(un_{je}-b_{je})^{2}}}.} If instead of Euclidean distance, the square of this value (the squared Euclidean distance, or SED) est utilisé, the resulting equation avoids square roots and is simply a sum of the SED of the coordinates: {style d'affichage (un_{1}-b_{1})^{2}+(un_{2}-b_{2})^{2}+cdots +(un_{n}-b_{n})^{2}=somme _{je=1}^{n}(un_{je}-b_{je})^{2}.} The squared form is a smooth, convex function of both points, and is widely used in optimization theory and statistics, forming the basis of least squares.

Euclidean distance in other coordinate systems If Cartesian coordinates are not used, par exemple, if polar coordinates are used in two dimensions or, in more general terms, if curvilinear coordinates are used, the formulas expressing the Euclidean distance are more complicated than the Pythagorean theorem, but can be derived from it. A typical example where the straight-line distance between two points is converted to curvilinear coordinates can be found in the applications of Legendre polynomials in physics. The formulas can be discovered by using Pythagoras' theorem with the equations relating the curvilinear coordinates to Cartesian coordinates. Par exemple, the polar coordinates (r, je) can be introduced as: {displaystyle x=rcos theta , y=rsin theta .} Then two points with locations (r1, θ1) et (r2, θ2) are separated by a distance s: {displaystyle s^{2}=(X_{1}-X_{2})^{2}+(y_{1}-y_{2})^{2}=(r_{1}cos theta _{1}-r_{2}cos theta _{2})^{2}+(r_{1}sin theta _{1}-r_{2}sin theta _{2})^{2}.} Performing the squares and combining terms, the Pythagorean formula for distance in Cartesian coordinates produces the separation in polar coordinates as: {style d'affichage {commencer{aligné}s ^{2}&=r_{1}^{2}+r_{2}^{2}-2r_{1}r_{2}la gauche(cos theta _{1}cos theta _{2}+sin theta _{1}sin theta _{2}droit)\&=r_{1}^{2}+r_{2}^{2}-2r_{1}r_{2}cos left(thêta _{1}-thêta _{2}droit)\&=r_{1}^{2}+r_{2}^{2}-2r_{1}r_{2}cos Delta theta ,fin{aligné}}} using the trigonometric product-to-sum formulas. This formula is the law of cosines, sometimes called the generalized Pythagorean theorem.[37] From this result, for the case where the radii to the two locations are at right angles, the enclosed angle Δθ = π/2, and the form corresponding to Pythagoras' theorem is regained: {displaystyle s^{2}=r_{1}^{2}+r_{2}^{2}.} The Pythagorean theorem, valid for right triangles, therefore is a special case of the more general law of cosines, valid for arbitrary triangles.

Pythagorean trigonometric identity Main article: Pythagorean trigonometric identity Similar right triangles showing sine and cosine of angle θ In a right triangle with sides a, b and hypotenuse c, trigonometry determines the sine and cosine of the angle θ between side a and the hypotenuse as: {displaystyle sin theta ={frac {b}{c}},quad cos theta ={frac {un}{c}}.} From that it follows: {style d'affichage {parce que }^{2}thêta +{péché }^{2}theta ={frac {un ^{2}+b^{2}}{c^{2}}}=1,} where the last step applies Pythagoras' theorem. This relation between sine and cosine is sometimes called the fundamental Pythagorean trigonometric identity.[38] In similar triangles, the ratios of the sides are the same regardless of the size of the triangles, and depend upon the angles. Par conséquent, dans la figure, the triangle with hypotenuse of unit size has opposite side of size sin θ and adjacent side of size cos θ in units of the hypotenuse.

Relation to the cross product The area of a parallelogram as a cross product; vectors a and b identify a plane and a × b is normal to this plane.

The Pythagorean theorem relates the cross product and dot product in a similar way:[39] {style d'affichage |mathbf {un} fois mathbf {b} |^{2}+(mathbf {un} cdot mathbf {b} )^{2}=|mathbf {un} |^{2}|mathbf {b} |^{2}.} This can be seen from the definitions of the cross product and dot product, comme {style d'affichage {commencer{aligné}mathbf {un} fois mathbf {b} &=abmathbf {n} péché {thêta }\mathbf {un} cdot mathbf {b} &=abcos {thêta },fin{aligné}}} with n a unit vector normal to both a and b. The relationship follows from these definitions and the Pythagorean trigonometric identity.

This can also be used to define the cross product. By rearranging the following equation is obtained {style d'affichage |mathbf {un} fois mathbf {b} |^{2}=|mathbf {un} |^{2}|mathbf {b} |^{2}-(mathbf {un} cdot mathbf {b} )^{2}.} This can be considered as a condition on the cross product and so part of its definition, for example in seven dimensions.[40][41] Generalizations Similar figures on the three sides The Pythagorean theorem generalizes beyond the areas of squares on the three sides to any similar figures. This was known by Hippocrates of Chios in the 5th century BC,[42] and was included by Euclid in his Elements:[43] If one erects similar figures (see Euclidean geometry) with corresponding sides on the sides of a right triangle, then the sum of the areas of the ones on the two smaller sides equals the area of the one on the larger side.

This extension assumes that the sides of the original triangle are the corresponding sides of the three congruent figures (so the common ratios of sides between the similar figures are a:b:c).[44] While Euclid's proof only applied to convex polygons, the theorem also applies to concave polygons and even to similar figures that have curved boundaries (but still with part of a figure's boundary being the side of the original triangle).[44] The basic idea behind this generalization is that the area of a plane figure is proportional to the square of any linear dimension, and in particular is proportional to the square of the length of any side. Ainsi, if similar figures with areas A, B and C are erected on sides with corresponding lengths a, b and c then: {style d'affichage {frac {UN}{un ^{2}}}={frac {B}{b^{2}}}={frac {C}{c^{2}}},,} {displaystyle Rightarrow A+B={frac {un ^{2}}{c^{2}}}C+{frac {b^{2}}{c^{2}}}C,.} Mais, by the Pythagorean theorem, a2 + b2 = c2, so A + B = C.

inversement, if we can prove that A + B = C for three similar figures without using the Pythagorean theorem, then we can work backwards to construct a proof of the theorem. Par exemple, the starting center triangle can be replicated and used as a triangle C on its hypotenuse, and two similar right triangles (A and B ) constructed on the other two sides, formed by dividing the central triangle by its altitude. The sum of the areas of the two smaller triangles therefore is that of the third, thus A + B = C and reversing the above logic leads to the Pythagorean theorem a2 + b2 = c2. (See also Einstein's proof by dissection without rearrangement) Generalization for similar triangles, green area A + B = blue area C Pythagoras' theorem using similar right triangles Generalization for regular pentagons Law of cosines Main article: Law of cosines The separation s of two points (r1, θ1) et (r2, θ2) in polar coordinates is given by the law of cosines. Interior angle Δθ = θ1−θ2.

The Pythagorean theorem is a special case of the more general theorem relating the lengths of sides in any triangle, the law of cosines:[45] {style d'affichage a^{2}+b^{2}-2abcos {thêta }=c^{2},} où {thêta de style d'affichage } is the angle between sides {style d'affichage a} et {style d'affichage b} .

Lorsque {thêta de style d'affichage } est {style d'affichage {frac {pi }{2}}} radians or 90°, alors {style d'affichage cos {thêta }=0} , and the formula reduces to the usual Pythagorean theorem.

Arbitrary triangle Generalization of Pythagoras' theorem by Tâbit ibn Qorra.[46] Lower panel: reflection of triangle CAD (Haut) to form triangle DAC, similar to triangle ABC (Haut).

At any selected angle of a general triangle of sides a, b, c, inscribe an isosceles triangle such that the equal angles at its base θ are the same as the selected angle. Suppose the selected angle θ is opposite the side labeled c. Inscribing the isosceles triangle forms triangle CAD with angle θ opposite side b and with side r along c. A second triangle is formed with angle θ opposite side a and a side with length s along c, as shown in the figure. Thābit ibn Qurra stated that the sides of the three triangles were related as:[47][48] {style d'affichage a^{2}+b^{2}=c(r+s) .} As the angle θ approaches π/2, the base of the isosceles triangle narrows, and lengths r and s overlap less and less. When θ = π/2, ADB becomes a right triangle, r + s = c, and the original Pythagorean theorem is regained.

One proof observes that triangle ABC has the same angles as triangle CAD, but in opposite order. (The two triangles share the angle at vertex A, both contain the angle θ, and so also have the same third angle by the triangle postulate.) Par conséquent, ABC is similar to the reflection of CAD, the triangle DAC in the lower panel. Taking the ratio of sides opposite and adjacent to θ, {style d'affichage {frac {c}{b}}={frac {b}{r}} .} De même, for the reflection of the other triangle, {style d'affichage {frac {c}{un}}={frac {un}{s}} .} Clearing fractions and adding these two relations: {displaystyle cs+cr=a^{2}+b^{2} ,} the required result.

The theorem remains valid if the angle {thêta de style d'affichage } is obtuse so the lengths r and s are non-overlapping.

General triangles using parallelograms Generalization for arbitrary triangles, green area = blue area Construction for proof of parallelogram generalization Pappus's area theorem is a further generalization, that applies to triangles that are not right triangles, using parallelograms on the three sides in place of squares (squares are a special case, bien sûr). The upper figure shows that for a scalene triangle, the area of the parallelogram on the longest side is the sum of the areas of the parallelograms on the other two sides, provided the parallelogram on the long side is constructed as indicated (the dimensions labeled with arrows are the same, and determine the sides of the bottom parallelogram). This replacement of squares with parallelograms bears a clear resemblance to the original Pythagoras' theorem, and was considered a generalization by Pappus of Alexandria in 4 UN D[49][50] The lower figure shows the elements of the proof. Focus on the left side of the figure. The left green parallelogram has the same area as the left, blue portion of the bottom parallelogram because both have the same base b and height h. Cependant, the left green parallelogram also has the same area as the left green parallelogram of the upper figure, because they have the same base (the upper left side of the triangle) and the same height normal to that side of the triangle. Repeating the argument for the right side of the figure, the bottom parallelogram has the same area as the sum of the two green parallelograms.

Solid geometry Main article: Solid geometry Pythagoras' theorem in three dimensions relates the diagonal AD to the three sides. A tetrahedron with outward facing right-angle corner In terms of solid geometry, Pythagoras' theorem can be applied to three dimensions as follows. Consider a rectangular solid as shown in the figure. The length of diagonal BD is found from Pythagoras' theorem as: {style d'affichage {surligner {BD}}^{,2}={surligner {avant JC}}^{,2}+{surligner {CD}}^{,2} ,} where these three sides form a right triangle. Using horizontal diagonal BD and the vertical edge AB, the length of diagonal AD then is found by a second application of Pythagoras' theorem as: {style d'affichage {surligner {UN D}}^{,2}={surligner {UN B}}^{,2}+{surligner {BD}}^{,2} ,} ou, doing it all in one step: {style d'affichage {surligner {UN D}}^{,2}={surligner {UN B}}^{,2}+{surligner {avant JC}}^{,2}+{surligner {CD}}^{,2} .} This result is the three-dimensional expression for the magnitude of a vector v (the diagonal AD) in terms of its orthogonal components {vk} (the three mutually perpendicular sides): {style d'affichage |mathbf {v} |^{2}=somme _{k=1}^{3}|mathbf {v} _{k}|^{2}.} This one-step formulation may be viewed as a generalization of Pythagoras' theorem to higher dimensions. Cependant, this result is really just the repeated application of the original Pythagoras' theorem to a succession of right triangles in a sequence of orthogonal planes.

A substantial generalization of the Pythagorean theorem to three dimensions is de Gua's theorem, named for Jean Paul de Gua de Malves: If a tetrahedron has a right angle corner (like a corner of a cube), then the square of the area of the face opposite the right angle corner is the sum of the squares of the areas of the other three faces. This result can be generalized as in the "n-dimensional Pythagorean theorem":[51] Laisser {style d'affichage x_{1},X_{2},ldots ,X_{n}} be orthogonal vectors in Rn. Consider the n-dimensional simplex S with vertices {displaystyle 0,x_{1},ldots ,X_{n}} . (Think of the (n- 1)-dimensional simplex with vertices {style d'affichage x_{1},ldots ,X_{n}} not including the origin as the "hypotenuse" of S and the remaining (n- 1)-dimensional faces of S as its "legs".) Then the square of the volume of the hypotenuse of S is the sum of the squares of the volumes of the n legs.

This statement is illustrated in three dimensions by the tetrahedron in the figure. La "hypotenuse" is the base of the tetrahedron at the back of the figure, et le "legs" are the three sides emanating from the vertex in the foreground. As the depth of the base from the vertex increases, the area of the "legs" increases, while that of the base is fixed. The theorem suggests that when this depth is at the value creating a right vertex, the generalization of Pythagoras' theorem applies. In a different wording:[52] Given an n-rectangular n-dimensional simplex, the square of the (n- 1)-content of the facet opposing the right vertex will equal the sum of the squares of the (n- 1)-contents of the remaining facets.

Inner product spaces See also: Hilbert space Vectors involved in the parallelogram law The Pythagorean theorem can be generalized to inner product spaces,[53] which are generalizations of the familiar 2-dimensional and 3-dimensional Euclidean spaces. Par exemple, a function may be considered as a vector with infinitely many components in an inner product space, as in functional analysis.[54] In an inner product space, the concept of perpendicularity is replaced by the concept of orthogonality: two vectors v and w are orthogonal if their inner product {displaystyle langle mathbf {v} ,mathbf {w} hochet } est zéro. The inner product is a generalization of the dot product of vectors. The dot product is called the standard inner product or the Euclidean inner product. Cependant, other inner products are possible.[55] The concept of length is replaced by the concept of the norm ||v|| of a vector v, défini comme:[56] {displaystyle lVert mathbf {v} rVert equiv {sqrt {langle mathbf {v} ,mathbf {v} hochet }},.} In an inner-product space, the Pythagorean theorem states that for any two orthogonal vectors v and w we have {style d'affichage à gauche|mathbf {v} +mathbf {w} droit|^{2}=gauche|mathbf {v} droit|^{2}+la gauche|mathbf {w} droit|^{2}.} Here the vectors v and w are akin to the sides of a right triangle with hypotenuse given by the vector sum v + w. This form of the Pythagorean theorem is a consequence of the properties of the inner product: {style d'affichage à gauche|mathbf {v} +mathbf {w} droit|^{2}=langle mathbf {v+w} , mathbf {v+w} rangle =langle mathbf {v} , mathbf {v} rangle +langle mathbf {w} , mathbf {w} rangle +langle mathbf {v, w} rangle +langle mathbf {w, v} rangle =left|mathbf {v} droit|^{2}+la gauche|mathbf {w} droit|^{2},} where the inner products of the cross terms are zero, because of orthogonality.

A further generalization of the Pythagorean theorem in an inner product space to non-orthogonal vectors is the parallelogram law :[56] {style d'affichage 2|mathbf {v} |^{2}+2|mathbf {w} |^{2}=|mathbf {v+w} |^{2}+|mathbf {v-w} |^{2} ,} which says that twice the sum of the squares of the lengths of the sides of a parallelogram is the sum of the squares of the lengths of the diagonals. Any norm that satisfies this equality is ipso facto a norm corresponding to an inner product.[56] The Pythagorean identity can be extended to sums of more than two orthogonal vectors. If v1, v2, ..., vn are pairwise-orthogonal vectors in an inner-product space, then application of the Pythagorean theorem to successive pairs of these vectors (as described for 3-dimensions in the section on solid geometry) results in the equation[57] {style d'affichage à gauche|somme _{k=1}^{n}mathbf {v} _{k}droit|^{2}=somme _{k=1}^{n}|mathbf {v} _{k}|^{2}} Sets of m-dimensional objects in n-dimensional space Another generalization of the Pythagorean theorem applies to Lebesgue-measurable sets of objects in any number of dimensions. Spécifiquement, the square of the measure of an m-dimensional set of objects in one or more parallel m-dimensional flats in n-dimensional Euclidean space is equal to the sum of the squares of the measures of the orthogonal projections of the object(s) onto all m-dimensional coordinate subspaces.[58] En termes mathématiques: {style d'affichage lui _{ms}^{2}=somme _{je=1}^{X}mathbf {mu ^{2}} _{mp_{je}}} où: {style d'affichage lui _{m}} is a measure in m-dimensions (a length in one dimension, an area in two dimensions, a volume in three dimensions, etc.). {style d'affichage s} is a set of one or more non-overlapping m-dimensional objects in one or more parallel m-dimensional flats in n-dimensional Euclidean space. {style d'affichage lui _{ms}} is the total measure (sum) of the set of m-dimensional objects. {style d'affichage p} represents an m-dimensional projection of the original set onto an orthogonal coordinate subspace. {style d'affichage lui _{mp_{je}}} is the measure of the m-dimensional set projection onto m-dimensional coordinate subspace {style d'affichage i} . Because object projections can overlap on a coordinate subspace, the measure of each object projection in the set must be calculated individually, then measures of all projections added together to provide the total measure for the set of projections on the given coordinate subspace. {style d'affichage x} is the number of orthogonal, m-dimensional coordinate subspaces in n-dimensional space (Rn) onto which the m-dimensional objects are projected (m ≤ n): {displaystyle x={certains d'entre eux {n}{m}}={frac {n!}{m!(nm)!}}} Non-Euclidean geometry Main article: Non-Euclidean geometry See also: Hilbert's axioms The Pythagorean theorem is derived from the axioms of Euclidean geometry, et en fait, were the Pythagorean theorem to fail for some right triangle, then the plane in which this triangle is contained cannot be Euclidean. Plus précisément, the Pythagorean theorem implies, and is implied by, Euclid's Parallel (Fifth) Postulate.[59][60] Ainsi, right triangles in a non-Euclidean geometry[61] do not satisfy the Pythagorean theorem. Par exemple, in spherical geometry, all three sides of the right triangle (say a, b, and c) bounding an octant of the unit sphere have length equal to π/2, and all its angles are right angles, which violates the Pythagorean theorem because {style d'affichage a^{2}+b^{2}=2c^{2}>c^{2}} .

Here two cases of non-Euclidean geometry are considered—spherical geometry and hyperbolic plane geometry; in each case, as in the Euclidean case for non-right triangles, the result replacing the Pythagorean theorem follows from the appropriate law of cosines.