What is Diagonal — Definition, Formula & Examples in Math

#Math Terms
TL;DR
A diagonal is a straight line segment that joins two non-adjacent (non-consecutive) vertices of a polygon or polyhedron. This article gives the formal definition, the count formula n(n−3)/2n(n-3)/2, length formulas for the square (a2a\sqrt{2}), rectangle (l2+b2\sqrt{l^2 + b^2}), and cube (a3a\sqrt{3}), three worked examples (Quick / Standard / Stretch), the properties of diagonals across common quadrilaterals, and the most common mistakes.
BT
Bhanzu TeamLast updated on June 4, 20267 min read

A diagonal is a line segment that connects two corners of a shape without sliding along any edge. A triangle has none — every pair of vertices is already joined by an edge. A square has two. A pentagon has five.

The Formal Definition

A diagonal of a polygon is a line segment joining two non-adjacent (non-consecutive) vertices. In a polyhedron (a 3D solid), a space diagonal joins two non-adjacent vertices that do not share a face; a face diagonal lies inside a single face of the solid.

The smallest polygon that can have a diagonal is the quadrilateral — three-sided polygons (triangles) have only neighbouring vertices.

Quick reference.

  • Definition: a segment joining two non-adjacent vertices.

  • Notation: dd for length; sometimes ACAC or BDBD naming the vertices.

  • Count for an nn-sided polygon: n(n−3)2\dfrac{n(n-3)}{2}.

  • Length — square (side aa): a2a\sqrt{2}.

  • Length — rectangle (l,bl, b): l2+b2\sqrt{l^{2} + b^{2}}.

  • Length — cube (side aa): a3a\sqrt{3} (space diagonal).

  • Grade introduced: CCSS-M 4.G.A (polygon properties); NCERT Class 8 — Understanding Quadrilaterals.

The Count Formula — Why n(n−3)2\dfrac{n(n-3)}{2}

From any one vertex, you can draw a line to every other vertex except two — yourself and your two immediate neighbours (those connect by edges, not diagonals). That gives n−3n - 3 diagonals per vertex. With nn vertices, the total count of vertex-to-diagonal pairs is n(n−3)n(n - 3). But each diagonal has two endpoints, so it's been counted twice — divide by 22.

Number of diagonals=n(n−3)2.\text{Number of diagonals} = \frac{n(n-3)}{2}.

Polygon

nn

Diagonals

Triangle

33

00

Quadrilateral

44

22

Pentagon

55

55

Hexagon

66

99

Heptagon

77

1414

Octagon

88

2020

Decagon

1010

3535

The count grows quickly because each new side adds connections to roughly all existing vertices.

Length of a Diagonal — The Three Most-Used Formulas

These three come up most often in CBSE and Common Core problems.

Square (side aa). The diagonal cuts the square into two right triangles whose legs are both aa. By the Pythagorean theorem:

d=a2+a2=a2.d = \sqrt{a^{2} + a^{2}} = a\sqrt{2}.

Rectangle (l,bl, b). The diagonal is the hypotenuse of a right triangle with legs ll and bb:

d=l2+b2.d = \sqrt{l^{2} + b^{2}}.

Cube (side aa). The space diagonal runs from one corner of the cube straight through to the opposite corner. It's the hypotenuse of a right triangle whose legs are aa (one edge) and a2a\sqrt{2} (the face diagonal):

d=a2+(a2)2=a2+2a2=a3.d = \sqrt{a^{2} + (a\sqrt{2})^{2}} = \sqrt{a^{2} + 2a^{2}} = a\sqrt{3}.

A pattern emerges: a square's diagonal grows like 2\sqrt{2}, a cube's like 3\sqrt{3}, a 4D-hypercube's like 4=2\sqrt{4} = 2, and so on. The n\sqrt{n}-growth is one of the cleanest results in elementary geometry.

Diagonal Properties Across Common Quadrilaterals

The diagonals of a quadrilateral carry rich information about the shape.

Quadrilateral

Diagonals equal?

Bisect each other?

Bisect at right angles?

Square

✓

✓

✓

Rectangle

✓

✓

–

Rhombus

–

✓

✓

Parallelogram

–

✓

–

Trapezium (general)

–

–

–

Isosceles trapezium

✓

–

–

Kite

–

One bisects the other

✓

These properties are how a geometry student proves what kind of quadrilateral they're looking at — measure the diagonals, check the three boxes above, identify the shape.

Three Worked Examples — Quick, Standard, Stretch

Quick. How many diagonals does a hexagon have?

Use n(n−3)2\dfrac{n(n-3)}{2} with n=6n = 6:

6×(6−3)2=6×32=9.\frac{6 \times (6 - 3)}{2} = \frac{6 \times 3}{2} = 9.

Final answer: 99 diagonals.

Standard (Wrong Path First — Where Diagonals Trip Students). A rectangle has length 2424 cm and breadth 77 cm. Find the length of its diagonal.

The wrong path. A student tries to add: d=l+b=24+7=31d = l + b = 24 + 7 = 31 cm.

The flaw: the diagonal is not the sum of the sides. It's the straight-line distance across, which is the hypotenuse of a right triangle. Adding ll and bb would only work if the rectangle were collapsed flat — which makes no geometric sense.

The rescue. Use the Pythagorean theorem on the right triangle whose legs are ll and bb:

d=l2+b2=242+72=576+49=625=25 cm.d = \sqrt{l^{2} + b^{2}} = \sqrt{24^{2} + 7^{2}} = \sqrt{576 + 49} = \sqrt{625} = 25 \text{ cm}.

Final answer: 2525 cm.

Sanity check: the diagonal should be less than l+b=31l + b = 31 (triangle inequality) and greater than l=24l = 24 (the diagonal is the longest side of the right triangle). 24<25<3124 < 25 < 31 ✓.

The lesson — a diagonal is a Pythagorean hypotenuse, not a sum. The right angle at the corner of the rectangle is the whole geometric reason behind the l2+b2\sqrt{l^{2} + b^{2}} formula.

Stretch. A cube has edge length 66 cm. Find (a) the face diagonal and (b) the space diagonal.

(a) Face diagonal — diagonal of one square face of side 66:

dface=62≈8.49 cm.d_{\text{face}} = 6\sqrt{2} \approx 8.49 \text{ cm}.

(b) Space diagonal — corner to opposite corner through the interior:

dspace=63≈10.39 cm.d_{\text{space}} = 6\sqrt{3} \approx 10.39 \text{ cm}.

Final answer: face diagonal ≈8.49\approx 8.49 cm; space diagonal ≈10.39\approx 10.39 cm.

This is the version of diagonal that shows up in NCERT Class 9–10 mensuration problems and in 3D coordinate geometry (the distance from (0,0,0)(0,0,0) to (a,a,a)(a, a, a) is exactly a3a\sqrt{3}).

Where Diagonals Appear — Beyond the Polygon

A few places the idea is the foundation under a larger result:

  • Pythagorean triples in carpentry. The "33-44-55 triangle" comes up because a rectangle of sides 33 and 44 has a diagonal of 55 — exactly the trick builders use to square up a foundation.

  • Television screen sizes. A "5555-inch TV" measures the diagonal of the screen, not the side. A 16:916:9 aspect-ratio screen with a 5555-inch diagonal is about 47.947.9 inches wide and 26.926.9 inches tall.

  • Triangulation in maps. Every modern GPS uses diagonals — straight-line distances from satellites to a receiver — to solve for position.

  • Graph theory. A diagonal in a Latin square or a magic square is a special row that the puzzle uses. The 1948 Latin Square connection by Sir Ronald A. Fisher extended diagonals into agricultural-trial design.

The earliest known proof that a square's diagonal is a2a\sqrt{2} — and that 2\sqrt{2} is not a rational number — is attributed to the Pythagorean school around 500 BCE. The proof is short, four lines, and changed mathematics: it forced the existence of irrational numbers for the first time.

Diagonal: Tripping Points to Avoid

Mistake 1: Counting an edge as a diagonal

Where it slips in: A student lists "the four sides plus two diagonals" of a square as 66 diagonals.

Don't do this: Treat any line segment between two corners as a diagonal.

The correct way: A diagonal joins non-adjacent vertices only. The sides of the polygon are not diagonals. A square has 22 diagonals, not 66.

Mistake 2: Adding the sides to find a diagonal

Where it slips in: Rectangle of 55 cm × 1212 cm — student writes diagonal =5+12=17= 5 + 12 = 17.

Don't do this: Sum the sides.

The correct way: Apply Pythagoras: d=52+122=169=13d = \sqrt{5^{2} + 12^{2}} = \sqrt{169} = 13 cm.

Mistake 3: Confusing the face diagonal with the space diagonal of a cube

Where it slips in: A problem asks for the longest diagonal of a cube of side aa; student gives a2a\sqrt{2}.

Don't do this: Stop at the face diagonal.

The correct way: The longest diagonal of a cube is the space diagonal, a3a\sqrt{3} — corner to opposite corner through the interior of the cube, not across one face.

Conclusion

  • A diagonal joins two non-adjacent vertices of a polygon or polyhedron.

  • An nn-sided polygon has n(n−3)2\dfrac{n(n-3)}{2} diagonals.

  • A square's diagonal is a2a\sqrt{2}; a rectangle's is l2+b2\sqrt{l^{2} + b^{2}}; a cube's space diagonal is a3a\sqrt{3}.

  • The diagonal of every rectangle and square is the hypotenuse of a right triangle — Pythagoras decides the length.

  • The properties of the two diagonals (equal, bisect, perpendicular) identify the type of quadrilateral.

Quick Self-Check — Three Problems

  1. How many diagonals does a decagon (n=10n = 10) have?

  2. Find the diagonal of a rectangle of length 99 cm and breadth 1212 cm.

  3. Find the space diagonal of a cube of side 44 cm.

If you got 2121 for problem 1, recount — the formula gives 3535.

Want a live Bhanzu trainer to walk your child through diagonals and the Pythagorean shortcut? Book a free demo class — online globally.

Was this article helpful?

Your feedback helps us write better content

Frequently Asked Questions

What is a diagonal in math?
A line segment joining two non-adjacent vertices of a polygon or polyhedron.
How many diagonals does an octagon have?
Using n(n−3)2\dfrac{n(n-3)}{2} with n=8n = 8: 8×52=20\dfrac{8 \times 5}{2} = 20.
What is the formula for the diagonal of a square?
d=a2d = a\sqrt{2}, where aa is the side length.
Does a triangle have a diagonal?
No. A triangle's three vertices are all adjacent to each other — no non-adjacent pairs exist, so no diagonals can be drawn.
Do the diagonals of a parallelogram bisect each other?
Yes — that's one of the defining properties. They do not bisect at right angles unless the parallelogram is a rhombus or a square.
How is the diagonal of a TV screen measured?
From one corner of the screen to the opposite corner, in inches. The advertised size (e.g., 5555") is the diagonal, not the width.
What's the difference between a face diagonal and a space diagonal?
A face diagonal lies inside one face of a 3D solid (e.g., the diagonal of a single face of a cube, length a2a\sqrt{2}). A space diagonal cuts through the interior of the solid from one corner to the opposite (length a3a\sqrt{3} for a cube).
✍️ Written By
BT
Bhanzu Team
Content Creator and Editor
Bhanzu’s editorial team, known as Team Bhanzu, is made up of experienced educators, curriculum experts, content strategists, and fact-checkers dedicated to making math simple and engaging for learners worldwide. Every article and resource is carefully researched, thoughtfully structured, and rigorously reviewed to ensure accuracy, clarity, and real-world relevance. We understand that building strong math foundations can raise questions for students and parents alike. That’s why Team Bhanzu focuses on delivering practical insights, concept-driven explanations, and trustworthy guidance-empowering learners to develop confidence, speed, and a lifelong love for mathematics.
Related Articles
Book a FREE Demo ClassBook Now →