# Difference between revisions of "2021 AMC 12B Problems/Problem 20"

## Problem

Let $Q(z)$ and $R(z)$ be the unique polynomials such that$$z^{2021}+1=(z^2+z+1)Q(z)+R(z)$$and the degree of $R$ is less than $2.$ What is $R(z)?$

$\textbf{(A) }-z \qquad \textbf{(B) }-1 \qquad \textbf{(C) }2021\qquad \textbf{(D) }z+1 \qquad \textbf{(E) }2z+1$

## Solution 1

Note that $$z^3-1\equiv 0\pmod{z^2+z+1}$$ so if $F(z)$ is the remainder when dividing by $z^3-1$, $$F(z)\equiv R(z)\pmod{z^2+z+1}.$$ Now, $$z^{2021}+1= (z^3-1)(z^{2018} + z^{2015} + \cdots + z^2) + z^2+1$$ So $F(z) = z^2+1$, and $$R(z)\equiv F(z) \equiv -z\pmod{z^2+z+1}$$ The answer is $\boxed{\textbf{(A) }-z}.$

## Solution 2 (Somewhat of a long method)

One thing to note is that $R(z)$ takes the form of $Az + B$ for some constants A and B. Note that the roots of $z^2 + z + 1$ are part of the solutions of $z^3 -1 = 0$ They can be easily solved with roots of unity: $$z^3 = 1$$ $$z^3 = e^{i 0}$$ $$z = e^{i 0}, e^{i \frac{2\pi}{3}}, e^{i -\frac{2\pi}{3}}$$ $$\newline$$ Obviously the right two solutions are the roots of $z^2 + z + 1 = 0$ We substitute $e^{i \frac{2\pi}{3}}$ into the original equation, and $z^2 + z + 1$ becomes 0. Using De Moivre's theorem, we get: $$e^{i\frac{4042\pi}{3}} + 1 = A \cdot e^{i \frac{2\pi}{3}} + B$$ $$e^{i\frac{4\pi}{3}} + 1 = A \cdot e^{i \frac{2\pi}{3}} + B$$ Expanding into rectangular complex number form: $$\frac{1}{2} - \frac{\sqrt{3}}{2} i = (-\frac{1}{2}A + B) + \frac{\sqrt{3}}{2} i A$$ Comparing the real and imaginary parts, we get: $$A = -1, B = 0$$ The answer is $\boxed{\textbf{(A) }-z}$. ~Jamess2022(burntTacos;-;)

~ pi_is_3.14