Solve for p, s
s=173
p=373
Share
Copied to clipboard
8p+5s=3849,7p+7s=3822
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.
8p+5s=3849
Choose one of the equations and solve it for p by isolating p on the left hand side of the equal sign.
8p=-5s+3849
Subtract 5s from both sides of the equation.
p=\frac{1}{8}\left(-5s+3849\right)
Divide both sides by 8.
p=-\frac{5}{8}s+\frac{3849}{8}
Multiply \frac{1}{8} times -5s+3849.
7\left(-\frac{5}{8}s+\frac{3849}{8}\right)+7s=3822
Substitute \frac{-5s+3849}{8} for p in the other equation, 7p+7s=3822.
-\frac{35}{8}s+\frac{26943}{8}+7s=3822
Multiply 7 times \frac{-5s+3849}{8}.
\frac{21}{8}s+\frac{26943}{8}=3822
Add -\frac{35s}{8} to 7s.
\frac{21}{8}s=\frac{3633}{8}
Subtract \frac{26943}{8} from both sides of the equation.
s=173
Divide both sides of the equation by \frac{21}{8}, which is the same as multiplying both sides by the reciprocal of the fraction.
p=-\frac{5}{8}\times 173+\frac{3849}{8}
Substitute 173 for s in p=-\frac{5}{8}s+\frac{3849}{8}. Because the resulting equation contains only one variable, you can solve for p directly.
p=\frac{-865+3849}{8}
Multiply -\frac{5}{8} times 173.
p=373
Add \frac{3849}{8} to -\frac{865}{8} by finding a common denominator and adding the numerators. Then reduce the fraction to lowest terms if possible.
p=373,s=173
The system is now solved.
8p+5s=3849,7p+7s=3822
Put the equations in standard form and then use matrices to solve the system of equations.
\left(\begin{matrix}8&5\\7&7\end{matrix}\right)\left(\begin{matrix}p\\s\end{matrix}\right)=\left(\begin{matrix}3849\\3822\end{matrix}\right)
Write the equations in matrix form.
inverse(\left(\begin{matrix}8&5\\7&7\end{matrix}\right))\left(\begin{matrix}8&5\\7&7\end{matrix}\right)\left(\begin{matrix}p\\s\end{matrix}\right)=inverse(\left(\begin{matrix}8&5\\7&7\end{matrix}\right))\left(\begin{matrix}3849\\3822\end{matrix}\right)
Left multiply the equation by the inverse matrix of \left(\begin{matrix}8&5\\7&7\end{matrix}\right).
\left(\begin{matrix}1&0\\0&1\end{matrix}\right)\left(\begin{matrix}p\\s\end{matrix}\right)=inverse(\left(\begin{matrix}8&5\\7&7\end{matrix}\right))\left(\begin{matrix}3849\\3822\end{matrix}\right)
The product of a matrix and its inverse is the identity matrix.
\left(\begin{matrix}p\\s\end{matrix}\right)=inverse(\left(\begin{matrix}8&5\\7&7\end{matrix}\right))\left(\begin{matrix}3849\\3822\end{matrix}\right)
Multiply the matrices on the left hand side of the equal sign.
\left(\begin{matrix}p\\s\end{matrix}\right)=\left(\begin{matrix}\frac{7}{8\times 7-5\times 7}&-\frac{5}{8\times 7-5\times 7}\\-\frac{7}{8\times 7-5\times 7}&\frac{8}{8\times 7-5\times 7}\end{matrix}\right)\left(\begin{matrix}3849\\3822\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}p\\s\end{matrix}\right)=\left(\begin{matrix}\frac{1}{3}&-\frac{5}{21}\\-\frac{1}{3}&\frac{8}{21}\end{matrix}\right)\left(\begin{matrix}3849\\3822\end{matrix}\right)
Do the arithmetic.
\left(\begin{matrix}p\\s\end{matrix}\right)=\left(\begin{matrix}\frac{1}{3}\times 3849-\frac{5}{21}\times 3822\\-\frac{1}{3}\times 3849+\frac{8}{21}\times 3822\end{matrix}\right)
Multiply the matrices.
\left(\begin{matrix}p\\s\end{matrix}\right)=\left(\begin{matrix}373\\173\end{matrix}\right)
Do the arithmetic.
p=373,s=173
Extract the matrix elements p and s.
8p+5s=3849,7p+7s=3822
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.
7\times 8p+7\times 5s=7\times 3849,8\times 7p+8\times 7s=8\times 3822
To make 8p and 7p equal, multiply all terms on each side of the first equation by 7 and all terms on each side of the second by 8.
56p+35s=26943,56p+56s=30576
Simplify.
56p-56p+35s-56s=26943-30576
Subtract 56p+56s=30576 from 56p+35s=26943 by subtracting like terms on each side of the equal sign.
35s-56s=26943-30576
Add 56p to -56p. Terms 56p and -56p cancel out, leaving an equation with only one variable that can be solved.
-21s=26943-30576
Add 35s to -56s.
-21s=-3633
Add 26943 to -30576.
s=173
Divide both sides by -21.
7p+7\times 173=3822
Substitute 173 for s in 7p+7s=3822. Because the resulting equation contains only one variable, you can solve for p directly.
7p+1211=3822
Multiply 7 times 173.
7p=2611
Subtract 1211 from both sides of the equation.
p=373
Divide both sides by 7.
p=373,s=173
The system is now solved.
Examples
Quadratic equation
{ x } ^ { 2 } - 4 x - 5 = 0
Trigonometry
4 \sin \theta \cos \theta = 2 \sin \theta
Linear equation
y = 3x + 4
Arithmetic
699 * 533
Matrix
\left[ \begin{array} { l l } { 2 } & { 3 } \\ { 5 } & { 4 } \end{array} \right] \left[ \begin{array} { l l l } { 2 } & { 0 } & { 3 } \\ { -1 } & { 1 } & { 5 } \end{array} \right]
Simultaneous equation
\left. \begin{cases} { 8x+2y = 46 } \\ { 7x+3y = 47 } \end{cases} \right.
Differentiation
\frac { d } { d x } \frac { ( 3 x ^ { 2 } - 2 ) } { ( x - 5 ) }
Integration
\int _ { 0 } ^ { 1 } x e ^ { - x ^ { 2 } } d x
Limits
\lim _{x \rightarrow-3} \frac{x^{2}-9}{x^{2}+2 x-3}