Skip to main content

2015 AIME I Problem 14

Problem 14 of 15HarderAlgebraGeometryProblem-Solving Techniques

For each integer n≥2,n \ge 2, let A(n)A(n) be the area of the region in the coordinate plane defined by the inequalities 1≤x<n1 \le x \lt n and 0≤y≤x⌊x⌋,0 \le y \le x\lfloor\sqrt{x}\rfloor, where ⌊x⌋\lfloor\sqrt{x}\rfloor is the greatest integer not exceeding x.\sqrt{x}. Find the number of values of nn with 2≤n≤10002 \le n \le 1000 for which A(n)A(n) is an integer.

Your answer

Integer from 0 to 999
Show solution

Solution

On the strip m≤x<m+1m \le x \lt m + 1 we have ⌊x⌋=k=⌊m⌋,\lfloor\sqrt{x}\rfloor = k = \lfloor\sqrt{m}\rfloor, so the region above it is a trapezoid under y=kxy = kx with area A(m+1)−A(m)=(2m+1)k2:A(m+1) - A(m) = \frac{(2m+1)k}{2}: an integer when kk is even, a half-integer when kk is odd. Hence as nn grows by 1,1, the integrality of A(n)A(n) is unchanged while kk is even and flips at every step while kk is odd. Consider the block of 2k+12k + 1 values k2<n≤(k+1)2.k^2 \lt n \le (k+1)^2. Starting from A(1)=0,A(1) = 0, the statuses of A(k2)A(k^2) cycle with period 4:4: integer for k≡0,1k \equiv 0, 1 and non-integer for k≡2,3(mod4)k \equiv 2, 3 \pmod 4 (an odd block flips the status an odd number of times, an even block preserves it). Counting integer values of A(n)A(n) inside each block: for k=4j−3k = 4j - 3 the block alternates, beginning and ending with non-integers, giving 4j−3;4j - 3; for k=4j−2k = 4j - 2 every value is a non-integer, giving 0;0; for k=4j−1k = 4j - 1 it alternates, beginning and ending with integers, giving 4j;4j; for k=4jk = 4j all 8j+18j + 1 values are integers. For j=1,…,7,j = 1, \ldots, 7, covering 2≤n≤292,2 \le n \le 29^2, the four blocks contribute (4j−3)+0+4j(4j - 3) + 0 + 4j +(8j+1)=16j−2+ (8j + 1) = 16j - 2 integers, totaling ∑j=17(16j−2)=434.\sum_{j=1}^{7}(16j - 2) = 434. Then the block k=29k = 29 contributes 2929 integers for 841<n≤900,841 \lt n \le 900, the block k=30k = 30 contributes none, and for k=31k = 31 the alternation over 961<n≤1000961 \lt n \le 1000 begins with an integer at n=962n = 962 and gives 2020 more. The total is 434+29+20=483.434 + 29 + 20 = 483.
AoPS wiki

Tagged: floor and ceiling functions · trapezoid · casework · pattern recognition

More practice