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

Similar Problems from Web Search

Share

15x+6y=21,16x+9y=12
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.
15x+6y=21
Choose one of the equations and solve it for x by isolating x on the left hand side of the equal sign.
15x=-6y+21
Subtract 6y from both sides of the equation.
x=\frac{1}{15}\left(-6y+21\right)
Divide both sides by 15.
x=-\frac{2}{5}y+\frac{7}{5}
Multiply \frac{1}{15} times -6y+21.
16\left(-\frac{2}{5}y+\frac{7}{5}\right)+9y=12
Substitute \frac{-2y+7}{5} for x in the other equation, 16x+9y=12.
-\frac{32}{5}y+\frac{112}{5}+9y=12
Multiply 16 times \frac{-2y+7}{5}.
\frac{13}{5}y+\frac{112}{5}=12
Add -\frac{32y}{5} to 9y.
\frac{13}{5}y=-\frac{52}{5}
Subtract \frac{112}{5} from both sides of the equation.
y=-4
Divide both sides of the equation by \frac{13}{5}, which is the same as multiplying both sides by the reciprocal of the fraction.
x=-\frac{2}{5}\left(-4\right)+\frac{7}{5}
Substitute -4 for y in x=-\frac{2}{5}y+\frac{7}{5}. Because the resulting equation contains only one variable, you can solve for x directly.
x=\frac{8+7}{5}
Multiply -\frac{2}{5} times -4.
x=3
Add \frac{7}{5} to \frac{8}{5} by finding a common denominator and adding the numerators. Then reduce the fraction to lowest terms if possible.
x=3,y=-4
The system is now solved.
15x+6y=21,16x+9y=12
Put the equations in standard form and then use matrices to solve the system of equations.
\left(\begin{matrix}15&6\\16&9\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}21\\12\end{matrix}\right)
Write the equations in matrix form.
inverse(\left(\begin{matrix}15&6\\16&9\end{matrix}\right))\left(\begin{matrix}15&6\\16&9\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=inverse(\left(\begin{matrix}15&6\\16&9\end{matrix}\right))\left(\begin{matrix}21\\12\end{matrix}\right)
Left multiply the equation by the inverse matrix of \left(\begin{matrix}15&6\\16&9\end{matrix}\right).
\left(\begin{matrix}1&0\\0&1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=inverse(\left(\begin{matrix}15&6\\16&9\end{matrix}\right))\left(\begin{matrix}21\\12\end{matrix}\right)
The product of a matrix and its inverse is the identity matrix.
\left(\begin{matrix}x\\y\end{matrix}\right)=inverse(\left(\begin{matrix}15&6\\16&9\end{matrix}\right))\left(\begin{matrix}21\\12\end{matrix}\right)
Multiply the matrices on the left hand side of the equal sign.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{9}{15\times 9-6\times 16}&-\frac{6}{15\times 9-6\times 16}\\-\frac{16}{15\times 9-6\times 16}&\frac{15}{15\times 9-6\times 16}\end{matrix}\right)\left(\begin{matrix}21\\12\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}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{3}{13}&-\frac{2}{13}\\-\frac{16}{39}&\frac{5}{13}\end{matrix}\right)\left(\begin{matrix}21\\12\end{matrix}\right)
Do the arithmetic.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{3}{13}\times 21-\frac{2}{13}\times 12\\-\frac{16}{39}\times 21+\frac{5}{13}\times 12\end{matrix}\right)
Multiply the matrices.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}3\\-4\end{matrix}\right)
Do the arithmetic.
x=3,y=-4
Extract the matrix elements x and y.
15x+6y=21,16x+9y=12
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.
16\times 15x+16\times 6y=16\times 21,15\times 16x+15\times 9y=15\times 12
To make 15x and 16x equal, multiply all terms on each side of the first equation by 16 and all terms on each side of the second by 15.
240x+96y=336,240x+135y=180
Simplify.
240x-240x+96y-135y=336-180
Subtract 240x+135y=180 from 240x+96y=336 by subtracting like terms on each side of the equal sign.
96y-135y=336-180
Add 240x to -240x. Terms 240x and -240x cancel out, leaving an equation with only one variable that can be solved.
-39y=336-180
Add 96y to -135y.
-39y=156
Add 336 to -180.
y=-4
Divide both sides by -39.
16x+9\left(-4\right)=12
Substitute -4 for y in 16x+9y=12. Because the resulting equation contains only one variable, you can solve for x directly.
16x-36=12
Multiply 9 times -4.
16x=48
Add 36 to both sides of the equation.
x=3
Divide both sides by 16.
x=3,y=-4
The system is now solved.