Difference between revisions of "2012 AIME I Problems/Problem 15"

(Solution)
(Solution)
Line 19: Line 19:
 
Thus, we have <math>a-1</math>, <math>a</math>, and <math>a+1</math> are relatively prime to <math>n</math>. We must find all <math>n</math> for which such an <math>a</math> exists. <math>n</math> cannot obviously not be a multiple of <math>2</math> or <math>3</math>, but for any other <math>n</math>, we can set <math>a = n-2</math>, and then <math>a-1 = n-3</math> and <math>a+1 = n-1</math>. All three of these will be relatively prime to <math>n</math>, since two numbers <math>p</math> and <math>q</math> are relatively prime iff <math>p-q</math> is relatively prime to <math>p</math>. In this case, <math>1</math>, <math>2</math>, and <math>3</math> are all relatively prime to <math>n</math>, so <math>a = n-2</math> works.
 
Thus, we have <math>a-1</math>, <math>a</math>, and <math>a+1</math> are relatively prime to <math>n</math>. We must find all <math>n</math> for which such an <math>a</math> exists. <math>n</math> cannot obviously not be a multiple of <math>2</math> or <math>3</math>, but for any other <math>n</math>, we can set <math>a = n-2</math>, and then <math>a-1 = n-3</math> and <math>a+1 = n-1</math>. All three of these will be relatively prime to <math>n</math>, since two numbers <math>p</math> and <math>q</math> are relatively prime iff <math>p-q</math> is relatively prime to <math>p</math>. In this case, <math>1</math>, <math>2</math>, and <math>3</math> are all relatively prime to <math>n</math>, so <math>a = n-2</math> works.
  
Now we simply count all <math>n</math> that are not multiples of <math>2</math> or <math>3</math>, which is easy by PIE. We get a final answer of <math>998 - (499 + 333 - 166) = 332</math>.
+
Now we simply count all <math>n</math> that are not multiples of <math>2</math> or <math>3</math>, which is easy by PIE. We get a final answer of <math>998 - (499 + 333 - 166) = \boxed{332}</math>.
  
 
== See also ==
 
== See also ==
 
{{AIME box|year=2012|n=I|num-b=14|after=Last Problem}}
 
{{AIME box|year=2012|n=I|num-b=14|after=Last Problem}}

Revision as of 10:54, 17 March 2012

Problem 15

There are $n$ mathematicians seated around a circular table with $n$ seats numbered $1,$ $2,$ $3,$ $...,$ $n$ in clockwise order. After a break the again sit around the table. The mathematicians note that there is a positive integer $a$ such that

    ($1$) for each $k,$ the mathematician who was seated in seat $k$ before the break is seated in seat $ka$ after the break (where seat $i + n$ is seat $i$);
    ($2$) for every pair of mathematicians, the number of mathematicians sitting between them after the break, counting in both the clockwise and the counterclockwise directions, is different from either of the number of mathematicians sitting between them before the break.

Find the number of possible values of $n$ with $1 < n < 1000.$

Solution

It is a well-known fact that the set $0, a, 2a, ... (n-1)a$ forms a complete set of residues if and only if $a$ is relatively prime to $n$.

Thus, we have $a$ is relatively prime to $n$. In addition, for any seats $p$ and $q$, we must have $ap - aq$ not be equivalent to either $p - q$ or $q - p$ modulo $n$ to satisfy our conditions. These simplify to $(a-1)p \equiv (a-1)q$ and $(a+1)p \equiv (a+1)q$ modulo $n$, so multiplication by both $a-1$ and $a+1$ must form a complete set of residues mod $n$ as well.

Thus, we have $a-1$, $a$, and $a+1$ are relatively prime to $n$. We must find all $n$ for which such an $a$ exists. $n$ cannot obviously not be a multiple of $2$ or $3$, but for any other $n$, we can set $a = n-2$, and then $a-1 = n-3$ and $a+1 = n-1$. All three of these will be relatively prime to $n$, since two numbers $p$ and $q$ are relatively prime iff $p-q$ is relatively prime to $p$. In this case, $1$, $2$, and $3$ are all relatively prime to $n$, so $a = n-2$ works.

Now we simply count all $n$ that are not multiples of $2$ or $3$, which is easy by PIE. We get a final answer of $998 - (499 + 333 - 166) = \boxed{332}$.

See also

2012 AIME I (ProblemsAnswer KeyResources)
Preceded by
Problem 14
Followed by
Last Problem
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
All AIME Problems and Solutions