Problem

Source:

Tags: algebra, floor function, function, optimization



Let $r_1,r_2,\ldots,r_m$ be positive rational numbers with a sum of $1$. Find the maximum values of the function $f:\mathbb N\to\mathbb Z$ defined by $$f(n)=n-\lfloor r_1n\rfloor-\lfloor r_2n\rfloor-\ldots-\lfloor r_mn\rfloor$$