Q-There are $n$ points in a plane, no three of which collinear. Find the number of diagonals in a polygon of $n$ sides.
Note I found error was with formula used to find number of triangles.
My attempt
In $n$ points there are ${n}\choose{3}$ triangles.
So, a polygon formed by ${n}\choose{3}$ triangles will have ${{n}\choose{3}} + 2$ sides (I got this result by noticing series like square have 2 triangles, pentagon have 3 triangles,…..)
And a polygon of $n$ sides have $\frac{n(n-3)}{2}$ diagonals .
Hence ${{n}\choose{3}} + 2$ sides will have $\frac{1}{2} \Big[\big( {{n}\choose{3}}\big[{{n}\choose{3}} + 2\big] + 2\big) -3\Big]$ diagonals .
But in textbook it's answer is ${{n}\choose{2}}-n$
What mistake I had done. Please help me to find out error
Please note that I am a highschool student seeking help from teachers, so please don't close my question.
Thanks everyone for paying attention to my question!!!!!
Best Answer
If you insist to make a conclusion starting from the number of triangles...
Say that you have $n$ points: $A_1, A_2, ..., A_n$.
These points define $\binom n3$ triangles. The total number of edges in all these triangles is: $3\times\binom n3$. However each edge is counted several times. For example, edge $A_1A_2$ appears in triangles $A_1A_2A_3$, $A_1A_2A_4$, ..., $A_1A_2A_n$ which means that each edge appears exactly $n-2$ times in all possible triangles.
So the total number of lines is actually:
$$\frac{3\times \binom n3}{n-2}$$
Not all lines are diagonals. You get the number of diagonas by subtracting the number of polygon sides $n$ from the total count of lines:
$$\frac{3\times \binom n3}{n-2}-n=\frac{3\times\frac{n(n-1)(n-2)}{3\times2\times1}}{n-2}-n=\frac{n(n-1)}{2}-n=\binom n2-n$$
The most complicated way to count the number of diagonals, but you asked for it :)