Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The question is how many triangles are there in the following picture?

How many triangles?

I have thought to solve it by creating a formula based on the angles of the lines starting from the bottom of each side. I don't get it right though. Any clues/ideas would be appreciated.

share|cite|improve this question
(+1) Good question. I used to wondered whether there was a relatively systematic way of doing those questions. – Ragib Zaman Nov 10 '11 at 11:14
I found 110 up till now. How many are there? – Raskolnikov Nov 10 '11 at 11:25
Still figuring it out. – Dimme Nov 10 '11 at 12:25
"...there was a time when the study of configurations was considered the most important branch of all geometry." Anschauliche geometrie, Hilbert & Cohn-Vossen, p. 95. – Robert Haraway Nov 10 '11 at 22:33
you can easily solve by: – user153627 May 27 '14 at 10:22

@Sp3000 is right, this is actually $PE-163$, and your particular case is given in the problem statement $ T(2) = 104.$

But if you are looking for a general formula to count the number of triangles in higher order then check here, (spoiler for the original PE problem).

share|cite|improve this answer
Thank you it was very helpful. – Dimme Nov 10 '11 at 18:38

You can model this using the graph theory. Then make an algorithm that will solve the problem.

Every line that ends connecting more than one line is a node. Find all nodes. Then start from one and look for graphs that contain 3 elements.

share|cite|improve this answer
Good answer. But solving this on paper seems taking quite some time. What if we try to create a formula. Each lines creates at least 2 triangles. The question is which lines to count? End-to-end? Hmmm thanks for your answer anyway. I will give it a try when getting home. – Dimme Nov 10 '11 at 12:22
up vote 6 down vote accepted

I think I found an easier solution for this specific problem without complicating it too much.

We have one basic kind of triangle, and that is the one that our big triangle contains 4 of. Let's call that order 1.

If we count the triangles inside order 1, we find out that they are 16. They are not so many so we can actually count them manually.

So long we have 16 triangles times 4, 64 triangles.

Now by combining 4 order-1 triangles we get new triangles that originate from the combination.

Lets count the new triangles for ONE side only. Be careful because some of them can be mirrored and some cannot. Actually there is only one that cannot be mirrored.

That gives us 13 new triangles for ONE side only from the combination of order 1 into order 2.

Now we have 13 more for every time we turn the big triangle around. So now we have:

16*4 + 13*3 = 103

Don't forget the big triangle!

16*4 + 13*3 + 1 = 104

Woho, solved! =)

share|cite|improve this answer

Another longish way would be to label all vertices and check if all triples give you triangles.

share|cite|improve this answer
+1, interesting approach. – NoChance Nov 10 '11 at 14:09

This forms part of a problem on the Project Euler website and as you can see your particular example is $T(2) = 104.$

share|cite|improve this answer
Thought I recognised it as a PE problem. – Peter Taylor Nov 10 '11 at 13:10

Using Burnside's lemma, the number of triangles is equal to $6n-22$ where $n$ is the number of orbits of the action of $D_3$ on the set of triangles.

To count them, notice that :

  • Every orbit contains one the four triangles in the bottom right-hand corner of the big triangle.
  • Two triangles in the same orbit are isometric.

So you only need to count twenty-one orbits rather than one hundred and four triangles.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.