Problem 802: (2021 AMC 10b, 25; 2021 AMC 12b, 25)
Let $S$ be the set of lattice points in the coordinate plane, both of whose coordinates are integers between $1$ and $30$, inclusive. Exactly $300$ points in $S$ lie on or below a line with equation $y = mx$. The possible values of $m$ lie in an interval of length $\frac{a}{b}$, where $a$ and $b$ are relatively prime positive integers. What is $a + b ?
$ $\textbf{(A)} ~31 \qquad\textbf{(B)} ~47 \qquad\textbf{(C)} ~62 \qquad\textbf{(D)} ~72 \qquad\textbf{(E)} ~85$
- For slope $m$, the number of points of $S$ on or below $y=mx$ is $\sum_{x=1}^{30}\min(30,\lfloor mx\rfloor)$.
- At $m=\frac23$: grouping $x=3k-2,3k-1,3k$ gives $(2k-2)+(2k-1)+2k=6k-3$, and $\sum_{k=1}^{10}(6k-3)=300$. For $m$ slightly less than $\frac23$, the $10$ points $(3k,2k)$ are lost, so $m\ge\frac23$.
- The count stays $300$ until the line reaches the next point of $S$ above it. For $\frac yx>\frac23$, $\frac yx-\frac23=\frac{3y-2x}{3x}\ge\frac1{3x}$, which is smallest for $3y-2x=1$ with $x$ as large as possible: $x=28$, $y=19$, difference $\frac1{84}$ (other choices give at least $\frac{2}{90}>\frac1{84}$ or $\frac1{3x}$ with $x<28$).
- So $m\in\left[\frac23,\frac{19}{28}\right)$, of length $\frac1{84}$, and $a+b=85$.
- The answer is (E).
Let $S$ be the set of lattice points whose coordinates are both integers from $1$ to $10$. Exactly $40$ points of $S$ lie on or below a line $y=mx$. The possible values of $m$ lie in an interval of length $\frac ab$, where $a$ and $b$ are relatively prime positive integers. What is $a+b$?