Olympiad Maths Prep

Track / Stage 7 / 164 of 300 #1564 of 2000

Problem 1564

National olympiad second round; IMO P1/P4
Algebra Difficulty 7.4 Prove it Canadian Mathematical Olympiad · Canada

Problem:

Let nn be a positive integer. For any positive integer jj and positive real number rr, define
fj(r)=min(jr,n)+min(jr,n),andgj(r)=min(jr,n)+min(jr,n), f_{j}(r)=\min (j r, n)+\min \left(\frac{j}{r}, n\right), \quad \text{and} \quad g_{j}(r)=\min (\lceil j r\rceil, n)+\min \left(\left\lceil\frac{j}{r}\right\rceil, n\right),
where x\lceil x\rceil denotes the smallest integer greater than or equal to xx. Prove that
j=1nfj(r)n2+nj=1ngj(r) \sum_{j=1}^{n} f_{j}(r) \leq n^{2}+n \leq \sum_{j=1}^{n} g_{j}(r)

This one wants a proof. Work it on paper, read the official solution, then mark yourself honestly — the ladder only means something if the record is true.

Official solutions — 2

Solution 1

Solution:

We first prove the left hand side inequality. We begin by drawing an n×nn \times n board, with corners at (0,0),(n,0),(0,n)(0,0),(n, 0),(0, n) and (n,n)(n, n) on the Cartesian plane.
Consider the line \ell with slope rr passing through (0,0)(0,0). For each j{1,,n}j \in\{1, \ldots, n\}, consider the point (j,min(jr,n))(j, \min (j r, n)). Note that each such point either lies on \ell or the top edge of the board. In the jthj^{\text{th}} column from the left, draw the rectangle of height min(jr,n)\min (j r, n). Note that the sum of the nn rectangles is equal to the area of the board under the line \ell plus nn triangles (possibly with area 0) each with width at most 1 and whose sum of the heights is at most nn. Therefore, the sum of the areas of these nn triangles is at most n/2n / 2. Therefore, j=1nmin(jr,n)\sum_{j=1}^{n} \min (j r, n) is at most the area of the square under \ell plus n/2n / 2.

Consider the line with slope 1/r1 / r. By symmetry about the line y=xy=x, the area of the square under the line with slope 1/r1 / r is equal to the area of the square above the line \ell. Therefore, using the same reasoning as before, j=1nmin(j/r,n)\sum_{j=1}^{n} \min (j / r, n) is at most the area of the square above \ell plus n/2n / 2.

Therefore, j=1nfj(r)=j=1n(min(jr,n)+min(jr,n))\sum_{j=1}^{n} f_{j}(r)=\sum_{j=1}^{n}\left(\min (j r, n)+\min \left(\frac{j}{r}, n\right)\right) is at most the area of the board plus nn, which is n2+nn^{2}+n. This proves the left hand side inequality.

To prove the right hand side inequality, we will use the following lemma:

Lemma: Consider the line \ell with slope ss passing through (0,0)(0,0). Then the number of squares on the board that contain an interior point below \ell is j=1nmin(js,n)\sum_{j=1}^{n} \min (\lceil j s\rceil, n).

Proof of Lemma: For each j{1,,n}j \in\{1, \ldots, n\}, we count the number of squares in the jthj^{\text{th}} column (from the left) that contain an interior point lying below the line \ell. The line x=jx=j intersects the line \ell at (j,js)(j, j s). Hence, since each column contains nn squares total, the number of such squares is min(js,n)\min (\lceil j s\rceil, n). Summing over all j{1,2,,n}j \in\{1,2, \ldots, n\} proves the lemma. End Proof of Lemma

By the lemma, the rightmost expression of the inequality is equal to the number of squares containing an interior point below the line with slope rr plus the number of squares containing an interior point below the line with slope 1/r1 / r. By symmetry about the line y=xy=x, the latter number is equal to the number of squares containing an interior point above the line with slope rr. Therefore, the rightmost expression of the inequality is equal to the number of squares of the board plus the number of squares of which \ell passes through the interior. The former is equal to n2n^{2}. Hence, to prove the inequality, it suffices to show that every line passes through the interior of at least nn squares. Since \ell has positive slope, each \ell passes through either nn rows and/or nn columns. In either case, \ell passes through the interior of at least nn squares. Hence, the right inequality holds.

Solution 2

Solution:

We first prove the left inequality. Define the function f(r)=j=1nfj(r)f(r)=\sum_{j=1}^{n} f_{j}(r). Note that f(r)=f(1/r)f(r)=f(1 / r) for all r>0r>0. Therefore, we may assume that r1r \geq 1.

Let m=n/rm=\lfloor n / r\rfloor, where x\lfloor x\rfloor denotes the largest integer less than or equal to xx. Then min(jr,n)=jr\min (j r, n)=j r for all j{1,,m}j \in\{1, \ldots, m\} and min(jr,n)=n\min (j r, n)=n for all j{m+1,,n}j \in\{m+1, \ldots, n\}. Note that since r1,min(j/r,n)nr \geq 1, \min (j / r, n) \leq n for all j{1,,n}j \in\{1, \ldots, n\}. Therefore,
f(r)=j=1nfj(r)=(1+2+m)r+(nm)n+(1+2++n)1r=m(m+1)2r+n(n+1)21r+n(nm) \begin{gathered} f(r)=\sum_{j=1}^{n} f_{j}(r)=(1+2+\ldots m) r+(n-m) n+(1+2+\ldots+n) \cdot \frac{1}{r} \\ =\frac{m(m+1)}{2} \cdot r+\frac{n(n+1)}{2} \cdot \frac{1}{r}+n(n-m) \end{gathered}
Then f(r)n2+nf(r) \leq n^{2}+n if and only if
m(m+1)r2+n(n+1)2rn(m+1) \frac{m(m+1) r}{2}+\frac{n(n+1)}{2 r} \leq n(m+1)
if and only if
m(m+1)r2+n(n+1)2rn(m+1) m(m+1) r^{2}+n(n+1) \leq 2 r n(m+1)
Since m=n/rm=\lfloor n / r\rfloor, there exists a real number bb satisfying 0b<r0 \leq b<r such that n=mr+bn=m r+b. Substituting this into the previous equation yields
m(m+1)r2+(mr+b)(mr+b+1)2r(mr+b)(m+1), m(m+1) r^{2}+(m r+b)(m r+b+1) \leq 2 r(m r+b)(m+1),
if and only if
2m2r2+mr2+(2mb+m)r+b2+b2m2r2+2mr2+2mbr+2br, 2 m^{2} r^{2}+m r^{2}+(2 m b+m) r+b^{2}+b \leq 2 m^{2} r^{2}+2 m r^{2}+2 m b r+2 b r,
which simplifies to mr+b2+bmr2+2brb(b+12r)mr(r1)m r+b^{2}+b \leq m r^{2}+2 b r \Leftrightarrow b(b+1-2 r) \leq m r(r-1). This is true since
b((br)+(1r))mr(r1). b((b-r)+(1-r)) \leq m r(r-1).
This holds since r1r \geq 1 and b<rb<r. Therefore, the left inequality holds.

We now prove the right inequality. Define the function g(r)=j=1ngj(r)g(r)=\sum_{j=1}^{n} g_{j}(r). Note that g(r)=g(1/r)g(r)=g(1 / r) for all r>0r>0. Therefore, we may assume that r1r \geq 1. We will consider two cases: rnr \geq n and 1r<n1 \leq r<n.

If rnr \geq n, then min(jr,n)=n\min (\lceil j r\rceil, n)=n and min(j/r,n)=1\min (\lceil j / r\rceil, n)=1 for all j{1,,n}j \in\{1, \ldots, n\}. Hence, gj(r)=n+1g_{j}(r)=n+1 for all j{1,,n}j \in\{1, \ldots, n\}. Therefore, g(r)=n(n+1)=n2+ng(r)=n(n+1)=n^{2}+n, implying that the inequality is true.

Now we consider the case 1r<n1 \leq r<n. Let m=n/rm=\lfloor n / r\rfloor. Hence, jrnj r \leq n for all j{1,,m}j \in\{1, \ldots, m\}, i.e. min(jr,n)=jr\min (\lceil j r\rceil, n)=\lceil j r\rceil and jrnj r \geq n for all j{m+1,,n}j \in\{m+1, \ldots, n\}, i.e. min(jr,n)=n\min (\lceil j r\rceil, n)=n. Therefore,
j=1nmin(jr,n)=j=1mjr+(nm)n \sum_{j=1}^{n} \min (\lceil j r\rceil, n)=\sum_{j=1}^{m}\lceil j r\rceil+(n-m) n
We will now consider the second sum j=1nmin{j/r,n}\sum_{j=1}^{n} \min \{\lceil j / r\rceil, n\}.
Since r1,min(j/r,n)min(n/r,n)nr \geq 1, \min (\lceil j / r\rceil, n) \leq \min (\lceil n / r\rceil, n) \leq n. Therefore, min(j/r,n)=j/r\min (\lceil j / r\rceil, n)=\lceil j / r\rceil. Since m=n/r,n/rm+1m=\lfloor n / r\rfloor,\lceil n / r\rceil \leq m+1. Since r>1,m<nr>1, m<n, which implies that m+1nm+1 \leq n. Therefore, min{j/r,n}=j/rn/rm+1\min \{\lceil j / r\rceil, n\}=\lceil j / r\rceil \leq\lceil n / r\rceil \leq m+1 for all j{1,,n}j \in\{1, \ldots, n\}.

For each positive integer k{1,,m+1}k \in\{1, \ldots, m+1\}, we now determine the number of positive integers j{1,,n}j \in\{1, \ldots, n\} such that j/r=k\lceil j / r\rceil=k. We denote this number by sks_{k}.

Note that j/r=k\lceil j / r\rceil=k if and only if k1<j/rkk-1<j / r \leq k if and only if (k1)r<jmin(kr,n)(k-1) r<j \leq \min (k r, n), since jnj \leq n. We will handle the cases k{1,,m}k \in\{1, \ldots, m\} and k=m+1k=m+1 separately. If k{1,,m}k \in\{1, \ldots, m\}, then min(kr,n)=kr\min (k r, n)=k r, since rmr \leq m and m=n/rm=\lfloor n / r\rfloor.

The set of positive integers jj satisfying (k1)r<jkr(k-1) r<j \leq k r is {(k1)r+1,,kr}\{\lfloor(k-1) r\rfloor+1,\ldots,\lfloor k r\rfloor\}. Hence,
sk=rkr(k1) s_{k}=\lfloor r k\rfloor-\lfloor r(k-1)\rfloor
for all k{1,,m}k \in\{1, \ldots, m\}. If k=m+1k=m+1, then (k1)r<jmin(kr,n)=n(k-1) r<j \leq \min (k r, n)=n. The set of positive integers jj satisfying (k1)r<jkr(k-1) r<j \leq k r is {(k1)r+1,,n}\{\lfloor(k-1) r\rfloor+1, \ldots, n\}. Then sm+1=nmrs_{m+1}=n-\lfloor m r\rfloor. Note that this number is non-negative by the definition of mm. Therefore, by the definition of sks_{k}, we have
j=1nmin(jr,n)=k=1m+1ksk=k=1m(k(kr(k1)r))+(m+1)(nrm)=(m+1)nk=1mkr. \begin{aligned} & \sum_{j=1}^{n} \min \left(\left\lceil\frac{j}{r}\right\rceil, n\right)=\sum_{k=1}^{m+1} k s_{k} \\ & \quad=\sum_{k=1}^{m}(k(\lfloor k r\rfloor-\lfloor(k-1) r\rfloor))+(m+1)(n-\lfloor r m\rfloor)=(m+1) n-\sum_{k=1}^{m}\lfloor k r\rfloor . \end{aligned}
Summing the two expressions yields that
g(r)=n2+n+j=1m(jrjr)n2+n g(r)=n^{2}+n+\sum_{j=1}^{m}(\lceil j r\rceil-\lfloor j r\rfloor) \geq n^{2}+n
which proves the right inequality.

Source: MathNet, licensed CC-BY-4.0. Statement and solution reproduced as published; topic, difficulty and ordering added by this site.