Define $f(x) = x^2 - 45x + 21$. Find the sum of all positive integers $n$ with the following property: there is exactly one integer $i$ in the set $\{1, 2, \ldots, n\}$ such that $n$ divides $f(i)$.

Let's think step by step and output the final answer within \boxed{}.
user