Associated Topics || Dr. Math Home || Search Dr. Math

### Diagonals in 3D Figures

```
Date: 06/21/99 at 10:48:26
From: Jamie Vassallo
Subject: Diagonals in 2D and 3D shapes

I am having great difficulty with math and require assistance. Could
you help? I have the formula n(n-3)/2, but I don't know how to justify
or prove it. Another thing is, could you please tell me the number of
diagonals in various 3D shapes, such as a tetrahedron, cube and so on.
Is there a formula for this or is it just coincidental? Thank you very
much for your help and I hope to hear from you soon.

Thank you.
Jamie
```

```
Date: 06/21/99 at 12:26:06
From: Doctor Peterson
Subject: Re: Diagonals in 2D and 3D shapes

Hi, Jamie.

Let's think how we can count the diagonals in a polygon. Pick any
vertex; there are N ways to do that. Now pick any vertex to go to
EXCEPT the two neighbors (and the point itself, of course). How many
ways are there to do that? When you finish, you'll have counted every
diagonal - except that you will have counted each one twice, once
starting from each end. Taking that into account will give you the
formula.

Now, for a general polyhedron, the same method would work except for
one detail: there can be any number of "neighbors" to any vertex. But
you can use a similar method to find the TOTAL number of segments that
can be drawn between any two vertices; then you can just subtract from
your count the number of edges in the polyhedron. Since you can make
different polyhedra with the same number of vertices but different
numbers of edges, you can't give an answer based only on the number of
vertices.

Have you looked at a tetrahedron and tried to count the diagonals? Try
it - you'll find there aren't any. For a cube, there will be two on
each of the six faces, and three going through the center. See if that
agrees with the formula you come up with.

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```

```
Date: 06/22/99 at 13:32:17
From: jamie vassallo
Subject: Diagonals in 3D objects

diagonals, the cube has 15 and then the pentagonal prism has either 28
or 32. Can you tell me the next 3 or 4 terms so that I can work out
the sequence? Thank you very much.

Jamie Vassallo
```

```
Date: 06/22/99 at 17:03:30
From: Doctor Peterson
Subject: Re: Diagonals in 3D objects

Hi again, Jamie.

There are a couple of problems in trying to figure this out by making
a list. For one thing, there really is no "sequence": you can't put
all the possible polyhedra in an ordered list as you can with
polygons, because there are lots of different ways to connect N
vertices to make a shape. Secondly, even if you can see a pattern in
the jumble of shapes you consider, it will be hard to be sure it's a
real pattern if you haven't given thought to the reason for the
pattern. It's much easier to find patterns if you look for a pattern
in the way you count, rather than just make a list of numbers and then
look for a pattern there.

Yet it will be worthwhile for you to make a list of shapes and try to
count the edges and the diagonals of each, in order to get to know
them. You'll want to get a feel for how diagonals work, so it wouldn't
be helpful for me to just give you a list - you need to do some
counting on your own. But I'll start your list to give you some ideas
on what to look for and how to count the diagonals.

Let's list several characteristics of each shape: the number of
Vertices (V), Edges (E), Faces (F), and Diagonals (D).

Tetrahedron
V   E   F   D
--- --- --- ---
4   6   4   0

+
/ \\
/   \ \
/     \  \
/       \   \
/       __\__ +
/____----   \ /
+-------------+

Since every point is connected to every other point, there's nothing
left to be a diagonal.

Square pyramid
V   E   F   D
--- --- --- ---
5   8   5   2

+
/ \\
/   \ \
/     \  \
/       \   \
/---------\---+
/           \ /
+-------------+

The top point is connected to all the others, so the only diagonals
are the two in the base.

Triangular hexahedron
(Twin tetrahedra)
V   E   F   D
--- --- --- ---
5   9   6   1

+
/ \\
/   \ \
/     \  \
/       \   \
/       __\__ +
/____----   \ /
+-------------+
\           /
\         /
\       /
\     /
\   /
\ /
+

The top and bottom points are connected to everything but each other;
the "equatorial" points are connected to everything, leaving only the
one diagonal.

Notice that these last two polyhedra have the same number of vertices,
but different numbers of edges. But the sum of the number of edges and
the number of diagonals is the same for both, because that's just the
total number of lines you can draw connecting any two points.

Octahedron
V   E   F   D
--- --- --- ---
6  12   8   3

+
/ \\
/   \ \
/     \  \
/       \   \
/---------\---+
/ \         \ /
+-------------+
\  \      //
\ \    /
\\  /
+

Each point is connected to every point except the opposite vertex; the
three pairs of opposites form three diagonals.

Pentagonal pyramid
V   E   F   D
--- --- --- ---
6  10   6   5

+
/|\
/|||\
/ ||| \
/ | | | \
/  | | |  \
/  |  |  |  \
/___|_-+-_|__ \
+-  |       |  -+
\  |       |  /
\|         |/
+---------+

The top point is connected to all the others, so the only diagonals
are the five in the base.

Triangular prism
V   E   F   D
--- --- --- ---
6   9   5   6

+
/    |\
/          | \
+------------------+
|               |  |
|               |  |
|               |  |
|               |  |
|               +  |
|          /     \ |
|    /            \|
+------------------+

The diagonals are all in the three sides.

I've given you three different polyhedra with six vertices. It gets a
lot worse with more vertices!

I'm not sure why you gave two numbers for the pentagonal prism; the
correct count, according to my formula, is 30: 5 in each base, 2 in
each of 5 sides, and 2 reaching from each vertex on one base to
vertices on the other base through the interior.

The important thing to see is that you can't just look at V and tell
me what D will be. You need to know at least two things about the
shape. There is a formula that relates D+E to V, which is what I
suggested to you in my last response; and another that relates V+F to
E. Putting these together, it turns out that D+F is determined by V.
So if you know V and either E or F, you can figure out what D is.

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```

```
Date: 06/23/99 at 06:17:47
From: James Vassallo
Subject: Thank you Dr Peterson

Dear Dr Peterson,

Thank you very much for your help, it is greatly appreciated, I now
understand more fully what my task actually is. Thank you once again
for all your time with me.

Jamie Vassallo
```

```
Date: 06/26/99 at 06:16:38
From: James Vassallo
Subject: Pyramids

Thank you for your faith in me, this is just a check, I have found
your information on pyramids useful, and have come up with the formula

(n-1)(n-4)
n = ----------
2

Is this correct? Just one other query; is there a link between the
formula for pyramids and prisms, or is there one formula linking all
3D shapes together?

Thank you.
Jamie
```

```
Date: 06/26/99 at 16:38:23
From: Doctor Peterson
Subject: Re: Pyramids

Hi, Jamie.

Yes, you have the right formula for a pyramid. I'm not sure how you
found it, but there's a very easy way: all the diagonals will be in
the base, since the apex is already connected to all other vertices;
so you just have to put n-1 into the formula for diagonals of a
polygon.

You can do something similar for a prism: many of the diagonals will
be in one or the other of the bases, and the rest can be easily
counted because they go from a vertex on the top to a vertex on the
bottom. I'm not sure there would be a direct link to the pyramid
formula, but they certainly aren't unrelated either.

There is a very simple general formula for the total number of lines
that can be drawn between any two of a set of n points in space, and
this will be the sum of the number of edges of the polyhedron and the
number of diagonals. You can easily derive your formula for a pyramid,
or the one for a prism, from this by coming up with a formula for the
number of edges. For example, for a pyramid, the number of edges is
just 2(n-1), since there are n-1 edges in the base, and the same
number of edges from the base to the apex.

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```

```
Date: 07/13/99 at 10:43:18
From: Jamie Vassallo
Subject: Diagonals

Dear Dr Peterson,

It's me again. I have yet another problem which I hope that you can
help me with. The problem has to do with the formula for prisms. I
think that I may have this formula but I am unsure. The formula I have
is n(n-4)/2. That is the factored version, I can't find the square on
my computer, so I can't give the expanded. The way that I sort of got
it was by identifying the number of diagonals in a prism, with an x +
y + z method, where x = z. X and z are the diagonals in the two end
polygons, and y is equal to the number of diagonals in the middle.
This is what I have:

n(n-3) + n(n-1) + n(n-3)
------            ------
2                 2

That is what I have. I am not sure about what the n(n-1) is, what it
stands for. Is it the same as with the pyramids, the number of
vertices multiplied by the number of vertices minus the apex? Because
in a pyramid, no diagonals go to the apex, without going along the
edges, and that is not the case in prisms. I have tried the formula
above on various figures and it works. So that is the testing I've
done. Then the proof would be finding it through the x + y + z method,
which I am not sure of, but I think I am close to finding it. Now the
area that I need your help with is checking it. Also help me, if you
could, in justifying the formula. I don't understand what each part of
it means. Another question that I have is that I have seen the x + y +
z, not written over 2, but rewritten as 1/2 n. Am I right in assuming
that this is just to get rid of the 'over 2'?  Is the n(n-1) over 2,
or not? That really confuses me.

Thanks once again for your help and look forward to hearing your
response.

Jamie Vassallo
```

```
Date: 07/13/99 at 12:20:03
From: Doctor Peterson
Subject: Re: Diagonals

Hi, Jamie.

n(n-3) + n(n-1) + n(n-3)
------            ------
2                 2

The first and third parts, as you explained, are the number of
diagonals in the top and bottom. You're using n here, of course, not
for the total number of vertices in the prism, but for the number of
vertices in the base (which is the natural number to use here, but has
to be clearly stated to avoid confusion). The middle part is the
number of "body diagonals" crossing from the top to the bottom. It can
be easily explained: you can choose one of n vertices for the top end
of such a diagonal, and then have n-1 choices for the bottom end,
since any vertex except the one attached to the top end by an edge of
the prism will give you a diagonal. This gives n(n-1). You don't have
to divide by two here, as you do in working out the total number of
lines you can draw between two of n points (or the number of
handshakes between n people), because each diagonal is counted only
once: the diagonal from point A on the top and point B' on the bottom
is different from the one between points B and A'. When you count
handshakes, A shaking with B is the same as B shaking with A, so you
divide by 2.

To get from this to your n(n-4)/2, you need two steps.

n(n-3) + n(n-1) + n(n-3)
------            ------
2                 2

n^2 - 3n + 2n^2 - 2n + n^2 - 3n   4n^2-8n
= ------------------------------- = -------
2                     2

= 2n^2 - 4n = 2n(n-2)

Putting n = v/2, this becomes

4(v/2)^2 - 8(v/2)   v^2 - 4v   v(v-4)
----------------- = -------- = ------
2              2        2

as you said. I suspect that this is where those 1/2 n's came from that
you saw: n must have been what I'm calling v, and n/2 was therefore
used where I put n.

The fact that you didn't mention that the n in this formula is
different from the n in the longer version tells me that you probably
don't understand the details about the formulas, but just got them
from two different sources and are trying to make them fit together.
I hope you'll think through this carefully so you really know how it
all works, and can reconstruct it for yourself.

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```

```
Date: 07/19/99 at 06:12:12
From: Jamie Vassallo
Subject: Re: Diagonals

Dear Dr Peterson,

You sent me that email showing that:

n(n-3) + n(n-1) + n(n-3)
------            ------
2                 2

= n^2 - 3n + 2n^2 - 2n + n^2 - 3n
-------------------------------
2

What I am unsure of is, how does the n(n-1) become the 2n^2 - 2n? I've
looked at multiplying by one half, but that just gives me n(n-1)/2. I
know that the first n (outside of the bracket) must be multiplied by 2
somewhere, but I don't follow how and why.

The last query that I have is: at the bottom of your last e-mail, you
said "putting n = v/2." Why do you do this? That is what I can't
understand. Thanks for your help and I look forward to hearing from
you.

Jamie
```

```
Date: 07/19/99 at 09:02:48
From: Doctor Peterson
Subject: Re: Diagonals

Hi, Jamie.

I've never asked you or your classmates how much you know of algebra,
though I've wondered whether some of you might have trouble with some
of the tools you need to work comfortably with these formulas. I wrote
assuming you'd ask if you didn't follow some steps. I'll be happy to
explain a little more deeply.

Here's what I wrote:

n(n-3) + n(n-1) + n(n-3)
------            ------
2                 2

n^2 - 3n + 2n^2 - 2n + n^2 - 3n   4n^2-8n
= ------------------------------- = -------
2                     2

= 2n^2 - 4n = 2n(n-2)

Here are the steps I left out between the first and second
expressions:

n(n-3) + 2n(n-1) + n(n-3)   n(n-3) + 2n(n-1) + n(n-3)
... = ------   -------   ------ = ------------------------- = ...
2         2        2                  2

Do you see what I did? Before adding the three expressions, I had to
write them all with the same denominator. Since the middle part didn't
have a denominator, I just multiplied it by 2/2. Then I combined them
into one fraction, after which I could multiply out each part using
the distributive property, and then add like terms. (I deliberately
left out these steps, because if you're good at algebra I'd be talking
down to you, as well as doing work for nothing, and if you aren't, it
would be a good exercise to figure out what I was doing rather than
have every step shown.)

As for v and n: changing variables can be pretty hard to follow; it
requires that you be really comfortable with the idea of variables
themselves. What's happening is that you want to get an expression for
the number of diagonals in terms of the total number of vertices in
the prism, whereas the formulas we'd been working with up to that
point were based on n being the number of vertices in each of the two
polygons that form the prism. For example, for a triangular prism, n
is 3, but the total number of vertices in the prism is 2*3 = 6. Our
n(n-3)/2 is the number of diagonals in one base of the prism, which is
a polygon with n vertices. But the number of vertices in the whole
prism is v = 2n, so in order to get a formula using v, we replace n
everywhere with its equivalent in terms of v, n = v/2. I'd actually
prefer leaving the formula in terms of n, which seems to me a natural
way to describe a prism; but your goal is to find formulas for
different polyhedra in a form that can be compared from one to the
next, so you wanted to get them all in terms of v.

I hope that helps; if not, keep asking. Good questions from someone
who cares about understanding are always welcome!

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```

```
Date: 07/19/99 at 13:10:19
From: Jamie Vassallo
Subject: Re: Diagonals

This is my last query; then I've figured the whole thing out. Can you
tell me how many diagonals there are in a dodecahedron and an
icosahedron?  Or can you tell me where on the Internet I can find that

Jamie
```

```
Date: 07/19/99 at 16:59:34
From: Doctor Peterson
Subject: Re: Diagonals

Hi, Jamie.

It's time to introduce you to a different approach to the prism, which
you can apply to these regular polyhedra.

Regularity means that some or all features of a shape are true
everywhere. A prism is not a regular polyhedron, because not all faces
are the same shape and not all edges are the same length, and so on;
but it is regular in one way: at every vertex you find the same number
of edges, namely two going to adjacent vertices in the same base, and
one going to the corresponding vertex in the other base. Luckily,
that's the kind of regularity that helps most with this problem.

You can use this to do the same thing you did originally in counting
the diagonals of a polygon. If there are v vertices in all, you can
pick any of them to start a diagonal, and then you go from there to
any vertex except itself and the three other vertices to which it is
connected, giving you (v-4) choices for each of the (v) starting
vertices. Since you will have counted each vertex twice this way, the
total number of diagonals is

v(v-4)
D = ------
2

Sound familiar?

You can use the same method for any regular polyhedron. See what you
get! (You'll find that regular polyhedra are pretty boring.) Then see
if you can actually visualize where these diagonals are and see that
you counted them correctly.

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```

```
Date: 07/20/99 at 08:21:53
From: Jamie Vassallo
Subject: Re: Diagonals

Dear Dr Peterson,

Thank you for the e-mails. I find that I now understand it all, except
for two small areas, which I hope you can help me with. The first is:
using the prism formula and the notes you gave me, I worked out the
number of diagonals. Can you check my data, see if they are correct,
as I have two conflicting sources, the Internet and also an
encyclopedia:

Vertices   Edges   Faces   Diagonals
Dodecahedron      12       30      12         48
Icosahedron       20       30      20        160

If those are correct, which I believe them to be, I have come up with
this logic, please tell me if I'm right.

v(v-j)
------
2

1. v  This represents the total number of vertices in the polyhedron

2. v-j  The total number of vertices minus j, where j is equal to the
number of diagonals unable to be drawn to from any given starting
vertex. For instance in the cube, from any given vertex, you are
unable to draw diagonals to 3 vertices as they are connected with
edges. Then you can't draw a diagonal to the vertex from where you
started. So it would be the total number of vertices minus 4. This
value would be (for all except two polyhedra) the shape of which the
polyhedron is made from plus 1. The exceptions are the cube, where the
1 need not be added; and the octahedron, where it is needs to be added
to 2.

3. 2  It is placed over two because by using this method you count
each diagonal twice.

I would be grateful to hear from you soon.
Jamie Vassallo
```

```
Date: 07/20/99 at 08:50:01
From: Doctor Peterson
Subject: Re: Diagonals

Hi, Jamie.

This sounds fine except for the details of how you find j. I would
express the formula not in terms of j, which is not an obvious number,
but in terms of something like the number of edges that meet at each
vertex. It has nothing to do with the shape of the faces. You might
like to make a chart for all the regular polyhedra and a few prisms,
showing not only V, E, and F, but also the number of edges per face
and the number of edges per vertex. Then show what your "j" is, and
see how it's related. Or just think carefully about what it means to
be unable to draw a diagonal to a vertex.

While you're studying polyhedra, you might want to look at several
sites on that subject; there are a lot of fascinating facts about
them, some of which might be relevant:

George Hart's Virtual Polyhedra
http://www.georgehart.com/virtual-polyhedra/vp.html
Alexander Bogomolny's Regular Polyhedra
http://www.cut-the-knot.org/do_you_know/polyhedra.shtml

- Doctor Peterson, The Math Forum
http://mathforum.org/dr.math/
```
Associated Topics:
High School Geometry
High School Polyhedra

Search the Dr. Math Library:

 Find items containing (put spaces between keywords):   Click only once for faster results: [ Choose "whole words" when searching for a word like age.] all keywords, in any order at least one, that exact phrase parts of words whole words

Submit your own question to Dr. Math
Math Forum Home || Math Library || Quick Reference || Math Forum Search