0% found this document useful (0 votes)
346 views

The Online Math Open Spring Contest Official Solutions March 22 - April 2, 2019

The document provides the solutions to 10 problems from the Online Math Open Spring Contest held from March 22 to April 2, 2019. It lists the problem authors, tournament director, website managers, and acknowledges their contributions. It then provides the problems, proposed answers, and detailed solutions for each problem. The maximum sum achieved in one of the problems is 123. Another solution expresses a quantity as 177/1. The expected value of swapping digits in a number is expressed as a fraction m/n where m and n are relatively prime positive integers.

Uploaded by

sujalacham
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
346 views

The Online Math Open Spring Contest Official Solutions March 22 - April 2, 2019

The document provides the solutions to 10 problems from the Online Math Open Spring Contest held from March 22 to April 2, 2019. It lists the problem authors, tournament director, website managers, and acknowledges their contributions. It then provides the problems, proposed answers, and detailed solutions for each problem. The maximum sum achieved in one of the problems is 123. Another solution expresses a quantity as 177/1. The expected value of swapping digits in a number is expressed as a fraction m/n where m and n are relatively prime positive integers.

Uploaded by

sujalacham
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 18

The Online Math Open Spring Contest

Official Solutions
March 22 – April 2, 2019
Acknowledgments

Tournament Director
• Vincent Huang

Problem Authors
• Ankan Bhattacharya
• James Lin
• Michael Ren
• Luke Robitaille
• Tristan Shin
• Edward Wan
• Brandon Wang
• Yannick Yao

Website Manager
• Evan Chen
• Douglas Chen

LATEX/Python Geek
• Evan Chen
OMO Spring 2019
Official Solutions

1. Daniel chooses some distinct subsets of {1, . . . , 2019} such that any two distinct subsets chosen are
disjoint. Compute the maximum possible number of subsets he can choose.
Proposed by Ankan Bhattacharya.
Answer. 2020 .

Solution. The union of all chosen sets must have at most 2019 elements, and everything other than the
empty set contributes an element, so there are at most 2020 sets. An example is ∅, {1}, . . . , {2019}.

2. Let A = (0, 0), B = (1, 0), C = (−1, 0), and D = (−1, 1). Let C be the closed curve given by the
segment AB, the minor arc of the circle x2 + (y − 1)2 = 2 connecting B to C, the segment CD, and
the minor arc of the circle x2 + (y − 1)2 = 1 connecting D to A. Let D be a piece of paper whose
boundary is C. Compute the sum of all integers 2 ≤ n ≤ 2019 such that it is possible to cut D into n
congruent pieces of paper.
Proposed by Vincent Huang.
Answer. 2039189 .

Solution. All n work. Let P1 , P2 , . . . , Pn−1 be equally spaced points on arc AD and Q1 , Q2 , . . . , Qn−1
be equally spaced points on arc CB. Then cutting D along each line segment Pi Qi produces n congruent
pieces.

3. Compute the smallest positive integer that can be expressed as the product of four distinct integers.
Proposed by Yannick Yao.

Answer. 4 .

Solution. The answer is 4 = 1(−1)(2)(−2). These are the four nonzero integers with lowest absolute
value, so any number n that is the product of 4 distinct integers must satisfy |n| ≥ 4.


& '
X 2019! − 2018!
4. Compute . (The notation dxe denotes the least integer n such that n ≥ x.)
k!
k=2018
Proposed by Tristan Shin.
Answer. 2019 .

Solution. For k ≥ 2020, write


k k
1 1 Y 1 1 Y 1 1
= < =
k! 2018! i=2019 i 2018! i=2019 2019 2018! · 2019k−2018

so we can write the sum as


∞ ∞
X 2018 · 2018! 2018 X 2018 · 2018!
= 2018 + +
k! 2019 k!
k=2018 k=2020

2018 X 2018
< 2018 + +
2019 2019k−2018
k=2020
2018
= 1
1 − 2019
= 2019

and clearly the sum is at least 2018 so the ceiling is 2019 as desired.

1
OMO Spring 2019
Official Solutions

5. Consider the set S of lattice points (x, y) with 0 ≤ x, y ≤ 8. Call a function f : S → {1, 2, . . . , 9} a
Sudoku function if:
• {f (x, 0), f (x, 1), . . . , f (x, 8)} = {1, 2, . . . , 9} for each 0 ≤ x ≤ 8 and {f (0, y), f (1, y), . . . , f (8, y)} =
{1, 2, . . . , 9} for each 0 ≤ y ≤ 8.
• For any integers 0 ≤ m, n ≤ 2 and any 0 ≤ i1 , j1 , i2 , j2 ≤ 2, f (3m+i1 , 3n+j1 ) 6= f (3m+i2 , 3n+j2 )
unless i1 = i2 and j1 = j2 .
P P
Over all Sudoku functions f , compute the maximum possible value of 0≤i≤8 f (i, i)+ 0≤i≤7 f (i, i+1).
Proposed by Brandon Wang.
Answer. 123 .

Solution. The definition of a Sudoku function is simply that the 9 × 9 grid whose rows and columns
are zero-indexed with (0, 0) in the upper left and whose entry in the ith row and jth column is equal
to f (i, j) is a valid solution to the puzzle Sudoku. The sum, then, is the sum of the entries along the
main diagonal and the 8 squares directly above it. If we identify the grid as

ABC
DEF
GHI,

where each variable represents a 3 × 3 grid, then we see that the set of 17 entries has 5 entries in each
of A, E, I, and the lower left corners of each of B, F .
The two entries in B, F are at most 9 each. The 5 entries in A have sum at most 5 + 6 + 7 + 8 + 9 = 35
since they’re distinct; the same thing holds for the sum of the entries in E, I, so the total sum is at
most 9 + 9 + 3(35) = 123. To show that this can actually be attained, set

7 5 1
A=E=I= 2 9 6 ,
3 4 8

4 8 3
B=F =G= 5 1 7 ,
9 6 2
and
6 2 9
C=D=H= 8 3 4 ,
1 7 5
which can be verified to work.

6. Let A, B, C, ..., Z be 26 nonzero real numbers. Suppose that T = T N Y W R. Compute the smallest
possible value of  2
A + B2 + · · · + Z 2 .


(The notation dxe denotes the least integer n such that n ≥ x.)
Proposed by Luke Robitaille.
Answer. 5 .
√4
Solution. We have N Y W R = 1, so N 2 Y 2 W 2 R2 = 1 and N 2 + Y 2 + W 2 + R2 ≥ 4 N 2 Y 2 W 2 R2 = 4.
2 2
Since A , B , etc. are all positive, we must have that the sum of squares is greater than four, so its
1
ceiling is at least 5. A construction is N = Y = W = R = 1 and all other variables equal 100 .

2
OMO Spring 2019
Official Solutions

7. Let ABCD be a square with side length 4. Consider points P and Q on segments AB and BC,
respectively, with BP = 3 and BQ = 1. Let R be the intersection of AQ and DP . If BR2 can be
expressed in the form m
n for coprime positive integers m, n, compute m + n.
Proposed by Brandon Wang.
Answer. 177 .

Solution. Note that AQ, DP are 90◦ rotations of each other so ∠P RQ = 90◦ . Now we can note by the
√ 4
Extended Law of Sines that BR = P Q sin ∠BQR = 10 · √ , which gives the answer. Alternatively,
17
1 13
we can compute P R = √ , RQ = √ and use Ptolemy’s Theorem on cyclic quadrilateral P RQB
17 17
to finish.

8. In triangle ABC, side AB has length 10, and the A- and B-medians have length 9 and 12, respectively.
Compute the area of the triangle.
Proposed by Yannick Yao.
Answer. 72 .

Solution. Let G be the centroid, so AG = 32 · 12 = 8 and BG = 23 · 9 = 6. Thus the area of 4BGC


equals 21 · 6 · 8 = 24, and the area of 4ABC equals thrice this, for an answer of 72.

9. Susan is presented with six boxes B1 , . . . , B6 , each of which is initially empty, and two identical coins
of denomination 2k for each k = 0, . . . , 5. Compute the number of ways for Susan to place the coins in
the boxes such that each box Bk contains coins of total value 2k .
Proposed by Ankan Bhattacharya.

Answer. 32 .

Solution. For n boxes B1 , . . . , Bn , we claim Susan has exactly 2n−1 ways to place the coins. We
proceed by induction on n, with n = 1 clear.
Suppose the statement is proven for n, and consider n + 1. Susan has two coins of denomination 2n ,
which may only be placed in boxes Bn and Bn+1 . Thus, Susan may place one in both Bn and Bn+1 , or
both in Bn+1 . In both situations, Susan has boxes with values 21 , . . . , 2n and coins of denominations
20 , 20 , 21 , 21 , . . . , 2n−1 , 2n−1 remaining, so the total number of ways for Susan to accomplish the task
is 2 · 2n−1 = 2n , as expected.
When n = 6, the answer is 25 = 32.

10. When two distinct digits are randomly chosen in N = 123456789 and their places are swapped, one gets
a new number N 0 (for example, if 2 and 4 are swapped, then N 0 = 143256789). The expected value of
N 0 is equal to m
n , where m and n are relatively prime positive integers. Compute the remainder when
m + n is divided by 106 .
Proposed by Yannick Yao.
Answer. 962963 .

Solution. Each digit has 28 1


36 chance of not being moved and 36 chance of being swapped to a given
0
position. This means that E(N ) = 36 (111111111)(1+2+· · ·+9)+( 28−1
1 5
36 )(123456789) = 4 (111111111)+
3 925925922 462962961
4 (123456789) = 4 = 2 . Therefore m + n = 462962963 and the remainder is 962963.

3
OMO Spring 2019
Official Solutions

11. Jay is given 99 stacks of blocks, such that the ith stack has i2 blocks. Jay must choose a positive
integer N such that from each stack, he may take either 0 blocks or exactly N blocks. Compute the
value Jay should choose for N in order to maximize the number of blocks he may take from the 99
stacks.
Proposed by James Lin.
Answer. 4489 .

Solution. It’s clear that Jay must choose N = i2 , and for each stack with at least N blocks Jay will
1
choose exactly N blocks. Hence, we need to maximize f (i) = i2 (100 − i) = i2 (200 − 2i). There are
2
200
several ways to do this. One is to note that by AM-GM, f (i) is maximal at i = , and then we
3
2
finish by comparing f (66), f (67). Another is to note that f (i) ≤ f (i + 1) reduces to 3i ≤ 197i + 99,
which is true for i = 0, 1, . . . , 66, hence we choose i = 67 and N = 672 .

12. A set D of positive integers is called indifferent if there are at least two integers in the set, and for any
two distinct elements x, y ∈ D, their positive difference |x − y| is also in D. Let M (x) be the smallest
size of an indifferent set whose largest element is x. Compute the sum M (2) + M (3) + · · · + M (100).
Proposed by Yannick Yao.
Answer. 1257 .

Solution. In fact, for any two elements x, y ∈ D, by Euclidean Algorithm we can see that gcd(x, y) ∈
D. As a result, all elements in D are a multiple of the smallest element. Therefore, for all x > 1, M (x)
is equal to the smallest (prime) divisor of x that is greater than 1.
When M (x) is 2, x is an even number, so there are 50 possibilities. When M (x) is 3, x is odd and a
multiple of 3, so there are 33−12 + 1 = 17 possibilities. When M (x) is 5, x is relatively prime to 2 · 3
and divisible by 5, so the possibilities are 5 · 1, 5 · 5, 5 · 7, 5 · 11, 5 · 13, 5 · 17, 5 · 19, for 7 possibities. When
M (x) is 7, x is relatively prime to 2 · 3 · 5 and divisible by 7, so the possibilities are 7 · 1, 7 · 7, 7 · 11, 7 · 13,
for 4 possibilities. When M (x) is a prime number greater than 10, the only possibility is x itself.
Therefore, the sum is 2 · 50 + 3 · 17 + 5 · 7 + 7 · 4 + 11 + 13 + 17 + 19 + 23 + 29 + 31 + 37 + 41 + 43 +
47 + 53 + 59 + 61 + 67 + 71 + 73 + 79 + 83 + 89 + 97 = 1257.

13. Let S = {10n + 1000 : n = 0, 1, . . . }. Compute the largest positive integer not expressible as the sum
of (not necessarily distinct) elements of S.
Proposed by Ankan Bhattacharya.
Answer. 34999 .

Solution. Note that S contains the numbers 1001, 1010, 1100, 2000, 11000. The last two numbers allow
us to make any multiple of 1000 which is at least 10000. Meanwhile, the smallest number attainable
which ends in xyz is obviously x · 1100 + y · 1010 + z · 1001 = 1000(x + y + z) + (100x + 10y + z).
This implies that all numbers which are of the form 1000n + 100x + 10y + z with 0 ≤ x, y, z ≤ 9 and
n ≥ x + y + z + 10 ≥ 37 is attainable, so all numbers which are at least 37000 obviously work.
However, 36999 is not the answer, because we have 36999 = 19 · 1001 + 8 · 1010 + 9 · 1100. Also, if
xyz 6= 999, then our previous bound becomes n ≥ x + y + z + 10 ≥ 36, so these observations show that
all numbers at least 36000 are attainable.
Similar constructions show that 35999, 35998, 35989, 35899 (eg. 35999 = 9 · 1001 + 9 · 1010 + 9 · 1100 +
4 · 2000 and 35998 = 18 · 1001 + 8 · 1010 + 9 · 1100) are all attainable, and if xyz 6∈ {999, 998, 989, 899},
our bound becomes n ≥ x + y + z + 10 ≥ 35, so these observations now show that all numbers at least
35000 are attainable.
Finally, it remains to show that 34999 fails. It’s clear that if a · 1001 + b · 1010 + c · 1100 ends in 999,
then a + b + c ≥ 27 and the second-smallest value of a + b + c is 36, so we require a = b = c = 9, giving
a sum of 27999, and adding 2000s to 27999 does not produce 34999, so we’re done.

4
OMO Spring 2019
Official Solutions

14. The sum  


1000
1000
X i
 
2019
i=0
i
p
can be expressed in the form , where p and q are relatively prime positive integers. Compute p + q.
q
Proposed by James Lin.
Answer. 152 .

Solution. Consider shuffling a deck of 2019 cards, 1019 of which are golden. We will count the
expected location of the topmost golden card, where we count down from the top. Let E[X] be this
expected location, and let P [X > i] be the probability that the topmost golden card has at least i
cards above it, so it is beyond the ith position. Then,

1000
X
E[X] = P [X > i]
i=0
(1000)(999) · · · (1000 − i)
=
(2019)(2018) · · · (2019 − i)
 
1000
i
= .
2019
i

Now, consider 1020 blocks of non-golden cards, 1018 of which are between consecutive golden cards
and the other 2 which are at the ends of the stack. Each non-golden card is equally likely to be in
1000
any of the 1020 regions, so there are expected to be cards before the first golden card. Hence,
1020
1000 2020 101
E[X] = +1= = , so the answer is 101 + 51 = 152.
1020 1020 51
Alternate solutions include evaluating the sum with algebraic manipulations and the Hockey Stick
Identity. Also, on the Art of Problem Solving forums, user hukilau17 posted a solution using integration,
which can be found at this link: artofproblemsolving.com/community/c487h1814861p12103390

15. Evan has 66000 omons, particles that can cluster into groups of a perfect square number of omons. An
omon in a cluster of n2 omons has a potential energy of n1 . Evan accurately computes the sum of the
potential energies of all the omons. Compute the smallest possible value of his result.
Proposed by Michael Ren and Luke Robitaille.
Answer. 284 .

Solution. This wants us to minimize a1 + a2 + · · · + ak given a21 + a22 + · · · + a2k = 66000. Clearly
a1 = 256, a2 = 20, a3 = 8 gives a result of 284. I claim this is optimal.

Since f (x) = x is concave, by Karamata we see f (a2i ) ≤ f (b2i ) if {a2i } majorizes {b2i }. Therefore,
P P
for some sequence {b2i } to attain a smaller result than {2562 , 202 , 82 }, it must not be majorized by
{2562 , 202 , 82 }.
p b1 ≥ 100. (If p
It follows that all bi ≤ 100 obviously the
p bi will be majorized). Now note that b2 +
· · · + bk ≥ b22 + · · · + b2k = 66000 − b21 so bi ≥ 66000 − b21 + b1 . Since
P
√ b1 ≥ 100, once again
by Karamata we see that the expression is minimized when b1 approaches 66000. If b1 ≤ 255 then
p
66000 − b21 + b1 > 284, so we can assume b1 = 256.

5
OMO Spring 2019
Official Solutions

Now b22 + · · · + b2k = 464. By a similar argument we see that b2 ∈ {20, 21}. If b2 = 20 then the optimal
sequence is the one we have already considered; if b2 = 21 then b23 + b24 + · · · = 23 so the optimal
sequence of bi is 4, 2, 1, 1, 1 or 3, 3, 2, 1. Each of these produces a final result of 286 which is more than
284, so 284 is the answer.

16. In triangle ABC, BC = 3, CA = 4, and AB = 5. For any point P in the same plane as ABC, define
f (P ) as the sum of the distances from P to lines AB, BC, and CA. The area of the locus of P where
f (P ) ≤ 12 is m
n for relatively prime positive integers m and n. Compute 100m + n.
Proposed by Yannick Yao.
Answer. 92007 .

Solution. We first observe the following: If X and Y are on the same side of lines AB, BC, CA, and
we move a point P from X to Y along the segment, then f (P ) is a linear function of the distance
it moved along the segment, since the distance of P from each of the three lines varies linearly. In
particular, if f (X) = f (Y ) = 12, then f (P ) = 12 for all P along the segment. This means that we only
need to consider the points that are on one of the three lines that achieves f (P ) = 12, since connecting
these points will form a polygon that is the locus. It’s clear that f (P ) < 12 for all P inside (or on the
boundary of) the triangle. Therefore, the critical points must lie on the six rays. We consider each of
them separately:
• Ray CA: If AP = d, then f (P ) = (d + 4) + 0 + 35 d = 85 d + 4, so d = 5.
• Ray CB: If BP = d, then f (P ) = 0 + (d + 3) + 45 d = 95 d + 3, so d = 5.
• Ray AC: If CP = d, then f (P ) = d + 0 + 35 (d + 4) = 58 d + 12
5 , so d = 6.
4
• Ray AB: If BP = d, then f (P ) = 5d + 53 (d + 5) + 0 = 75 d + 3, so d = 45
7 .
• Ray BC: If CP = d, then f (P ) = 0 + d + 45 (d + 3) = 95 d + 12
5 , so d = 16
3 .
4 3 7 40
• Ray BA: If AP = d, then f (P ) = 5 (d + 5) + 5 d + 0 = 5 d + 4, so d = 7 .

Therefore, if we add up the seven components of the locus, we get the area of

3 · 4 (3 + 5) · (4 + 5) − 3 · 4 5 · 45
7 4 ( 45 + 5) · (6 + 4) − 5 · 4 3
+ + · + 7 ·
2 2 2 5 2 5
6 · 16
3 ( 16 + 3) · ( 40
7 + 5) − 3 · 5 4
40
·5 3 920
+ + 3 · + 7
· = .
2 2 5 2 5 7
So the answer is 92007.

17. Let ABCD be an isosceles trapezoid with AD k BC. The incircle of 4ABC has center I and is
tangent to BC at P . The incircle of 4ABD has center J and is tangent to AD at Q. If P I = 8,
IJ = 25, and JQ = 15, compute the greatest integer less than or equal to the area of ABCD.
Proposed by Ankan Bhattacharya.
Answer. 1728 .

Solution. The main claim is that P , I, J, Q are collinear. This can be easily proven by noting that
BP − P C = AQ − QD by incircle lengths, whence P Q is perpendicular to the bases of ABCD, but
a more “conceptual” solution is to invoke the Japanese theorem for ABCD, which gives that IJ is
perpendicular to the bases (which is also sufficient).
With this, the problem is easily solved. Let the angle bisectors AJ and BI meet at K. By angle
chasing ∠AKB = 90◦ , whence we obtain similar triangles

4AJQ ∼ 4IJK ∼ 4IBP ∼ 4BKA

6
OMO Spring 2019
Official Solutions

(the last one from equal angles formed by the bisectors).


200
Now we are in business. Write IK = x and JK = y (thus x2 + y 2 = 252 = 625). Then BI = x and
AJ = 375
y , so
x IK AK y + 375
y
= = =
y JK BK x + 200
x

and thus x2 + 200 = y 2 + 375, which forces x2 = 400 and y 2 = 225.


It follows that BK = 30 and AK = 40, so AB = 50.
Here is a nice way to complete the solution, due to Vincent Huang. Let M be the midpoint of minor
arc AB on (ABCD) so it’s well-known that M is the circumcenter of AJIB. By Ptolemy’s Formulas
AI 25 · 10 + 25 · 50 4
on cyclic quadrilateral AJIB we find AI · BJ = (25 · 10 + 25 · 50) and = = ,
√ √ BJ 25 · 25 + 10 · 50 3
hence AI = 20 5, BJ = 15 5. Now by computing the area of [AIJ] in two ways, once as 12 · 25 · 20

25 5
and once as AI·AJ·IJ
4R , we find the radius of circle (AJIB) is 2 = AM = BM .
625 AM · M B · AB
Now we can easily find that [AM B] = = , where R0 is the radius of (ABCD).
2 4R0
125
This in turn yields R0 = . Now clearly sin ∠A 3 24 0
2 = 5 =⇒ sin ∠A = 25 so BD = 2R sin A = 60, as
4
is AC. Now we know already that AD − BC = 28, and by Ptolemy we see AD · BC + AB · CD =
AC · BD =⇒ AD · BC = 1100, so AD = 50 and BC = 22. It easily follows that [ABCD] = 1728 and
we’re done.

18. Define a function f as follows. For any positive integer i, let f (i) be the smallest positive integer j such
that there exist pairwise distinct positive integers a, b, c, and d such that gcd(a, b), gcd(a, c), gcd(a, d),
gcd(b, c), gcd(b, d), and gcd(c, d) are pairwise distinct and equal to i, i + 1, i + 2, i + 3, i + 4, and j in
some order, if any such j exists; let f (i) = 0 if no such j exists. Compute f (1) + f (2) + · · · + f (2019).
Proposed by Edward Wan.
Answer. 1871 .

Solution. For a sextuple (a1 , a2 , a3 , a4 , a5 , a6 ) of distinct positive integers, we will call it vengeful if
there exists a quadruple (a, b, c, d) of integers for which gcd(a, b), gcd(a, c), gcd(a, d), gcd(b, c), gcd(b, d),
and gcd(c, d) are equal to a1 , a2 , a3 , a4 , a5 and a6 in some order. In that case, we will say that (a, b, c, d)
avenges (a1 , a2 , a3 , a4 , a5 , a6 ). We will now show a lemma which will later prove useful:
Lemma 1. A sextuple (a1 , a2 , a3 , a4 , a5 , a6 ) of distinct positive integers is vengeful only if there exists
no positive integer n for which there are exactly two multiples of n among the ai ’s.
Proof . Assume, for contradiction, that there exists a vengeful sextuple Γ = (a1 , a2 , a3 , a4 , a5 , a6 ) and a
positive integer n dividing exactly two of the ai ’s. Then, if we consider a quadruple (a, b, c, d) avenging
Γ, and let k be the number of multiples of n among a, b, c, d, then we know that k2 = 2. However, this
is absurd, contradiction. 
With Lemma 1, let’s return to the problem. When i = 1, Lemma 1 implies that if f (1) > 0, then
2|f (1), 3 - f (1), 4 - f (1), and 5 - f (1). These conditions, together with f (1) ∈
/ {1, 2, 3, 4, 5}, imply that
f (1) = 0 or f (1) ≥ 14. Since (4, 15, 42, 140) is a quadruple which avenges (1, 2, 3, 4, 5, 14), we have that
f (1) = 14. When i = 2, Lemma 1 implies that 3|f (2), which together with f (2) ∈ / {2, 3, 4, 5, 6} gives
that f (2) = 0 or f (2) ≥ 9. Therefore, since (12, 18, 20, 45) is a quadruple which avenges (2, 3, 4, 5, 6, 9),
we have that f (2) = 9. The following result characterizes the value of f (n) for all n ≥ 3:
Lemma 2. Set x0 = 0, x1 = 2, x2 = 3, x3 = 0, x4 = 0, x5 = 0, x6 = 3, x7 = 2, x8 = 0, x9 = 0, x10 = 1,
and x11 = 0. Then, if we let υ(n) denote the remainder of n upon division by 12, then we have that
f (n) = xυ(n) for n ≥ 3.
Proof . We will conduct casework on υ(n).

7
OMO Spring 2019
Official Solutions

• υ(n) = 0: Let n = 12k for k ≥ 1. Then by Lemma 1, we know that if f (n) > 0 then 2 - f (n), but
4|f (n), clearly absurd. Hence f (n) = 0 in this case.
• υ(n) = 1: Let n = 12k +1 for k ≥ 1. We know by Lemma 1 that 2|f (n), and since ((12k +1)(12k +
3)(12k + 5), (12k + 1)(12k + 2), (12k + 4)(6k + 1)(12k + 5), (12k + 4)(12k + 3)) is a quadruple that
avenges (12k + 1, 12k + 2, 12k + 3, 12k + 4, 12k + 5, 2), we have that f (n) = 2 in this case.
• υ(n) = 2: Let n = 12k + 2 for k ≥ 1. We know by Lemma 1 that 3|f (n), and since ((12k + 4)(6k +
1)(12k + 5), (12k + 6)(6k + 2), (12k + 6)(4k + 1)(6k + 1), (12k + 3)(12k + 5)) is a quadruple that
avenges (12k + 2, 12k + 3, 12k + 4, 12k + 5, 12k + 6, 3), we have f (n) = 3 in this case.
• υ(n) = 3: Let n = 12k + 3 for k ≥ 0. We know by Lemma 1 that if f (n) > 0, then 2|f (n), 3|f (n),
and 6 - f (n), which is absurd. Hence, f (n) = 0 in this case.
• υ(n) = 4: Let n = 12k + 4 for k ≥ 0. We know by Lemma 1 that if f (n) > 0 then 2 - f (n), 4|f (n),
clearly absurd. Hence, f (n) = 0 in this case.
• υ(n) = 5: Let n = 12k + 5 for k ≥ 0. We know by Lemma 1 that if f (n) > 0 then 2|f (n), 3|f (n),
and 6 - f (n), clearly absurd. Hence, f (n) = 0 in this case.
• υ(n) = 6: Let n = 12k + 6 for k ≥ 0. By Lemma 1 we know that 3|f (n), so since ((12k + 7)(12k +
8)(6k + 5), (12k + 8)(12k + 9), (12k + 10)(6k + 3), (12k + 7)(12k + 9)) avenges (12k + 6, 12k +
7, 12k + 8, 12k + 9, 12k + 10, 3), we know that f (n) = 3 in this case.
• υ(n) = 7: Let n = 12k + 7 for k ≥ 0. By Lemma 1 we know that 2|f (n), so since ((12k +
7)(12k + 9)(12k + 11), (12k + 7)(12k + 10), (12k + 8)(12k + 9), (12k + 8)(6k + 5)(12k + 11)) avenges
(12k + 7, 12k + 8, 12k + 9, 12k + 10, 12k + 11, 2), we have that f (n) = 2 in this case.
• υ(n) = 8: Let n = 12k + 8 for k ≥ 0. By Lemma 1 we know that if f (n) > 0 then 2 - f (n) and
4|f (n), clearly absurd. Hence, f (n) = 0 in this case.
• υ(n) = 9: Let n = 12k + 9 for k ≥ 0. By Lemma 1 we know that if f (n) > 0 then 2|f (n), 3|f (n),
and 6 - f (n), clearly absurd. Hence f (n) = 0 in this case.
• υ(n) = 10: Let n = 12k + 10 for k ≥ 0. Since ((12k + 11)(12k + 13), (12k + 10)(12k + 11)(6k +
7), (12k + 12)(12k + 13)(6k + 5), (12k + 12)(6k + 7)) is a quadruple that avenges (12k + 10, 12k +
11, 12k + 12, 12k + 13, 12k + 14, 1), we have that f (n) = 1 in this case.
• υ(n) = 11: Let n = 12k + 11 for k ≥ 0. By Lemma 1 we know that if f (n) > 0 then 2|f (n), 3|f (n),
and 6 - f (n), clearly absurd. Hence f (n) = 0 in this case.

In conclusion, as we’ve exhausted all 12 cases for υ(n), we know that f (n) = xυ(n) for all n ≥ 3, as
desired. 
Due to Lemma 2, we can easily compute the sum in the question as 14 + 9 + 0 + 168 ∗ 11 = 1871.

19. Arianna and Brianna play a game in which they alternate turns writing numbers on a paper. Before the
game begins, a referee randomly selects an integer N with 1 ≤ N ≤ 2019, such that i has probability
i
1+2+···+2019 of being chosen. First, Arianna writes 1 on the paper. On any move thereafter, the player
whose turn it is writes a + 1 or 2a, where a is any number on the paper, under the conditions that no
number is ever written twice and any number written does not exceed N . No number is ever erased.
The winner is the person who first writes the number N . Assuming both Arianna and Brianna play
optimally, the probability that Brianna wins can be expressed as m
n where m and n are relatively prime
positive integers. Compute m + n.
Proposed by Edward Wan.
Answer. 1274114 .

Solution. We claim that Arianna wins if and only if N is odd, expressible as 4k + 2 for k ≥ 1, or 4.
Otherwise, Brianna wins.
First of all, notice that Arianna always wins for odd numbers, since if Brianna wrote x on her previous
move, she can just write x + 1. The reason this strategy wins is because Brianna always writes only

8
OMO Spring 2019
Official Solutions

even numbers and Arianna only odds. Hence, Arianna wins because Brianna cannot possibly ever
write the odd number N , and Arianna never writes anything larger than N.
Now, we will deal with the cases where N is even. When N = 2, it’s clear that Brianna wins by simply
writing 2 on her first move. When N = 4, Arianna wins by simply writing 4 on her second move
(as Brianna must write 2 on her first move). Otherwise, we will suppose that N = 2k, where k > 2.
Firstly, we can observe that the first player to write k or 2k − 1 loses, as the next player simply writes
2k on her next move. Hence, one player winning is equivalent to ”forcing” their opponent to write one
of the ”traps” k, 2k − 1. Hence, the first player to write a number which is not a member of the set
{1, 2, · · · , k − 1, k + 1, · · · , 2k − 2} loses. Therefore, since both players play optimally, we may assume
that neither player moves outside of this set unless they are forced to.
Let’s first consider the case where k is odd, i.e., 4|N − 2. Observe then that it is always possible to
play in {1, 2, · · · , k − 1, k + 1, · · · , 2k − 2} unless all of these numbers have already been played. To see
this, simply note that we can always just play the smallest unused element e of this set, since e − 1 has
been played, except for when e = k + 1, in which case k+1 2 has been played. Therefore, since this set
has cardinality 2k − 3, an odd number, Arianna is the one who plays the last unused number in this
set, and so hence Brianna is the first one who is forced to play in {k, 2k − 1}, and hence Arianna wins.
Now, let’s consider the case when k is even, i.e. 4|N. With a similar argument as before, we know
that it is always possible to play in {1, 2, · · · , k − 1, k + 1, · · · , 2k − 2}/{k + 1} whenever there is an
unused element in this set. However, the difference when k is even is that under optimal strategy,
neither Arianna nor Brianna should ever play the number k + 1. To see this, note that since k + 1 is
odd, if it’s possible to write k + 1, then k must have been written already, and hence it’s possible to
immediately win by writing N = 2k. Therefore, since the set {1, 2, · · · , k − 1, k + 1, · · · , 2k − 2}/{k + 1}
has cardinality 2k − 4, an even number, we know that Brianna is the last person to play in this set.
Therefore, Arianna is eventually forced to play either k or 2k − 1, and so hence Brianna wins in this
case.
2+8+12+16+···+2016 509038 254519
All that remains now is to compute 1+2+···+2019 = 2039190 = 1019595 , so that m + n = 1274114.

20. Let ABC be a triangle with AB = 4, BC = 5, and CA = 6. Suppose X and Y are points such that

• BC and XY are parallel


• BX and CY intersect at a point P on the circumcircle of 4ABC
• the circumcircles of 4BCX and 4BCY are tangent to AB and AC, respectively.
p
Then AP 2 can be written in the form q for relatively prime positive integers p and q. Compute 100p+q.
Proposed by Tristan Shin.
Answer. 230479 .

Solution. First note that ∠CBY = 180◦ − ∠ACY = 180◦ − ∠ACP . Similarly we have ∠BCX =
180◦ − ∠ABP . It follows that ∠CBY + ∠BCX = 180◦ , so BY ||CX and BCXY is a parallelogram.
RABC AB BP
Now, by the Extended Law of Sines applied to (ABC), (BCY ) we have that = = .
RBCY BC BY
AC CP
Similarly we have that = , hence combining these equations and using BY = CX yields that
BC CX
BP AB
= , so AP is the A-symmedian of 4ABC.
CP AC
√ √
2 · 42 + 2 · 62 − 52 79
Now let M be the midpoint of BC. Then AM = = . Since P, M are inverses
2 2
√ 24 48 2304
in bc−inversion, we see AP = = √ , so AP 2 = , yielding an answer of 230479.
AM 79 79

9
OMO Spring 2019
Official Solutions

21. Define a sequence by a0 = 2019 and an = a2019


n−1 for all positive integers n. Compute the remainder
when
a0 + a1 + a2 + · · · + a51
is divided by 856.
Proposed by Tristan Shin.
Answer. 108 .

Solution. Let p = 107, q = 53 so that p − 1 = 2q. Also set n = 2019. Observe that n is a primitive
root mod both p and q since n2 and n53 are not 1 (mod 107) and n4 and n26 are not 1 (mod 53). Then
n is also a primitive root mod 2q since powers of n range all residues mod q and are all 1 (mod 2).
i
Observe that ai = n(n ) , so we can reduce ni (mod 2q) and the sum remains the same mod p. But
the ni range all odd integers from 1 to 2q − 1 = p − 2 inclusive except for q because n is a primitive
root mod 2q, so the sum is
p−1
n1 + n3 + n5 + . . . + np−2 − n 2 (mod p).

But observe that


np − n
n1 + n3 + n5 + . . . + np−2 = ≡0 (mod p),
n2 − 1
p−1
so we just need to compute −n 2 (mod p). But since n is a primitive root mod p, this is just 1
(mod p). Then clearly the sum is 52 · 3 ≡ 4 (mod 8), so we deduce that it is 108 (mod 856).

22. For any set S of integers, let f (S) denote the number of integers k with 0 ≤ k < 2019 such that there
exist s1 , s2 ∈ S satisfying s1 − s2 = k. For any positive integer m, let xm be the minimum possible
value of f (S1 ) + · · · + f (Sm ) where S1 , . . . , Sm are nonempty sets partitioning the positive integers. Let
M be the minimum of x1 , x2 , . . . , and let N be the number of positive integers m such that xm = M .
Compute 100M + N .
Proposed by Ankan Bhattacharya.
Answer. 202576 .

Solution. The main claims are that M = 2019 and N = 676.


First we prove M ≥ 2019. Let a be any positive integer, and consider the segment [a, a + 2018] of 2019
integers. Consider any subset S ⊆ [a, a + 2018]; it is clear that f (S) ≥ |S| with equality iff S is an
arithmetic progression. Summing this inequality over all S1 , . . . , Sm , it follows that
m
X
f (S1 ) + · · · + f (Sm ) ≥ f (S1 ∩ [a, a + 2018]) + · · · + f (Sm ∩ [a, a + 2018]) ≥ |Sk ∩ [a, a + 2018]| = 2019.
k=1

This is clearly possible (e.g. when m = 1).


Now we analyze the equality cases; suppose that S1 t · · · t Sm = N gives equality. The first claim is
that if a ∈ Si then a + 2019 ∈ Si . Indeed, as above
X
f (S1 ) + · · · + f (Sm ) = f (Sk ∩ [a + 1, a + 2019]) + f (Sm ∩ [a + 1, a + 2019])
k6=i
X
= f (Sk ∩ [a, a + 2018]) + f (Sm ∩ [a + 1, a + 2019]) = 2019
k6=i
X
= f (Sk ∩ [a, a + 2018]) + f (Sm ∩ [a, a + 2018])
k6=i

and the result follows. Now we may interpret each Sk as an arithmetic progression in Z/2019Z;
conversely any such arithmetic partition works.

10
OMO Spring 2019
Official Solutions

Thus, we only need to enumerate the number of possible m for which Z/2019Z can be split into m
cyclic arithmetic progressions. Since 2019 = 3 · 673, each set must have size 1, 3, 673, or 2019, and
both 3 and 673 cannot occur (else they will share an element).
Now it is easy to see that the possible values of m are 1, 3, 673, 675, . . . , 2019, for a total of 676 possible
values. Thus N = 676 and 100M + N = 202576.

23. Let a1 , a2 , a3 , a4 , and a5 be real numbers satisfying

a1 a2 + a2 a3 + a3 a4 + a4 a5 + a5 a1 = 20,
a1 a3 + a2 a4 + a3 a5 + a4 a1 + a5 a2 = 22.

Then the smallest possible value of a21 + a22 + a23 + a24 + a25 can be expressed as m + n, where m and
n are positive integers. Compute 100m + n.
Proposed by Ankan Bhattacharya.
Answer. 2105 .

Solution. Here is a solution by Vincent Huang. The minimum possible value is 21+ 5, for an answer
of 2105. To prove that this is a lower bound, set ω = e2πi/5 , and note that

0 ≤ |a0 + a1 ω + a2 ω 2 + a3 ω 3 + a4 ω 4 |2
= (a0 + a1 ω + a2 ω 2 + a3 ω 3 + a4 ω 4 )(a0 + a1 ω −1 + a2 ω −2 + a3 ω −3 + a4 ω −4 )
4
X
= a2k + 2ak ak+1 Re(ω) + 2ak ak+2 Re(ω 2 )
k=0
√ √
= a20 + a21 + a22 + a23 + a24 + 2 · 20 · −1+4 5 + 2 · 22 · −1−4 5



which gives a20 + · · · + a24 ≥ 21 + 5, as desired. (Here indices are taken modulo 5.)

Equality is possible if and only if a0 + a1 ω + a2 ω 2 + a3 ω 3 + a4 ω 4 = 0. Note that ω 2 + 1−2 5 ω + 1 = 0,

so (a0 , a1 , a2 , a3 , a4 ) = (s + t, s · 1−2 5 + t, s + t, t, t) gives equality for any real s and t.
We claim that we may choose s and t in such a way so that both conditions are satisfied. Indeed, by
computing, note that
√ √
a1 a2 + a2 a3 + a3 a4 + a4 a5 + a5 a1 = (1 − 5)s2 + (5 − 5)st + 5t2 ,

a1 a3 + a2 a4 + a3 a5 + a4 a1 + a5 a2 = s2 + (5 − 5)st + 5t2 .
√ √
Thus, we need 5 · s2 = 2. The other necessary condition is 5t2 + (5 − 5)st + (s2 − 22) = 0, so as a
quadratic in t, its discriminant is
√ √
(5 − 5)2 s2 − 20(s2 − 22) = 440 − 10 5 · s2 = 420 > 0,

and thus there exists a real solution for t, as desired.

24. We define the binary operation × on elements of Z2 as

(a, b) × (c, d) = (ac + bd, ad + bc)

for all integers a, b, c, and d. Compute the number of ordered six-tuples (a1 , a2 , a3 , a4 , a5 , a6 ) of integers
such that
[[[[(1, a1 ) × (2, a2 )] × (3, a3 )] × (4, a4 )] × (5, a5 )] × (6, a6 ) = (350, 280).

Proposed by Michael Ren and James Lin.


Answer. 8 .

11
OMO Spring 2019
Official Solutions

Solution. (Solution by Vincent Huang.) The below solution is casework-intensive, but it’s really not
that bad with the right organization and optimizations and definitely doable in 90 minutes.
Notice that (a + bt) × (c + dt) ≡ (ac + bd) + (ad + bc)t (mod t2 − 1). This motivates a natural algebraic
interpretation of the conditions:
Let P (t) = (1 + a1 t)(2 + a2 t)(3 + a3 t)(4 + a4 t)(5 + a5 t)(6 + a6 t) ≡ 350 + 280t (mod t2 − 1), so we wish
to find the number of solutions to P (1) = (1 + a1 )(2 + a2 )(3 + a3 )(4 + a4 )(5 + a5 )(6 + a6 ) = 630 and
P (−1) = (1 − a1 )(2 − a2 )(3 − a3 )(4 − a4 )(5 − a5 )(6 − a6 ) = 70.
Note that if 3 | 3 + a3 then 3 | 3 − a3 | 70, contradiction, so 3 + a3 , 3 − a3 | 70. Similarly we
have 6 + a6 , 6 − a6 | 70. By examining all the divisors of 70, it follows that (3 + a3 , 3 − a3 ) =
(7, −1), (5, 1), (1, 5), (−1, 7). Call these options A, B, C, D. Similarly we find that (6 + a6 , 6 − a6 ) =
(14, −2), (10, 2), (7, 5), (5, 7), (2, 10), (−2, 14). Call these options A, B, C, D, E, F . For the rest of this
solution, we’ll use eg. case AE to refer to the case where (3 + a3 , 3 − a3 ) = (7, −1) and (6 + a6 , 6 − a6 ) =
(2, 10). In addition, we’ll use the notation (1245)+ to refer to the product (1+a1 )(2+a2 )(4+a4 )(5+a5 )
and define (1245)− similarly; other notation like (124)+ , (12)+ will mean the same thing.
Cases AA, AC, BB, BD, CC, CE, DD, DF: In each of these cases we either get that (3 + a3 )(6 + a6 ) - 70
or that (3 − a3 )(6 − a6 ) - 70, contradiction.
Case AB: We have (1245)+ = 9, (1245)− = −35. If 5 | 5 − a5 then 5 | 5 + a5 | 9, contradiction, hence
5 − a5 = ±1, ±7. Then for 5 + a5 | 9, we require (5 + a5 , 5 − a5 ) = (9, 1), (3, 7). In the first case we get
(124)+ = 1, (124)− = −35, which has no solutions. In the second case we get (124)+ = 3, (124)− = −5.
Since one of 4 + a4 , 4 − a4 is ≥ 4, we see 4 − a4 = 5, so (12)+ = 1, (12)− = −1, which has no solutions.
Case AD: We have (1245)+ = 18, (1245)− = −10. By reasoning similar to case AB, we see (5 +
a5 , 5 − a5 ) = (9, 1). Thus (124)+ = 2, (124)− = −10 and we see (4 + a4 , 4 − a4 ) = (−2, 10), so
(12)+ = −1, (12)− = −1, contradiction.
Case AE: We have (1245)+ = 45, (1245)− = −7. Then by similar reasoning, we see (5 + a5 , 5 −
a5 ) = (9, 1), (3, 7). The first case yields (124)+ = 5, (124)− = −7, from which we obtain the solution
(0, 3, 4, −3, 4, −4). In the second case, (124)+ = 15, (124)= − 1, and there are no possible values for a4 ,
contradiction.
Case AF: We have (1245)+ = −45, (1245)− = −5, from which we deduce (5+a5 , 5−a4 ) = (5, 5), (9, 1), (15, −5).
Thus ((124)+ , (124)− ) = (−9, −1), (−5, −5), (−3, 1), and in each case we find no solutions.
Case BA: We have (1245)+ = 9, (1245)− = −35. These equations are identical to case AB, so there
are no solutions.
Case BC: We have (1245)+ = 18, (1245)− = 14. Then casework yields that (5+a5 , 5−a5 ) = (3, 7), (9, 1).
In the first case we get (124)+ = 6, (124)− = 2, from which there are no solutions. In the second case
we get (124)+ = 2, (124)− = 14, from which we obtain the solution (0, 0, 2, −3, 4, 1).
Case BE: We have (1245)+ = 63, (1245)− = 7. Then casework shows (5 + a5 , 5 − a5 ) = (3, 7), (9, 1). In
the first case we get (124)+ = 21, (124)− = 1, from which we obtain the solution (0, 1, 2, 3−, 2 − 4). In
the second case we get (124)+ = (124)− = 7, and there are no solutions.
Case BF: We have (1245)+ = −63, (1245)− = 5. Casework shows (5 + a5 , 5 − a5 ) = (9, 1), from which
we get (124)+ = −7, (124)− = 5, and we get the solution (0, −3, 2, 3, 4, −8).
Case CA: We have (1245)+ = 45, (1245)− = −7. These equations are identical to case AE, so we get
the solution (0, 3, −2, −3, 4, 8).
Case CB: We have (1245)+ = 63, (1245)− = 7. These equations are identical to case BE, from which
we get the solution (0, 1, −2, 3, −2, 4).
Case CD: We have (1245)+ = 126, (1245)− = 2. Casework show (5 + a5 , 5 − a5 ) = (9, 1), from which
we get (124)+ = 14, (124)− = 2, and we get the solution (0, 0, −2, 3, 4, −1).
Case CF: We have (1245)+ = −315, (1245)− = 1. Casework shows (5 + a5 , 5 − a5 ) = (9, 1), from which
we get (124)+ = −35, (124)− = 1, and we find there are no solutions.
Case DA: We have (1245)+ = −45, (1245)− = −5. These equations are identical to case AF, so there
are no solutions.

12
OMO Spring 2019
Official Solutions

Case DB: We have (1245)+ = −63, (1245)− = 5. These equations are identical to case BF, so we get
the solution (0, −3, −4, 3, 4, 4).
Case DC: We have (1245)+ = −90, (1245)− = 2. Casework shows that (5 + a5 , 5 − a5 ) = (9, 1), so
(124)+ = −10, (124)− = 2, and we find there are no solutions.
Case DE: We have (1245)+ = −315, (1245)− = 1. Casework shows that (5 + a5 , 5 − a5 ) = (9, 1), from
which we get (124)+ = −35, (124)− = 1, and there are no solutions.
Thus we have exhausted all cases, and there are 8 total solutions.

25. Let S be the set of positive integers not divisible by p4 for all primes p. Anastasia and Bananastasia
play a game.
At the beginning, Anastasia writes down the positive integer N on the board. Then the players take
moves in turn; Bananastasia moves first. On any move of his, Bananastasia replaces the number n on
the blackboard with a number of the form n − a, where a ∈ S is a positive integer. On any move of
hers, Anastasia replaces the number n on the blackboard with a number of the form nk , where k is a
positive integer. Bananastasia wins if the number on the board becomes zero.
Compute the second-smallest possible value of N for which Anastasia can prevent Bananastasia from
winning.
Proposed by Brandon Wang and Vincent Huang.
Answer. 625 .

Solution. The main claim is that if, at the end of Bananastasia’s turn, the number on the board isn’t
0 or 1, then Anastasia can always prevent Banastasia from writing a 0 or 1 on the following turn. By
continuing this process indefinitely, Anastasia never loses.
Indeed, let n > 1 be the number on the board. Then we may as well assume n > 9, because if n ≤ 9
Anastasia can just pretend n is n4 and make the same moves. Now, if n − 1 is a power of two then
16 | n4 − 1, so clearly n4 − 1, n4 are not in S, hence if Anastasia chooses k = 4 and replaces n with n4 ,
Banastasia cannot make a 0 or 1 on his next turn. If n − 1 isn’t a power of two then we can find an
3 3 3
odd prime p | n − 1 so that vp (np − 1) = vp (n − 1) + vp (p3 ) ≥ 4, hence once again np − 1, np are not
in S, so Anastasia can choose k = p3 this time and achieve the same result.
Therefore, if Anastasia writes N such that N, N − 1 are both divisible by fourth powers of primes, she
cannot lose. Thus the second-smallest value of N is 625.

26. There exists a unique prime p > 5 for which the decimal expansion of p1 repeats with a period of exactly
294. Given that p > 1050 , compute the remainder when p is divided by 109 .
Proposed by Ankan Bhattacharya.
Answer. 572857143 .

Solution. The conditions on p are equivalent to p | 10294 − 1 but p - 10k − 1 for k < 294. It follows
that p | Φ294 (10).
We claim that the only prime dividing both Φ294 (10) and one of 101 −1, . . . , 10293 −1 is 7. Let q be such
a prime, and let d be the order of 10 modulo q, so d | 294. Then we require νq (10294 − 1) > νq (10d − 1).
However by exponent lifting this forces q | 294
d , so q equals 2, 3, or 7. Clearly q 6= 2 since Φ294 (10) is
odd. To see q 6= 3, note that Φ294 (10) ≡ Φ294 (1) = 1 (mod 3), as 294 is not a prime power.

Thus it follows that Φ294 (10) is a power of 7 times a power of p. We claim that ν7 Φ294 (10) = 1.
Indeed, note that by exponent lifting,
(
X 1 + ν7 (n) 6 | n
ν7 Φd (10) = ν7 (10n − 1) =


d|n
0 otherwise,

13
OMO Spring 2019
Official Solutions

from which ν7 Φ294 (10) = 1 quickly follows.
2
Thus 71 Φ294 (10) is a power of p. However, it is easy to see that Φ294 (10) < 2·10ϕ(294) = 2·1084 < 1050 ,
so in fact p = 71 Φ294 (10).
Now to compute p modulo 109 , note that Φ294 (10) = Φ42 (107 ) by well-known cyclotomic polynomial
properties. Thus it follows that
7p ≡ a1 107 + a0 (mod 109 ),
where we write Φ42 (x) = a12 x12 + · · · + a0 . Recall that the coefficients of cyclotomic polynomials are
symmetric, so a0 = a12 = 1 and a1 = a11 is the negative of the sum of the roots of Φ42 (x). This is
known to equal µ(42) = −1, so a1 = 1.
Finally, p ≡ 17 · 107 + 1 ≡ 572857143 modulo 109 .


27. Let G be a graph on n vertices V1 , V2 , . . . , Vn and let P1 , P2 , . . . , Pn be points in the plane. Suppose
that, whenever Vi and Vj are connected by an edge, Pi Pj has length 1; in this situation, we say that
the Pi form an embedding of G in the plane. Consider a set S ⊆ {1, 2, . . . , n} and a configuration
of points Qi for each i ∈ S. If the number of embeddings of G such that Pi = Qi for each i ∈ S is
finite and nonzero, we say that S is a tasty set. Out of all tasty sets S, we define a function f (G) to
be the smallest size of a tasty set. Let T be the set of all connected graphs on n vertices with n − 1
f (G)2
edges. Choosing
j k G uniformly and at random from T , let an be the expected value of n2 . Compute
2019 lim an .
n→∞
Proposed by Vincent Huang.

Answer. 273 .

Solution. For a fixed G and tasty set S, clearly S must contain all the leaves of G, as otherwise the
points corresponding to the leaves can vary freely along some unit circle centered at a neighbor. Now
consider two leaves vi , vj such that the path from vi → vj contains k edges. If we set Qi Qj = k in our
embedding, every intermediate vertex in the path has a fixed position, so all their positions are forced.
In this manner we can choose the positions of the leaves such that the position of every other vertex
in the embedding is forced, so f (G) is just the total number of leaves.
Now let x1 , x2 , . . . , xn be the indicator variables where xi is 1 iff Vi is a leaf. Then f (G)2 =
P 2
xi +
xi xj . Note that Vi is a leaf if removing it yields a tree, and there are (n − 1)n−3 possible trees on
P
the other n − 1 vertices as well as n − 1 options for the parent of Vi , so the expected value of x2i = xi
(n − 1)n−2 1
is n−2
by Cayley’s Formula. This tends to as n → ∞. Similarly xi , xj are both leaves if
n e
n−4
removing them yields one of (n − 2) possible trees, and we can attach them in (n − 2)2 ways, so
n−2
(n − 2) 1 2
the expected value of xi xj is n−2
, which tends to 2 . So the expected value of f (G)
n 2 tends to
n e
1
, and the answer is 273.
e2

28. Let ABC be a triangle. There exists a positive real number x such that AB = 6x2 + 1 and AC =
2x2 + 2x, and there exist points W and X on segment AB along with points Y and Z on segment AC
such that AW = x, W X = x + 4, AY = x + 1, and Y Z = x. For any line ` not intersecting segment
BC, let f (`) be the unique point P on line ` and on the same side of BC as A such that ` is tangent
to the circumcircle of triangle P BC. Suppose lines f (W Y )f (XY ) and f (W Z)f (XZ) meet at B, and
that lines f (W Z)f (W Y ) and f (XY )f (XZ) meet
√at C. Then the product of all possible values for the
b c
length of BC can be expressed in the form a + for positive integers a, b, c, d with c squarefree and
d
gcd(b, d) = 1. Compute 100a + b + c + d.
Proposed by Vincent Huang.
Answer. 413 .

14
OMO Spring 2019
Official Solutions

Solution. Let E = f (W Y ), F = f (XY ), G = f (XZ), H = f (W Z). Let T be the Miquel point of


quadrilateral EHGF . Note that T BCF is cyclic, but due to tangency we have ∠XF B = ∠F CB =
∠GCB = ∠XGB, hence X ∈ (T BCF ). Similarly we get that (T GHZC), (T BW EH), (T CY EF ) are
cyclic.
Next note ∠W XY = ∠BT F = ∠BGF = ∠CGH = ∠W ZY , so W XY Z is cyclic. Now note ∠XW Z =
180◦ − ∠BT H = 180◦ − ∠XT H − ∠XGB = 180◦ − ∠XT H − ∠HT Z = 180◦ − ∠XT Z, so T also lies
on this circle. By Miquel’s Theorem applied to triangle AXZ with points B, G, C, we get T ∈ (ABC).
Finally, let BG, CG meet (ABC) at B1 , C1 . By Reim’s Theorem we have B1 C1 ||XZ. However,
∠B1 BC = ∠GBC = ∠ZGC = ∠ZT C, so T, Z, B1 are collinear, and similarly T, X, C1 are as well.
Therefore a homothety centered at T sends (T XZ) to (T B1 C1 ), so the circles are tangent.
Now from AW · AX = AY · AZ we get x(2x + 4) = (x + 1)(2x + 1) =⇒ √ x = p 1. By Casey’s
Theorem applied to (ABC) and four circles A, B, C, (W XY√ZT ), we see that a 6 = b (c − 6)(c − 1)+
p 7 3
c (b − 3)(b − 2). Plugging in b = 4, c = 7 gives a = 4 + , so the answer is 413 and we’re done.
3

29. Let n be a positive integer and let P (x) be a monic polynomial of degree n with real coefficients. Also
n+1
X i2 P (i2 )2
let Q(x) = (x + 1)2 (x + 2)2 . . . (x + n + 1)2 . Consider the minimum possible value mn of .
i=1
Q(i)
Then there exist positive constants a, b, c such that, as n approaches infinity, the ratio between mn and
a2n n2n+b c approaches 1. Compute b2019abc2 c.
Proposed by Vincent Huang.
Answer. 4318 .

Solution. Apply Lagrange Interpolation to P at the points 12 , 22 , . . . , (n + 1)2 to deduce that


n+1
P (i2 ) 2
Q
j6=i (x − j )
X
Q = P (x).
i=1 j6=i (i2 − j 2 )

Comparing xn coefficients on both sides therefore yields


n+1 n+1
P (i2 ) P (i2 )
 
X 1 X n
1= Q Q = Q (−1)n+1−i .
i=1 j6=i (i + j) j6=i (i − j) n! i=1 j6=i (i + j) i − 1

Therefore, by Cauchy-Schwarz, we have


n+1
!2 n+1 2 ! n+1 !
P (i2 ) P (i2 )2
  X
2
X n n+1−i n X
n! = Q (−1) ≤ Q 2
.
i=1 j6=i (i + j) i − 1 i=1
i−1 i=1 j6=i (i + j)

2n
 n+1
X 4i2 P (i2 )2
This last expression simplifies as n , hence we have that the desired expression is at least
i=1
Q(i)
n!4
. Equality can easily be achieved by examining the Cauchy-Schwarz equality case and selecting
4(2n)!
an appropriate P such that the P (i2 ) terms are in the proper ratio. By Stirling’s Approximation we

π 3/2 1 1 3 π π
find the expression tends towards n2n+3/2 , so a = , b = , c = , and we can compute
2 (2e)2n 2e 2 2
3
the answer is b2019 · 16e π 3 c = 4318.

30. Let ABC be a triangle with symmedian point K, and let θ = ∠AKB − 90◦ . Suppose that θ is both
positive and less than ∠C. Consider a point K 0 inside 4ABC such that A, K 0 , K, and B are concyclic
and ∠K 0 CB = θ. Consider another point P inside 4ABC such that K 0 P ⊥ BC and ∠P CA = θ.

15
OMO Spring 2019
Official Solutions

If sin ∠AP B = sin2 (C − θ) and the product of the lengths of the A- and B-medians of 4ABC is
p √ √
5 + 1, then the maximum possible value of 5AB 2 − CA2 − CB 2 can be expressed in the form m n
for positive integers m, n with n squarefree. Compute 100m + n.
Proposed by Vincent Huang.
Answer. 802 .

Solution. Let the projections of K 0 onto BC, CA, AB be PA , PB , PC . Then the angle condition
rewrites as ∠K 0 AB + ∠K 0 BA + ∠K 0 CB = 90◦ , or equivalently that ∠PC PA B = ∠PC PB PA , so
(PA PB PC ) is tangent to BC. It follows that if P 0 is the isogonal conjugate of K 0 , then the six-point
circle of K 0 , P 0 is tangent to BC, so K 0 P 0 ⊥ BC and CK 0 , CP 0 are isogonal, hence P = P 0 .
Now ∠AP B = 180◦ + ∠C − ∠AK 0 B = 90◦ + ∠C − θ. Then letting √ φ = ∠C − θ, it follows from the
2 −1 + 5
condition that cos φ = sin φ, from which we easily get cos φ = .
2
Finally, since P, Q are isogonal conjugates and P ∈ (AKB), we have Q ∈ (AGB) where G is the
centroid, so applying Law of Cosines yields AB 2 = AG2 + BG2 − 2AG · BG cos ∠AGB = AG2 + BG2 +
2AG · BG sin φ. Letting ma , mb be the lengths ofq
medians from A and B and using the median formula
p√ √ √
2 2 2 5−1
yields 5c − a − b = 8ma mb sin φ = 8 5+1 2 = 8 2, so the answer is 802.

16

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy