Question 106374
We are looking for the number of nickels in the machine, so let's use n = # of nickels, d = # of dimes, and q = # of quarters.  We know that the total number of coins is 195, so:

{{{q + d + n=195}}}

For convenience sake, to eliminate calculations with decimal fractions, let's consider the amount of money in the machine to be 2215 cents rather than $22.15.  Now, the number of cents in a quarter is 25, so the amount of money represented by the quarters is 25q cents.  Similarly, the dimes are worth 10d cents, and the nickels are worth 5n cents.  Putting it all together,

{{{25q+10d+5n=2215}}}


We also know that there are five times as many dimes as nickels, so:

{{{d=5n}}}


Now we have three linear equations in three variables.  Since the third equation is so simple, we can simplify the problem by an immediate substitution.  Everywhere you see d in the first two equations, substitute 5n.  That simplifies the problem to two simultaneous linear equations (Eq 1 and Eq 2)in two variables, namely q and n.

{{{q + 5n + n=195}}}
Eq 1) {{{q + 6n=195}}}


{{{25q+10(5n)+5n=2215}}}
Eq 2) {{{25q+55n=2215}}}

I chose to solve this system by multiplying the first equation by -25 yielding Eq 3, and then adding the Eq 3 and Eq 2 term by term to eliminate the variable q.

Eq 1) {{{q + 6n=195}}}


Eq 3) {{{-25q -150n=-4875}}} :Eq 1) times -25
Eq 2) +{{{25q+55n=2215}}}
--------------------------
Eq 4) {{{-95n = -2660}}}

-25q plus 25q = 0q; -150n plus 55n = -95n; and -4875 plus 2215 = -2660.  Then dividing through by -95 yields:

{{{n=28}}}, So there are 28 nickels in the machine.

Let's check the answer:

A little more arithmetic tells us that there are 28 X 5 or 140 dimes, and 195 coins - 140 dimes - 28 nickels or 27 quarters. The nickels are worth 28 X 5 cents, or $1.40.  The dimes are worth 140 X 10 cents, or $14.00, and the quarters are worth 27 X 25 cents, or $6.75.  $1.40 plus $14.00 plus $6.75 = $22.15.