document.write( "Question 158310: A farmer buys 100 animals for $100.00. The animals include at least one cow, one pig, and one chicken, but no other kind. If a cow costs $10.00, a pig costs $3.00, and a chicken costs $0.50, how many of each did he buy? \n" ); document.write( "
Algebra.Com's Answer #116712 by ptaylor(2198)![]() ![]() You can put this solution on YOUR website! This problem has been around for a looooong time. It's yet another example of having more unknowns than equations. In problems such as this, it's usually necessary to apply a great deal of trial and error coupled with the constraints inherent in the problem. Many times, there is more than one solution.\r \n" ); document.write( "\n" ); document.write( "Let x=number of chickens \n" ); document.write( "y=number of pigs \n" ); document.write( "z=number of cows\r \n" ); document.write( "\n" ); document.write( "Now we are told that: \n" ); document.write( "x+y+z=100----------------------------eq1 \n" ); document.write( "we are also told that: \n" ); document.write( "0.5x+3y+10z=100------------------------eq2 \n" ); document.write( "Multiply eq 2 by 2 and then subtract eq1 from it and we get:\r \n" ); document.write( "\n" ); document.write( "5y+19z=100 \n" ); document.write( "subtract 19z from each side\r \n" ); document.write( "\n" ); document.write( "5y=100-19z divide each side by 5\r \n" ); document.write( "\n" ); document.write( "y=(100-19z)/5----eq2a --- this equation gives us a relationship between the number of pigs (y) and the number of cows (z).\r \n" ); document.write( "\n" ); document.write( "Now we know a couple of things that will help us to solve this problem: \n" ); document.write( "(1) We cannot have fractions of animals ---we are dealing with whole numbers \n" ); document.write( "(2) We cannot have negative animals----we are dealing with positive numbers \n" ); document.write( "(3) We must, at least, have one of each animal\r \n" ); document.write( "\n" ); document.write( "By inspecting eq2a, we can quickly see that we cannot have more than 5 cows otherwise we start getting negative pigs. So, lets do some trial and error:\r \n" ); document.write( "\n" ); document.write( "If we have 5 cows-----------------y=(100-95)/5=1 BINGO!! \n" ); document.write( "So, 5 cows and 1 pig are possibilities \n" ); document.write( "Lets substitute these values into eq1 and see if they work for chickens: \n" ); document.write( "x+1+5=100 \n" ); document.write( "x=94 chickens \n" ); document.write( "Clearly the numbers check; let's see if the values check: \n" ); document.write( "94*0.5+1*3.00+ 5*10=100 \n" ); document.write( "47+3+50=100 \n" ); document.write( "100=100 \n" ); document.write( "So, 94 chicks, 1 pig and 5 cows work \n" ); document.write( "Let's see if we have other possibilities: \n" ); document.write( "If we have 4 cows-----y=(100-76)/5----No!!! we get fractions of pigs \n" ); document.write( "If we have 3 cows-----y=(100-57)/5----No!!! we get fractions of pigs \n" ); document.write( "If we have 2 cows-----y=(100-38)/5----No!!! we get fractions of pigs \n" ); document.write( "If we have 1 cow------y=(100-19)/5----No!!! we get fractions of pigs again \n" ); document.write( " \n" ); document.write( "\n" ); document.write( "Hope this helps---ptaylor \n" ); document.write( " \n" ); document.write( " |