# Difference between revisions of "2017 AIME II Problems/Problem 13"

## Problem

For each integer $n\geq3$, let $f(n)$ be the number of $3$-element subsets of the vertices of the regular $n$-gon that are the vertices of an isosceles triangle (including equilateral triangles). Find the sum of all values of $n$ such that $f(n+1)=f(n)+78$.

## Solution

Considering $n \pmod{6}$, we have the following formulas:

Even and a multiple of 3: $\frac{n(n-4)}{2} + \frac{n}{3}$ Even and not a multiple of 3: $\frac{n(n-2)}{2}$ Odd and a multiple of 3: $\frac{n(n-3)}{2} + \frac{n}{3}$ Odd and not a multiple of 3: $\frac{n(n-1)}{2}$

Considering the six possibilities $n \equiv 0,1,2,3,4,5 \pmod{6}$ and solving, we find that the only valid solutions are $n = 36, 52, 157$, from which the answer is $36 + 52 + 157 = \boxed{245}$.

 2017 AIME II (Problems • Answer Key • Resources) Preceded byProblem 12 Followed byProblem 14 1 • 2 • 3 • 4 • 5 • 6 • 7 • 8 • 9 • 10 • 11 • 12 • 13 • 14 • 15 All AIME Problems and Solutions