1
$\begingroup$

I'm studying for a Linear Algebra exam, and having difficulty with solving matrices in a timely manner. Our professor provided us with several sample exams to practice with, which begin with a matrix (generally 3x4 augmented) that needs to be solved for unique, infinite, and no solutions. To make things trickier, the matrices generally contain at least one variable placed in ways that deliberately resist solving, like: $$ A = \left[\begin{array}{rrr|r} 1 & 1 & a & -1 \\ 3 & (a+1) & (a-1) &-1\\ a&2&1&0 \end{array}\right] $$ or $$ A= \left[\begin{array}{rrr|r} 1 & -2 & 0 & 1 \\ 1 & -1 & \lambda &2\\ 0 & \lambda & 9 & \mu \end{array}\right] $$ We're supposed to solve these through Gaussian Elimination, which as I understand it is doing different matrix transformations over and over until you happen across a solution. That sort of experimentation takes a ton of time, but it seems awfully random for math. Is there a linear progression to take when solving matrices, or any analysis / tests to check prior that can speed up the process?

Failing that, does anyone have any tips they think might help? Any help would be immensely appreciated. Thanks!

$\endgroup$
0
$\begingroup$

Performing gaussian elimination on a matrix is an algorithmic procedure which you should be able to apply to any matrix without "thinking" too much. Namely, you shouldn't apply random row operations, but you should apply them in a specific way that is guaranteed to lead to a simple system from which the solutions can be read immediately. When there are parameters involved, one should postpone using the parameters to eliminate rows as long as possible in order to not handle different cases (something is zero, something is not zero). Let me demonstrate this on your first matrix:

  1. The first thing to do is to perform a row operation which makes the $(1,1)$ entry of the matrix non-zero (and preferably, not a parameter). That is, switch the first row with some other row to make the $(1,1)$-entry non-zero. If all the entries in the first column are zero, this is not possible and you move to the next column. If there are parameters and constants, make the $(1,1)$ entry constant. For the first matrix, this is already the case.
  2. The next step is to perform row operations that will make all the other entries in the first row zero. In our case, $$ \left[\begin{array}{rrr|r} 1 & 1 & a & -1 \\ 3 & (a+1) & (a-1) &-1\\ a&2&1&0 \end{array}\right] \xrightarrow{R_2 = R_2 - 3R_1, R_3 = R_3 - aR_1} \left[\begin{array}{rrr|r} 1 & 1 & a & -1 \\ 0 & (a-2) & (-2a-1) &0 \\ 0 & 2 - a & 1 - a^2 & a \end{array}\right]. $$
  3. At this point, we move to the second column. By performing a row switching operation between the second row and some $i$-th row when $i > 2$, we can try and make the $(2,2)$-entry of the matrix non-zero (and if possible, a constant). If this is not possible, we move to the third column. In our case, the $(2,2)$-entry is $a - 2$ which is a parameter and we can't switch it with a row that has a non-parameter entry so we leave it.
  4. Next, we use the $(2,2)$-entry to cancel all the $(i,2)$-entries for $i > 2$. In our case, $$ \left[\begin{array}{rrr|r} 1 & 1 & a & -1 \\ 0 & (a-2) & (-2a-1) &0 \\ 0 & 2 - a & 1 - a^2 & a \end{array}\right] \xrightarrow{R_3 = R_3 + R_2} \left[\begin{array}{rrr|r} 1 & 1 & a & -1 \\ 0 & (a-2) & (-2a-1) &0 \\ 0 & 0 & - a^2 - 2a & a \end{array}\right]. $$

That's it. The final $3 \times 3$ part of the augmented system is upper triangular. The equivalent system we got is

$$ x_1 + x_2 + a x_3 = -1, \\ (a-2)x_2 - (2a + 1)x_3 = 0, \\ -(a^2 + 2a)x_3 = a. $$

When does this system has a solution? Start with the last equation which has the simplest form. If $a^2 + 2a \neq 0$ then $x_3 = -\frac{a}{a^2 + 2a}$ so there is a unique value of $x_3$ which satisfies the equation. If $a = 0$ then we get the equation $0 \cdot x_3 = 0$ which has infinitely many solutions. If $a = 2$ then we get the equation $0 \cdot x_3 = 2$ which has no solutions. Now we perform back substitution. Given $x_3$, we see that the second equation has a unique solution if $a \neq 2$ and we don't need to bother about the case $a = 2$ because the third equation cannot be solved. Finally, we move to the first equation in which we see that given $x_3,x_2$ we see that $x_1$ is determined uniquely. Let us summarize:

  1. If $a = 0$ then there are infinitely many solutions (the dimension of the space of solutions will be one).
  2. If $a = 2$ then there are no solutions.
  3. If $a \neq 0,2$ then the system will have a unique solution.

It takes some practice but after a few exercises of this sort you'll see that you will be able to do the operations quickly and in a systematic way. For practice, I suggest you try the approach above with the second matrix and post your results. I'll be happy to upvote and comment on your attempt.


For the second matrix, we have

$$ \left[\begin{array}{rrr|r} 1 & -2 & 0 & 1 \\ 1 & -1 & \lambda &2\\ 0 & \lambda & 9 & \mu \end{array}\right] \xrightarrow{R_2 = R_2 - R_1} \left[\begin{array}{rrr|r} 1 & -2 & 0 & 1 \\ 0 & 1 & \lambda & 1 \\ 0 & \lambda & 9 & \mu \end{array}\right] \xrightarrow{R_3 = R_3 - \lambda R_1} \left[\begin{array}{rrr|r} 1 & -2 & 0 & 1 \\ 0 & 1 & \lambda & 1 \\ 0 & 0 & 9 - \lambda^2 & \mu - \lambda \end{array}\right].$$

This corresponds to the system of equations $$ x_1 - 2x_2 = 1, \\ x_2 + \lambda x_3 = 1, \\ (9 - \lambda^2) x_3 = \mu - \lambda. $$

Start again from the last equation. If $9 - \lambda^2 \neq 0$ then $x_3$ is determined uniquely as $x_3 = \frac{\mu - \lambda}{9 - \lambda^2}$. If $9 = \lambda^2$ (so $\lambda = \pm 3$) the equation reads $0 \cdot x_3 = \mu - \lambda$. This equation has infinitely many solutions if $\mu = \lambda$ and no solutions otherwise. Moving to the second equation, we see that given $x_3$, $x_2$ is determined uniquely and given $x_3,x_2$ the first equation determines $x_1$ uniquely. Hence, we have three cases:

  1. If $\lambda \neq \pm 3$, the system has a unique solution.
  2. If $\lambda = \mu = 3$ or $\lambda = \mu = -3$ the system has infinitely many solutions (the dimension of the solution space is one).
  3. If $\lambda = 3$ but $\mu \neq 3$ or $\lambda = -3$ but $\mu \neq -3$ the system has no solutions.
$\endgroup$
  • $\begingroup$ For a $3 \times 3$ matrix (augmented or not), you'll need at most $3$ operations to bring it to an upper triangular form so you can see that this isn't much work once you get used to it. For your second matrix, you can perform two operations in order to reduce the system to a system which can be analyzed directly. $\endgroup$ – levap Mar 1 '17 at 15:16
  • $\begingroup$ Very helpful, thanks! Trying the second matrix currently. $\endgroup$ – Evan Mar 1 '17 at 15:29
  • $\begingroup$ I got it down to an upper triangular really quickly, where $\left[\begin{array}{rrr|r} 1 & -2 & 1 & 1 \\ 0 & \lambda & 9 & \mu \\ 0 & 0 & \lambda - 9 & \lambda - \mu \end{array}\right]$ but wasn't sure how to solve it, so I reduced it to ref $\left[\begin{array}{rrr|r} 1 & -2 & 1 & 1 \\ 0 & 1 & 1 & 1 \\ 0 & 0 & 1 & (\lambda - \mu) \over (\lambda - 9) \end{array}\right]$ and now with all the variables in $R_3$ I'm even less sure. $\endgroup$ – Evan Mar 1 '17 at 15:58
  • $\begingroup$ Your upper triangular form is wrong. I've added the analysis of the second matrix in my answer. $\endgroup$ – levap Mar 1 '17 at 16:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.