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

Similar Problems from Web Search

Share

17x+y=12,18x-y=4
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.
17x+y=12
Choose one of the equations and solve it for x by isolating x on the left hand side of the equal sign.
17x=-y+12
Subtract y from both sides of the equation.
x=\frac{1}{17}\left(-y+12\right)
Divide both sides by 17.
x=-\frac{1}{17}y+\frac{12}{17}
Multiply \frac{1}{17} times -y+12.
18\left(-\frac{1}{17}y+\frac{12}{17}\right)-y=4
Substitute \frac{-y+12}{17} for x in the other equation, 18x-y=4.
-\frac{18}{17}y+\frac{216}{17}-y=4
Multiply 18 times \frac{-y+12}{17}.
-\frac{35}{17}y+\frac{216}{17}=4
Add -\frac{18y}{17} to -y.
-\frac{35}{17}y=-\frac{148}{17}
Subtract \frac{216}{17} from both sides of the equation.
y=\frac{148}{35}
Divide both sides of the equation by -\frac{35}{17}, which is the same as multiplying both sides by the reciprocal of the fraction.
x=-\frac{1}{17}\times \frac{148}{35}+\frac{12}{17}
Substitute \frac{148}{35} for y in x=-\frac{1}{17}y+\frac{12}{17}. Because the resulting equation contains only one variable, you can solve for x directly.
x=-\frac{148}{595}+\frac{12}{17}
Multiply -\frac{1}{17} times \frac{148}{35} by multiplying numerator times numerator and denominator times denominator. Then reduce the fraction to lowest terms if possible.
x=\frac{16}{35}
Add \frac{12}{17} to -\frac{148}{595} by finding a common denominator and adding the numerators. Then reduce the fraction to lowest terms if possible.
x=\frac{16}{35},y=\frac{148}{35}
The system is now solved.
17x+y=12,18x-y=4
Put the equations in standard form and then use matrices to solve the system of equations.
\left(\begin{matrix}17&1\\18&-1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}12\\4\end{matrix}\right)
Write the equations in matrix form.
inverse(\left(\begin{matrix}17&1\\18&-1\end{matrix}\right))\left(\begin{matrix}17&1\\18&-1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=inverse(\left(\begin{matrix}17&1\\18&-1\end{matrix}\right))\left(\begin{matrix}12\\4\end{matrix}\right)
Left multiply the equation by the inverse matrix of \left(\begin{matrix}17&1\\18&-1\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}17&1\\18&-1\end{matrix}\right))\left(\begin{matrix}12\\4\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}17&1\\18&-1\end{matrix}\right))\left(\begin{matrix}12\\4\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{1}{17\left(-1\right)-18}&-\frac{1}{17\left(-1\right)-18}\\-\frac{18}{17\left(-1\right)-18}&\frac{17}{17\left(-1\right)-18}\end{matrix}\right)\left(\begin{matrix}12\\4\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{1}{35}&\frac{1}{35}\\\frac{18}{35}&-\frac{17}{35}\end{matrix}\right)\left(\begin{matrix}12\\4\end{matrix}\right)
Do the arithmetic.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{1}{35}\times 12+\frac{1}{35}\times 4\\\frac{18}{35}\times 12-\frac{17}{35}\times 4\end{matrix}\right)
Multiply the matrices.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{16}{35}\\\frac{148}{35}\end{matrix}\right)
Do the arithmetic.
x=\frac{16}{35},y=\frac{148}{35}
Extract the matrix elements x and y.
17x+y=12,18x-y=4
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.
18\times 17x+18y=18\times 12,17\times 18x+17\left(-1\right)y=17\times 4
To make 17x and 18x equal, multiply all terms on each side of the first equation by 18 and all terms on each side of the second by 17.
306x+18y=216,306x-17y=68
Simplify.
306x-306x+18y+17y=216-68
Subtract 306x-17y=68 from 306x+18y=216 by subtracting like terms on each side of the equal sign.
18y+17y=216-68
Add 306x to -306x. Terms 306x and -306x cancel out, leaving an equation with only one variable that can be solved.
35y=216-68
Add 18y to 17y.
35y=148
Add 216 to -68.
y=\frac{148}{35}
Divide both sides by 35.
18x-\frac{148}{35}=4
Substitute \frac{148}{35} for y in 18x-y=4. Because the resulting equation contains only one variable, you can solve for x directly.
18x=\frac{288}{35}
Add \frac{148}{35} to both sides of the equation.
x=\frac{16}{35}
Divide both sides by 18.
x=\frac{16}{35},y=\frac{148}{35}
The system is now solved.