# Math Help - Using Gaussian Elimination to solve for k

1. ## Using Gaussian Elimination to solve for k

Working on this problem. Actually 2 problems, involving Gaussian elimination. Both of them say

Find the values of $k$ such that the system has (a) a unique solution (b) no solution and (c) infinitely many solutions

I am required to use Gaussian Elimination

The first problem is
$x+ky = -1$
$kx+y = 1$

My solution is as follows, but not sure if correct (not sure how to do latex for this). I have seperated each entry by a comma (,)
row 1 = 1, k, -1
row 2 = k, 1, 1
-k * R1 + R2 = 0, -(k2)+1, k+1

(a) if k = -1 R3 = 0, 0 and has infinitely many solutions
(b) if k = 1 R3 = 0, 2 and is inconsistant
(c) if k != 1 and k != -1 the system has a unique solution

I'm not sure if that is correct. I've gone through the problem several times, and come up with the same outcome everytime, but I'm new to this. I did really well at basic Matrix stuff, but this is the next paper after the intro one.

The second problem is
$x-2y+3z = 2$
$x+y+z = k$
$2x - y + 4z = k^2$

I've gone through this a whole lot of times (I need to use Gaussian elimination) and end up with some unfactorable equation at the end. Where should I start with this problem? I don't want the answer, just some help.
What I have been doing is laying it out in a compact matrix and then multiplying the rows to eliminate the x and y values.

Here is my working - not sure if it is correct.

2. ## Re: Using Gaussian Elimination to solve for k

Hey lukasaurus.

Your first question is spot on.

For the second one I confirmed the answer in Octave which is:

>> B
B =

1 -2 3
1 1 1
2 -1 4

>> det(B)
ans = 0
>> rref(B)
ans =

1.00000 0.00000 1.66667
0.00000 1.00000 -0.66667
0.00000 0.00000 0.00000

This confirms no unique solution and this command:

>> X = [2;2;4]
X =

2
2
4

>> A = [B,X]
A =

1 -2 3 2
1 1 1 2
2 -1 4 4

>> rref(A)
ans =

1.00000 0.00000 1.66667 2.00000
0.00000 1.00000 -0.66667 0.00000
0.00000 0.00000 0.00000 0.00000

confirms that infinitely many solutions only occurs when k = 2 just as you have mentioned.

If I set k = 1 for example Octave gives us:

>> X = [2;1;1]
X =

2
1
1

>> A = [B,X]
A =

1 -2 3 2
1 1 1 1
2 -1 4 1

>> rref(A)
ans =

1.00000 0.00000 1.66667 0.00000
0.00000 1.00000 -0.66667 0.00000
0.00000 0.00000 0.00000 1.00000

which is inconsistent (note the 1.0000).

3. ## Re: Using Gaussian Elimination to solve for k

Thanks so much,

Is there a calculator that can do Matrix calculations? Last exam I had there were no calculator restrictions and I was using an old fx82 casio (because I haven't been in Uni or high school for about 15 years and it was all I had).

And what is Octave?

4. ## Re: Using Gaussian Elimination to solve for k

Octave is basically a free version of MATLAB which has a lot of the same features and is open source.

You can also get what is known as GUIOctave which provides the front-end to make it look like MATLAB.

GNU Octave

Download GUI Octave 1.5.4 Free - A GUI for Octave. - Softpedia