```Question 117570
1) {{{4x + y = -12}}}
2) {{{2x + 2y= -15}}}

There are a number of ways to solve these, so let's look at all of them, step by step.  First, remember that an equation in two first degree variables is a description of a straight line on the xy plane.  If you have two lines, the point where they intersect (if they do intersect) is an x, y ordered pair that satisfies both equations at the same time.

First, the <b>Substitution Method:</b>

Step 1:  Solve one of the equations for one of the variables.  We'll solve equation 1) for y.

{{{4x + y = -12}}}
{{{y=-4x-12}}}  Now we have an expression for y that can be substituted for y in equation 2), giving us a single equation in a single variable.

Step 2: Substitute the expression for y in equation 2)
{{{2x + 2(-4x-12)= -15}}}

Step 3: Solve for x
{{{2x-8x-24=-15}}}
{{{-6x=9}}}
{{{x=-(9/6)=-(3/2)}}}

Step 4: Substitute this new found value for x into the form of equation 1) where we solved for y:

{{{y=-4(-3/2)-12}}}
{{{y=-6}}}

Now we know that the two lines represented by the two equations intersect in the point ({{{-3/2}}},{{{-6}}}).

Next, <b>Gaussian Elimination:</b>

Step 1: Put the equations in standard form.  {{{ax+by=c}}}  For this problem, they are already in this form.

Discussion: There are several things you can do, and the order in which you do them depends on the particular problem.  You are trying to get one of the variable coefficients (a or b in the standard form) to be zero and the other one to be 1 so that you will have the value of one of the variables.  The things you can do are:

Multiply an equation by a constant value.
Add/Subtract the two equations term by term and replace one of the equations with the result.

1) {{{4x + y = -12}}}
2) {{{2x + 2y= -15}}}

Multiply equation 2 by {{{-1/2}}}

1) {{{4x + y = -12}}}
2) {{{-x - y= 15/2}}}

Add Eq 1) and 2) and replace eq 2):

1) {{{4x + y = -12}}}
2) {{{3x +0y= -9/2}}}

Multiply Eq 2) by {{{1/3}}}

1) {{{4x + y = -12}}}
2) {{{x = -3/2}}}

Now we have a value for x, time to find y.  Multiply Eq 2) by -4:

1) {{{4x + y = -12}}}
2) {{{-4x = 6}}}

Add the two equations and replace Eq 1)

1) {{{0x + y = -6}}}
2) {{{-4x = 6}}}

And we now have a value for y.  SURPRISE!  We got the same answer as the Substitution Method  ({{{-(3/2)}}},{{{-6}}})

Next, <b>Cramer's Rule</b>

Step 1:  Create and evaluate the coefficient determinant, D, an array of the coefficients on the variables.  If you have two equations {{{red(a[1]x+b[1]y=c[1])}}} and {{{green(a[2]x+b[2]y=c[2])}}}, then the coefficient determinant is:

{{{D=(matrix(2,2,red(a[1]),red(b[1]),green(a[2]),green(b[2])))=red(a[1])*green(b[2])-green(a[2])*red(b[1])}}}

{{{D=(matrix(2,2,4,1,2,2))=4*2-2*1=6}}}

Step 2:  Create the constant matrix.  This is a single column matrix of the 'c' values

{{{(matrix(2,1,c[1],c[2]))}}}

{{{(matrix(2,1,-12,-15))}}}

Step 3:  Create the x Determinant, {{{D[x]}}} by substituting the constant matrix for the x (first) column in the coefficient matrix, {{{D}}} and then evaluate.

{{{D[x]=(matrix(2,2,red(c[1]),red(b[1]),green(c[2]),green(b[2])))=red(c[1])*green(b[2])-green(c[2])*red(b[1])}}}

{{{D[x]=(matrix(2,2,-12,1,-15,2))=-12*2-(-15)*1=-9}}}

Step 4:  Create the y Determinant.  Same as the last step, except that the constant matrix replaces the second column.

{{{D[y]=(matrix(2,2,red(a[1]),red(c[1]),green(a[2]),green(c[2])))=red(a[1])*green(c[2])-green(a[2])*red(c[1])}}}

{{{D[y]=(matrix(2,2,4,-12,2,-15))=4*(-15)-2*(-12)=-36}}}

Step 5:  Apply Cramer's Rule:

<b>Cramer's Rule</b>:  {{{x=D[x]/D}}} and {{{y=D[y]/D}}}

{{{x=-9/6=-3/2}}}
{{{y=-36/6=-6}}}

And again we get the same answer. ({{{-(3/2)}}},{{{-6}}}) I'm feeling pretty confident by now.

The one thing you have to remember with Cramer's rule is that if the coefficient determinant evaluates to zero {{{D=0}}} then you either have an inconsistent system (two parallel lines) with no solution set or a consistent and undetermined system of two coincident lines with an infinite solution set.  And you have to use another method to determine which.  The best way is to put your equations into slope-intercept form, {{{y=mx+b}}} by solving for y and reducing everything to lowest terms.  If the slope values, m, are equal but the intercepts, b, are different, you have two parallel lines.  If they are the same equation, they are the same line quite obviously.

****************************

Equations in three variables are just a more complex application of all the same principles that we just discussed.  I'm not going to explain the details, but you should be able to tell what I'm doing.  (You have an equal sign in the wrong place in the first equation, but I'm going to assume you just hit the wrong key and it should be a minus sign)

First the substitution method:
{{{2a + b -5c = -21}}}
{{{a + 2b - 2c = -15}}}
{{{a - 4b + c = 18}}}

{{{a =-2b+2c-15}}}

{{{-2b+2c-15-4b+c=18}}}
{{{-6b+3c=33}}}
{{{c=2b+11}}}

{{{a=-2b+4b+22-15}}}
{{{a=2b+7}}}

{{{2(2b+7)+b-5(2b+11)=-21}}}
{{{4b+14+b-10b-55=-21}}}
{{{-5b=-21-14+55=20}}}
{{{b=-4}}}

{{{a=2(-4)+7=-1}}}
{{{c=2(-4)+11=3}}}

Here's Cramer's Rule
Just remember that you have to repeat the first two columns when you evaluate a 3X3 Determinant

{{{D=(matrix(3,5,red(a[1]),red(b[1]),red(c[1]),red(a[1]),red(b[1]),green(a[2]),green(b[2]),green(c[2]),green(a[2]),green(b[2]),a[3],b[3],c[3],a[3],b[3]))=red(a[1])*green(b[2])*c[3]+red(b[1])*green(c[2])*a[3]+red(c[1])*green(a[2])*b[3]-a[3]*green(b[2])*red(c[1])-b[3]*green(c[2])*red(a[1])-c[3]*green(a[2])*red(b[1]))}}}

D for this problem is:

{{{D=(matrix(3,5,2,1,-5,2,1,1,2,-2,1,2,1,-4,1,1,-4))=2*2*1+1*(-2)*1+(-5)*1*(-4)-1*2*(-5)-(-4)*(-2)*2-1*1*1=4-2+20+10-16-1=25}}}

And

{{{D[x]=(matrix(3,5,-21,1,-5,-21,1,-15,2,-2,-15,2,18,-4,1,18,-4))=-42-36-300+180+168+15=-25}}}

And finally,

{{{D[x]/D=(-25)/25=-1}}}, just as we suspected.  Now that you know how to do it, I'll let you handle the arithmetic for the other two variables.

Hope that helps,
John```