2007 iTest Problems/Problem 54

Revision as of 03:53, 8 October 2014 by Timneh (talk | contribs) (Created page with "== Problem == Let <math>T=\text{TNFTPP}</math>. Consider the sequence <math>(1, 2007)</math>. Inserting the difference between <math>1</math> and <math>2007</math> between them,...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Problem

Let $T=\text{TNFTPP}$. Consider the sequence $(1, 2007)$. Inserting the difference between $1$ and $2007$ between them, we get the sequence $(1, 2006, 2007)$. Repeating the process of inserting differences between numbers, we get the sequence $(1, 2005, 2006, 1, 2007)$. A third iteration of this process results in $(1, 2004, 2005, 1, 2006, 2005, 1, 2006, 2007)$. A total of $2007$ iterations produces a sequence with $2^{2007}+1$ terms. If the integer $4T$ (that is, $4$ times the integer $T$) appears a total of $N$ times among these $2^{2007}+1$ terms, find the remainder when $N$ gets divided by $2007$.

Solution