Skip to main content
Solve for y, x
Tick mark Image
Graph

Similar Problems from Web Search

Share

5y+4x=21,2y+8x=54
To solve a pair of equations using substitution, first solve one of the equations for one of the variables. Then substitute the result for that variable in the other equation.
5y+4x=21
Choose one of the equations and solve it for y by isolating y on the left hand side of the equal sign.
5y=-4x+21
Subtract 4x from both sides of the equation.
y=\frac{1}{5}\left(-4x+21\right)
Divide both sides by 5.
y=-\frac{4}{5}x+\frac{21}{5}
Multiply \frac{1}{5} times -4x+21.
2\left(-\frac{4}{5}x+\frac{21}{5}\right)+8x=54
Substitute \frac{-4x+21}{5} for y in the other equation, 2y+8x=54.
-\frac{8}{5}x+\frac{42}{5}+8x=54
Multiply 2 times \frac{-4x+21}{5}.
\frac{32}{5}x+\frac{42}{5}=54
Add -\frac{8x}{5} to 8x.
\frac{32}{5}x=\frac{228}{5}
Subtract \frac{42}{5} from both sides of the equation.
x=\frac{57}{8}
Divide both sides of the equation by \frac{32}{5}, which is the same as multiplying both sides by the reciprocal of the fraction.
y=-\frac{4}{5}\times \frac{57}{8}+\frac{21}{5}
Substitute \frac{57}{8} for x in y=-\frac{4}{5}x+\frac{21}{5}. Because the resulting equation contains only one variable, you can solve for y directly.
y=-\frac{57}{10}+\frac{21}{5}
Multiply -\frac{4}{5} times \frac{57}{8} by multiplying numerator times numerator and denominator times denominator. Then reduce the fraction to lowest terms if possible.
y=-\frac{3}{2}
Add \frac{21}{5} to -\frac{57}{10} by finding a common denominator and adding the numerators. Then reduce the fraction to lowest terms if possible.
y=-\frac{3}{2},x=\frac{57}{8}
The system is now solved.
5y+4x=21,2y+8x=54
Put the equations in standard form and then use matrices to solve the system of equations.
\left(\begin{matrix}5&4\\2&8\end{matrix}\right)\left(\begin{matrix}y\\x\end{matrix}\right)=\left(\begin{matrix}21\\54\end{matrix}\right)
Write the equations in matrix form.
inverse(\left(\begin{matrix}5&4\\2&8\end{matrix}\right))\left(\begin{matrix}5&4\\2&8\end{matrix}\right)\left(\begin{matrix}y\\x\end{matrix}\right)=inverse(\left(\begin{matrix}5&4\\2&8\end{matrix}\right))\left(\begin{matrix}21\\54\end{matrix}\right)
Left multiply the equation by the inverse matrix of \left(\begin{matrix}5&4\\2&8\end{matrix}\right).
\left(\begin{matrix}1&0\\0&1\end{matrix}\right)\left(\begin{matrix}y\\x\end{matrix}\right)=inverse(\left(\begin{matrix}5&4\\2&8\end{matrix}\right))\left(\begin{matrix}21\\54\end{matrix}\right)
The product of a matrix and its inverse is the identity matrix.
\left(\begin{matrix}y\\x\end{matrix}\right)=inverse(\left(\begin{matrix}5&4\\2&8\end{matrix}\right))\left(\begin{matrix}21\\54\end{matrix}\right)
Multiply the matrices on the left hand side of the equal sign.
\left(\begin{matrix}y\\x\end{matrix}\right)=\left(\begin{matrix}\frac{8}{5\times 8-4\times 2}&-\frac{4}{5\times 8-4\times 2}\\-\frac{2}{5\times 8-4\times 2}&\frac{5}{5\times 8-4\times 2}\end{matrix}\right)\left(\begin{matrix}21\\54\end{matrix}\right)
For the 2\times 2 matrix \left(\begin{matrix}a&b\\c&d\end{matrix}\right), the inverse matrix is \left(\begin{matrix}\frac{d}{ad-bc}&\frac{-b}{ad-bc}\\\frac{-c}{ad-bc}&\frac{a}{ad-bc}\end{matrix}\right), so the matrix equation can be rewritten as a matrix multiplication problem.
\left(\begin{matrix}y\\x\end{matrix}\right)=\left(\begin{matrix}\frac{1}{4}&-\frac{1}{8}\\-\frac{1}{16}&\frac{5}{32}\end{matrix}\right)\left(\begin{matrix}21\\54\end{matrix}\right)
Do the arithmetic.
\left(\begin{matrix}y\\x\end{matrix}\right)=\left(\begin{matrix}\frac{1}{4}\times 21-\frac{1}{8}\times 54\\-\frac{1}{16}\times 21+\frac{5}{32}\times 54\end{matrix}\right)
Multiply the matrices.
\left(\begin{matrix}y\\x\end{matrix}\right)=\left(\begin{matrix}-\frac{3}{2}\\\frac{57}{8}\end{matrix}\right)
Do the arithmetic.
y=-\frac{3}{2},x=\frac{57}{8}
Extract the matrix elements y and x.
5y+4x=21,2y+8x=54
In order to solve by elimination, coefficients of one of the variables must be the same in both equations so that the variable will cancel out when one equation is subtracted from the other.
2\times 5y+2\times 4x=2\times 21,5\times 2y+5\times 8x=5\times 54
To make 5y and 2y equal, multiply all terms on each side of the first equation by 2 and all terms on each side of the second by 5.
10y+8x=42,10y+40x=270
Simplify.
10y-10y+8x-40x=42-270
Subtract 10y+40x=270 from 10y+8x=42 by subtracting like terms on each side of the equal sign.
8x-40x=42-270
Add 10y to -10y. Terms 10y and -10y cancel out, leaving an equation with only one variable that can be solved.
-32x=42-270
Add 8x to -40x.
-32x=-228
Add 42 to -270.
x=\frac{57}{8}
Divide both sides by -32.
2y+8\times \frac{57}{8}=54
Substitute \frac{57}{8} for x in 2y+8x=54. Because the resulting equation contains only one variable, you can solve for y directly.
2y+57=54
Multiply 8 times \frac{57}{8}.
2y=-3
Subtract 57 from both sides of the equation.
y=-\frac{3}{2}
Divide both sides by 2.
y=-\frac{3}{2},x=\frac{57}{8}
The system is now solved.