  In 2000, A. Tripathi used generating functions to obtain a formula for the
number of non-negative solutions (x,y) of the equation ax + by = n where a, b
and n are given positive integers. We generalize this procedure for the number
of solutions of the equation ax + by + cz = n. The formula leads us to a
surprising connection between the number of solutions of the equation ax + by +
cz = n and quadratic residues. As a consequence of our work, we are able to
prove the equivalence between two fundamental results by Gauss and Sylvester in
the nineteenth century which are generally viewed to be independent.

Number Theory