MathLabs

Problem 1

In the plane, points with integer coordinates are vertices of unit squares, colored alternately black and white as on a chessboard. For positive integers m,n m,n , consider a right triangle with integer-coordinate vertices and legs of lengths m,n m,n along square edges. Let S1 S_1 be the black area and S2 S_2 the white area. Define f(m,n)=∣S1−S2∣ f(m,n)=|S_1-S_2|. (a) Calculate f(m,n) f(m,n) when m,n m,n are both even or both odd. (b) Prove f(m,n)≤max⁡(m,n)/2 f(m,n)\le\max(m,n)/2. (c) Show that no constant C C satisfies f(m,n)<C f(m,n)<C for all m,n m,n .
Step 2 of 3: Handle opposite parity
In plain words

Handle opposite parity

f(m,n)≤max⁡(m,n)2f(m,n)\le\dfrac{\max(m,n)}2
Detailed analysis

Suppose m m is odd and n n even. Increase the odd leg to m+1 m+1; the enlarged triangle has equal legs even and hence zero excess. The added triangle has base 11 and height n n , area n/2 n/2, so the original excess is at most n/2≤max⁡(m,n)/2 n/2\le\max(m,n)/2.