<s>[INST] Let $a = \frac{1 + \sqrt{2009}}{2}$ . Find the value of $(a^3 - 503a - 500)^5$ . 
Let $a = \frac{1 + \sqrt{2009}}{2}$ . Find the value of $(a^3 - 503a - 500)^5$ .

What I Tried: We have :-
$$ (a^3 - 503a - 500)^5 = [a(a^2 - 3) - 500(a - 1)]^5$$
$$= \Bigg(\Bigg[\frac{1 + \sqrt{2009}}{2}\Bigg]\Bigg[\frac{1009 + \sqrt{2009}}{2}\Bigg] - 500\Bigg[\frac{\sqrt{2009} - 1}{2}\Bigg]\Bigg)^5$$
$$= \Bigg[\Bigg(\frac{1010\sqrt{2009} + 3018}{2}\Bigg)\Bigg] - 250(\sqrt{2009} - 1)\Bigg]^5$$
$$=(505\sqrt{2009} + 1509 - 250\sqrt{2009} - 250)^5$$
$$= (250\sqrt{2009} - 1259)^5$$
However, the answer given is $32$, so there could have been more simplifications. 
As a question, where did I go wrong? Also can anyone give me some simpler way of solving this?
 [/INST] Your working leads to the answer. Here is the correction -
$a = \frac{1 + \sqrt{2009}}{2}$
$a^2 - 3 = \frac{999 + \sqrt{2009}}{2}$
$a (a^2 - 3) = 752 + 250 \sqrt {2009}$
$500 (a + 1) = 250 ( \sqrt {2009} + 3)$
$a(a^2-3) - 500(a+1) = 2$
So $(a^3 - 503a - 500)^5 = 32$
</s>