Counting the Number of Diagonals of N-sided Polygon

Abrar Shariar
The Startup
Published in
4 min readOct 25, 2019

--

Photo by sutirta budiman on Unsplash

We start our journey from quadrilateral since triangles are the most lamest of all polygons (in terms of diagonals of course!). As well taught in the classroom, we know a quadrilateral have 2 diagonals. Now, can we find the number of diagonals of an N-sided Polygon, where N = any positive integer? In fact, there seems to be a nifty trick to count the number of diagonals of any polygon. Don’t be intimidated cause we are not going to dive into any tedious calculation, rather use some basic intuitive steps. Let’s see some polygons in action:

A sweet pentagon with 5 diagonals

Here, we have a pentagon ABCDE. Now, if we start drawing diagonals from the vertex A, we can draw 2 diagonals connecting D and C to form AD and AC respectively. Remember we can only consider non-adjacent vertices when drawing diagonals. Again, taking vertex B, we connect E and D to form 2 more diagonals: BE and BD.

Now, consider the vertex C, what are the vertices we have in option to connect? We can connect with E, to form CE and with A to form CA. Wait a sec! Didn’t we consider CA earlier when drawing diagonals from A? Indeed we have, since CA = AC. Since double counting will be a blot in our mathematical sense, we only…

--

--