Difference between revisions of "2007 AMC 12A Problems/Problem 22"
(→Solution 5 (Rigorous)) |
|||
| Line 72: | Line 72: | ||
==Solution 5 (Rigorous)== | ==Solution 5 (Rigorous)== | ||
| − | Let the number of digits of | + | Let the number of digits of <math>n</math> be <math>m</math>. If <math>m = 5</math>, <math>n</math> will already be greater than <math>2007</math>. Notice that <math>S(n)</math> is always at most <math>9m</math>. Then if <math>m = 3</math>, <math>n</math> will be at most <math>999</math>, <math>S(n)</math> will be at most <math>27</math>, and <math>S(S(n))</math> will be even smaller than <math>27</math>. Clearly we cannot reach a sum of <math>2007</math>, unless <math>m = 4</math> (i.e. <math>n</math> has <math>4</math> digits). |
| − | + | Then, let <math>n</math> be a four digit number in the form <math>1000a + 100b + 10c + d</math>. Then <math>S(n) = a + b + c + d</math>. | |
| + | |||
| + | <math>S(S(n))</math> is the sum of the digits of <math>a + b + c + d</math>. We can represent <math>S(S(n))</math> as the sum of the tens digit and the ones digit of <math>S(n)</math>. The tens digit in the form of a decimal is | ||
| + | |||
| + | |||
| + | <math>\frac{a + b + c + d}{10}</math>. | ||
| + | |||
| + | |||
| + | To remove the decimal portion, we can simply take the floor of the expression, | ||
| + | |||
| + | |||
| + | <math>\lfloor\frac{a + b + c + d}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | Now that we have expressed the tens digit, we can express the ones digit as <math>S(S(n)) -10</math> times the above expression, or | ||
| + | |||
| + | |||
| + | <math>a + b + c + d - 10\lfloor\frac{a + b + c + d}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | Adding the two expressions yields the value of <math>S(S(n))</math> | ||
| + | |||
| + | |||
| + | <math> = a + b + c + d - 9\lfloor\frac{a + b + c + d}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | Combining this expression to the ones for <math>n</math> and <math>S(n)</math> yields | ||
| + | |||
| + | |||
| + | <math>1002a + 102b + 12c + 3d - 9\lfloor\frac{a + b + c + d}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | Setting this equal to <math>2007</math> and rearranging a bit yields | ||
| + | |||
| + | |||
| + | <math>12c + 3d = 2007 - 1002a - 102b + 9\lfloor\frac{a + b + c + d}{10}\rfloor</math> | ||
| + | |||
| + | <math>\Rightarrow</math> <math>4c + d = 669 - 334a - 34b + 3\lfloor\frac{a + b + c + d}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | (The reason for this slightly weird arrangement will soon become evident) | ||
| + | |||
| + | |||
| + | Now we examine the possible values of <math>a</math>. If <math>a \ge 3</math>, <math>n</math> is already too large. <math>a</math> must also be greater than <math>0</math>, or <math>n</math> would be a <math>3</math>-digit number. Therefore, <math>a = 1 \, \text{or} \, 2</math>. Now we examine by case. | ||
| + | |||
| + | If <math>a = 2</math>, then <math>b</math> and <math>c</math> must both be <math>0</math> (otherwise <math>n</math> would already be greater than <math>2007</math>). Substituting these values into the equation yields | ||
| + | |||
| + | |||
| + | <math>d = 1 + 3\lfloor\frac{2 + d}{10}\rfloor</math> | ||
| + | |||
| + | <math>\Rightarrow</math> <math>d=1</math>. | ||
| + | |||
| + | |||
| + | Sure enough, <math>2001 + (2+1) + 3=2007</math>. | ||
| + | |||
| + | Now we move onto the case where <math>a = 1</math>. Then our initial equation simplifies to | ||
| + | |||
| + | |||
| + | <math>4c + d = 335 - 34b + 3\lfloor\frac{1 + b + c + d}{10}\rfloor</math> | ||
| + | |||
| + | |||
| + | Since <math>c</math> and <math>d</math> can each be at most <math>9</math>, we substitute that value to find the lower bound of <math>b</math>. Doing so yields | ||
| + | |||
| + | |||
| + | <math>34b \ge 290 + 3\lfloor\frac{19 + b}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | The floor expression is at least <math>3\lfloor\frac{19}{10}\rfloor=3</math> , so the right-hand side is at least <math>293</math>. Solving for <math>b</math>, we see that <math>b \ge 9 </math> <math>\Rightarrow</math> <math>b=9</math>. Again, we substitute for <math>b</math> and the equation becomes | ||
| + | |||
| + | |||
| + | <math>4c + d = 29 + 3\lfloor\frac{10 + c + d}{10}\rfloor</math> | ||
| + | |||
| + | <math>\Rightarrow</math> <math>4c + d = 32 + 3\lfloor\frac{c + d}{10}\rfloor</math>. | ||
| + | |||
| + | |||
| + | Just like we did for <math>b</math>, we can find the lower bound of <math>c</math> by assuming <math>d = 9</math> and solving: | ||
| + | |||
| + | |||
| + | <math>4c + 9 \ge 29 + 3\lfloor\frac{c + 9}{10}\rfloor</math> | ||
| + | |||
| + | <math>\Rightarrow</math> <math>4c \ge 20 + 3\lfloor\frac{c + 9}{10}\rfloor</math> | ||
| + | |||
| + | |||
| + | The right hand side is <math>20</math> for <math>c=0</math> and <math>23</math> for <math>c \ge 1</math>. Solving for c yields <math>c \ge 6</math>. Looking back at the previous equation, the floor expression is <math>0</math> for <math>c+d \le 9</math> and <math>3</math> for <math>c+d \ge 10</math>. Thus, the right-hand side is <math>32</math> for <math>c+d \le 9</math> and <math>35</math> for <math>c+d \ge 10</math>. We can solve these two scenarios as systems of equations/inequalities: | ||
| + | |||
| + | <math>4c+d = 32</math> | ||
| + | |||
| + | <math>c+d \le 9</math> | ||
| + | |||
| + | and | ||
| + | |||
| + | <math>4c+d=35</math> | ||
| + | |||
| + | <math>c+d \ge 10</math> | ||
| + | |||
| + | Solving yields three pairs <math>(c, d):</math> <math>(8, 0)</math>; <math>(8, 3)</math>; and <math>(7, 7)</math>. Checking the numbers <math>1980</math>, <math>1983</math>, and <math>1977</math>; we find that all three work. Therefore there are a total of <math>4</math> possibilities for <math>n</math> <math>\Rightarrow</math> <math>\boxed{\text{D}}</math>. | ||
| + | |||
| + | Note: Although this solution takes a while to read (as well as to write) the actual time it takes to think through the process above is very short in comparison to the solution length. | ||
== See also == | == See also == | ||
Revision as of 16:20, 21 July 2020
- The following problem is from both the 2007 AMC 12A #22 and 2007 AMC 10A #25, so both problems redirect to this page.
Contents
Problem
For each positive integer
, let
denote the sum of the digits of
For how many values of
is
Solution
Solution 1
For the sake of notation let
. Obviously
. Then the maximum value of
is when
, and the sum becomes
. So the minimum bound is
. We do casework upon the tens digit:
Case 1:
. Easy to directly disprove.
Case 2:
.
, and
if
and
otherwise.
- Subcase a:
. This exceeds our bounds, so no solution here. - Subcase b:
. First solution.
Case 3:
.
, and
if
and
otherwise.
- Subcase a:
. Second solution. - Subcase b:
. Third solution.
Case 4:
. But
, and
clearly sum to
.
Case 5:
. So
and
(recall that
), and
. Fourth solution.
In total we have
solutions, which are
and
.
Solution 2
Clearly,
. We can break this into three cases:
Case 1:
- Inspection gives
.
Case 2:
,
(not to be confused with
),
- If you set up an equation, it reduces to
- which has as its only solution satisfying the constraints
,
.
Case 3:
,
,
- This reduces to
. The only two solutions satisfying the constraints for this equation are
,
and
,
.
The solutions are thus
and the answer is
.
Solution 3
As in Solution 1, we note that
and
.
Obviously,
.
As
, this means that
, or equivalently that
.
Thus
. For each possible
we get three possible
.
(E. g., if
, then
is a number such that
and
, therefore
.)
For each of these nine possibilities we compute
as
and check whether
.
We'll find out that out of the 9 cases, in 4 the value
has the correct sum of digits.
This happens for
.
Solution 4
- This solution is not a good solution, but is viable for in contest situations
Clearly
. Thus,
Now we need a bound for
. It is clear that the maximum for
(from
) which means the maximum for
is
. This means that
.
- Warning: This is where you will cringe badly
Now check all multiples of
from
to
and we find that only
work, so our answer is
.
Remark: this may seem time consuming, but in reality, calculating
for
values is actually very quick, so this solution would only take approximately 3-5 minutes, helpful in a contest.
Solution 5 (Rigorous)
Let the number of digits of
be
. If
,
will already be greater than
. Notice that
is always at most
. Then if
,
will be at most
,
will be at most
, and
will be even smaller than
. Clearly we cannot reach a sum of
, unless
(i.e.
has
digits).
Then, let
be a four digit number in the form
. Then
.
is the sum of the digits of
. We can represent
as the sum of the tens digit and the ones digit of
. The tens digit in the form of a decimal is
.
To remove the decimal portion, we can simply take the floor of the expression,
.
Now that we have expressed the tens digit, we can express the ones digit as
times the above expression, or
.
Adding the two expressions yields the value of
.
Combining this expression to the ones for
and
yields
.
Setting this equal to
and rearranging a bit yields
.
(The reason for this slightly weird arrangement will soon become evident)
Now we examine the possible values of
. If
,
is already too large.
must also be greater than
, or
would be a
-digit number. Therefore,
. Now we examine by case.
If
, then
and
must both be
(otherwise
would already be greater than
). Substituting these values into the equation yields
.
Sure enough,
.
Now we move onto the case where
. Then our initial equation simplifies to
Since
and
can each be at most
, we substitute that value to find the lower bound of
. Doing so yields
.
The floor expression is at least
, so the right-hand side is at least
. Solving for
, we see that
. Again, we substitute for
and the equation becomes
.
Just like we did for
, we can find the lower bound of
by assuming
and solving:
The right hand side is
for
and
for
. Solving for c yields
. Looking back at the previous equation, the floor expression is
for
and
for
. Thus, the right-hand side is
for
and
for
. We can solve these two scenarios as systems of equations/inequalities:
and
Solving yields three pairs
;
; and
. Checking the numbers
,
, and
; we find that all three work. Therefore there are a total of
possibilities for
.
Note: Although this solution takes a while to read (as well as to write) the actual time it takes to think through the process above is very short in comparison to the solution length.
See also
| 2007 AMC 12A (Problems • Answer Key • Resources) | |
| Preceded by Problem 21 |
Followed by Problem 23 |
| 1 • 2 • 3 • 4 • 5 • 6 • 7 • 8 • 9 • 10 • 11 • 12 • 13 • 14 • 15 • 16 • 17 • 18 • 19 • 20 • 21 • 22 • 23 • 24 • 25 | |
| All AMC 12 Problems and Solutions | |
| 2007 AMC 10A (Problems • Answer Key • Resources) | ||
| Preceded by Problem 24 |
Followed by Last question | |
| 1 • 2 • 3 • 4 • 5 • 6 • 7 • 8 • 9 • 10 • 11 • 12 • 13 • 14 • 15 • 16 • 17 • 18 • 19 • 20 • 21 • 22 • 23 • 24 • 25 | ||
| All AMC 10 Problems and Solutions | ||
These problems are copyrighted © by the Mathematical Association of America, as part of the American Mathematics Competitions.