If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

# Direct variation word problem: filling gas

## Video transcript

we're told that the total cost of filling up your car with gas varies directly varies directly with the number of gallons of gasoline you are purchasing so this first statement tells us that if X is equal to the number of gallons number of gallons gallons purchased and y is equal to the cost of filling up the car filling car this first statement tells us that Y it varies directly with the number of gallons with X so that means that y is equal to some constant some constant we'll just call that K times X this is what it means to vary directly if X goes up Y will go up we don't know what the rate is K tells us the rate if X goes down Y will be down now they give us more information and this will help us figure out what K is if a gallon of gas if a gallon of gas cost 225 how many gallons could you purchase for \$18 so if X is equal to 1 this this statement up here a gallon of gas that tells us if we get one gallon if X is equal to one then Y is 225 right Y is what it costs they tell us one gallon cost 225 so you could write it right here 225 is equal to K times X times 1 times 1 well I don't even have to write that x 1 there it's essentially telling us exactly what the rate is what K is we don't even have to write that 1 there K is equal to 2 point 2 5 that's what this told us right there so the equation how Y varies with X is y is equal to 2 point 2 5 X where X is the number of gallons we purchase Y is the cost of that purchase so it's 225 a gallon and then they ask us how many gallons how many gallons could you purchase for \$18 so \$18 is going to be our total cost it is y cost of filling the car so 18 is going to be equal to 2 point 2 5 X now if we want to solve for X we can divide both sides by 2.25 so let's do that you divide 18 by 2.25 divide 2.25 x by 2.25 and what do we get let me scroll down a little bit the right-hand side the 2.2 5s cancel out you get X and then what is 18 divided by 2 point 2 5 so let me write this down so first of all I just like to think of it as a fraction 2.25 is the same thing let me write it over here 2.25 is equal to 2 and 1/4 which is the same thing as 9 over 4 so 18 divided by 18 divided by 2 point 2 5 is equal to 18 divided by 9 over 4 which is equal to 18 times 4 over 9 or 18 over 1 times 4 over 9 and let's see 18 divided by 9 18 divided by 9 is 2 9 divided by 9 is 1 that simplifies pretty nicely into 8 so 18 divided by 2 point 2 5 is 8 so we can buy 8 gallons for \$18.00