Define
\[ S = \tan^{-1}(2020) + \sum_{j = 0}^{2020} \tan^{-1}(j^2 - j + 1). \]
Then $S$ can be written as $\frac{m \pi}{n}$, where $m$ and $n$ are relatively prime positive integers. Find $m + n$.

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