Skip to main content
Solve for x, y (complex solution)
Tick mark Image
Solve for x, y
Tick mark Image
Graph

Similar Problems from Web Search

Share

ax+\left(-2b\right)y=2,2x-y=7
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.
ax+\left(-2b\right)y=2
Choose one of the equations and solve it for x by isolating x on the left hand side of the equal sign.
ax=2by+2
Add 2by to both sides of the equation.
x=\frac{1}{a}\left(2by+2\right)
Divide both sides by a.
x=\frac{2b}{a}y+\frac{2}{a}
Multiply \frac{1}{a} times 2by+2.
2\left(\frac{2b}{a}y+\frac{2}{a}\right)-y=7
Substitute \frac{2\left(by+1\right)}{a} for x in the other equation, 2x-y=7.
\frac{4b}{a}y+\frac{4}{a}-y=7
Multiply 2 times \frac{2\left(by+1\right)}{a}.
\left(\frac{4b}{a}-1\right)y+\frac{4}{a}=7
Add \frac{4by}{a} to -y.
\left(\frac{4b}{a}-1\right)y=7-\frac{4}{a}
Subtract \frac{4}{a} from both sides of the equation.
y=\frac{7a-4}{4b-a}
Divide both sides by \frac{4b}{a}-1.
x=\frac{2b}{a}\times \frac{7a-4}{4b-a}+\frac{2}{a}
Substitute \frac{7a-4}{4b-a} for y in x=\frac{2b}{a}y+\frac{2}{a}. Because the resulting equation contains only one variable, you can solve for x directly.
x=\frac{2b\left(7a-4\right)}{a\left(4b-a\right)}+\frac{2}{a}
Multiply \frac{2b}{a} times \frac{7a-4}{4b-a}.
x=\frac{2\left(7b-1\right)}{4b-a}
Add \frac{2}{a} to \frac{2b\left(7a-4\right)}{a\left(4b-a\right)}.
x=\frac{2\left(7b-1\right)}{4b-a},y=\frac{7a-4}{4b-a}
The system is now solved.
ax+\left(-2b\right)y=2,2x-y=7
Put the equations in standard form and then use matrices to solve the system of equations.
\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}2\\7\end{matrix}\right)
Write the equations in matrix form.
inverse(\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=inverse(\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}2\\7\end{matrix}\right)
Left multiply the equation by the inverse matrix of \left(\begin{matrix}a&-2b\\2&-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}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}2\\7\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}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}2\\7\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}{a\left(-1\right)-\left(-2b\right)\times 2}&-\frac{-2b}{a\left(-1\right)-\left(-2b\right)\times 2}\\-\frac{2}{a\left(-1\right)-\left(-2b\right)\times 2}&\frac{a}{a\left(-1\right)-\left(-2b\right)\times 2}\end{matrix}\right)\left(\begin{matrix}2\\7\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}{4b-a}&\frac{2b}{4b-a}\\-\frac{2}{4b-a}&\frac{a}{4b-a}\end{matrix}\right)\left(\begin{matrix}2\\7\end{matrix}\right)
Do the arithmetic.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\left(-\frac{1}{4b-a}\right)\times 2+\frac{2b}{4b-a}\times 7\\\left(-\frac{2}{4b-a}\right)\times 2+\frac{a}{4b-a}\times 7\end{matrix}\right)
Multiply the matrices.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{2\left(7b-1\right)}{4b-a}\\\frac{7a-4}{4b-a}\end{matrix}\right)
Do the arithmetic.
x=\frac{2\left(7b-1\right)}{4b-a},y=\frac{7a-4}{4b-a}
Extract the matrix elements x and y.
ax+\left(-2b\right)y=2,2x-y=7
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.
2ax+2\left(-2b\right)y=2\times 2,a\times 2x+a\left(-1\right)y=a\times 7
To make ax and 2x equal, multiply all terms on each side of the first equation by 2 and all terms on each side of the second by a.
2ax+\left(-4b\right)y=4,2ax+\left(-a\right)y=7a
Simplify.
2ax+\left(-2a\right)x+\left(-4b\right)y+ay=4-7a
Subtract 2ax+\left(-a\right)y=7a from 2ax+\left(-4b\right)y=4 by subtracting like terms on each side of the equal sign.
\left(-4b\right)y+ay=4-7a
Add 2ax to -2ax. Terms 2ax and -2ax cancel out, leaving an equation with only one variable that can be solved.
\left(a-4b\right)y=4-7a
Add -4by to ay.
y=\frac{4-7a}{a-4b}
Divide both sides by -4b+a.
2x-\frac{4-7a}{a-4b}=7
Substitute \frac{4-7a}{-4b+a} for y in 2x-y=7. Because the resulting equation contains only one variable, you can solve for x directly.
2x=\frac{4\left(1-7b\right)}{a-4b}
Add \frac{4-7a}{-4b+a} to both sides of the equation.
x=\frac{2\left(1-7b\right)}{a-4b}
Divide both sides by 2.
x=\frac{2\left(1-7b\right)}{a-4b},y=\frac{4-7a}{a-4b}
The system is now solved.
ax+\left(-2b\right)y=2,2x-y=7
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.
ax+\left(-2b\right)y=2
Choose one of the equations and solve it for x by isolating x on the left hand side of the equal sign.
ax=2by+2
Add 2by to both sides of the equation.
x=\frac{1}{a}\left(2by+2\right)
Divide both sides by a.
x=\frac{2b}{a}y+\frac{2}{a}
Multiply \frac{1}{a} times 2by+2.
2\left(\frac{2b}{a}y+\frac{2}{a}\right)-y=7
Substitute \frac{2\left(by+1\right)}{a} for x in the other equation, 2x-y=7.
\frac{4b}{a}y+\frac{4}{a}-y=7
Multiply 2 times \frac{2\left(by+1\right)}{a}.
\left(\frac{4b}{a}-1\right)y+\frac{4}{a}=7
Add \frac{4by}{a} to -y.
\left(\frac{4b}{a}-1\right)y=7-\frac{4}{a}
Subtract \frac{4}{a} from both sides of the equation.
y=\frac{7a-4}{4b-a}
Divide both sides by \frac{4b}{a}-1.
x=\frac{2b}{a}\times \frac{7a-4}{4b-a}+\frac{2}{a}
Substitute \frac{7a-4}{4b-a} for y in x=\frac{2b}{a}y+\frac{2}{a}. Because the resulting equation contains only one variable, you can solve for x directly.
x=\frac{2b\left(7a-4\right)}{a\left(4b-a\right)}+\frac{2}{a}
Multiply \frac{2b}{a} times \frac{7a-4}{4b-a}.
x=\frac{2\left(7b-1\right)}{4b-a}
Add \frac{2}{a} to \frac{2b\left(7a-4\right)}{a\left(4b-a\right)}.
x=\frac{2\left(7b-1\right)}{4b-a},y=\frac{7a-4}{4b-a}
The system is now solved.
ax+\left(-2b\right)y=2,2x-y=7
Put the equations in standard form and then use matrices to solve the system of equations.
\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}2\\7\end{matrix}\right)
Write the equations in matrix form.
inverse(\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right)\left(\begin{matrix}x\\y\end{matrix}\right)=inverse(\left(\begin{matrix}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}2\\7\end{matrix}\right)
Left multiply the equation by the inverse matrix of \left(\begin{matrix}a&-2b\\2&-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}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}2\\7\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}a&-2b\\2&-1\end{matrix}\right))\left(\begin{matrix}2\\7\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}{a\left(-1\right)-\left(-2b\right)\times 2}&-\frac{-2b}{a\left(-1\right)-\left(-2b\right)\times 2}\\-\frac{2}{a\left(-1\right)-\left(-2b\right)\times 2}&\frac{a}{a\left(-1\right)-\left(-2b\right)\times 2}\end{matrix}\right)\left(\begin{matrix}2\\7\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}{4b-a}&\frac{2b}{4b-a}\\-\frac{2}{4b-a}&\frac{a}{4b-a}\end{matrix}\right)\left(\begin{matrix}2\\7\end{matrix}\right)
Do the arithmetic.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\left(-\frac{1}{4b-a}\right)\times 2+\frac{2b}{4b-a}\times 7\\\left(-\frac{2}{4b-a}\right)\times 2+\frac{a}{4b-a}\times 7\end{matrix}\right)
Multiply the matrices.
\left(\begin{matrix}x\\y\end{matrix}\right)=\left(\begin{matrix}\frac{2\left(7b-1\right)}{4b-a}\\\frac{7a-4}{4b-a}\end{matrix}\right)
Do the arithmetic.
x=\frac{2\left(7b-1\right)}{4b-a},y=\frac{7a-4}{4b-a}
Extract the matrix elements x and y.
ax+\left(-2b\right)y=2,2x-y=7
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.
2ax+2\left(-2b\right)y=2\times 2,a\times 2x+a\left(-1\right)y=a\times 7
To make ax and 2x equal, multiply all terms on each side of the first equation by 2 and all terms on each side of the second by a.
2ax+\left(-4b\right)y=4,2ax+\left(-a\right)y=7a
Simplify.
2ax+\left(-2a\right)x+\left(-4b\right)y+ay=4-7a
Subtract 2ax+\left(-a\right)y=7a from 2ax+\left(-4b\right)y=4 by subtracting like terms on each side of the equal sign.
\left(-4b\right)y+ay=4-7a
Add 2ax to -2ax. Terms 2ax and -2ax cancel out, leaving an equation with only one variable that can be solved.
\left(a-4b\right)y=4-7a
Add -4by to ay.
y=\frac{4-7a}{a-4b}
Divide both sides by -4b+a.
2x-\frac{4-7a}{a-4b}=7
Substitute \frac{4-7a}{-4b+a} for y in 2x-y=7. Because the resulting equation contains only one variable, you can solve for x directly.
2x=\frac{4\left(1-7b\right)}{a-4b}
Add \frac{4-7a}{-4b+a} to both sides of the equation.
x=\frac{2\left(1-7b\right)}{a-4b}
Divide both sides by 2.
x=\frac{2\left(1-7b\right)}{a-4b},y=\frac{4-7a}{a-4b}
The system is now solved.