# How do I find the unique solution to this linear system?

The question is based on an exercise in linear algebra:

THOUGHTS:

By looking at the determinant, I know that a unique solution occurs when $$c \neq 2$$ or $$-3$$ since a square matrix is singular if and only if its determinant is $$0$$ (see this article). How can I really find what this solution is concretely?

Hint: The system has a unique solution if you can invert the matrix $$\begin{bmatrix} 1&1&-1\\ 1&c&3\\ 2&3&c \end{bmatrix}$$ And the solution is $$\begin{bmatrix} X_1\\X_2\\X_3 \end{bmatrix} = \begin{bmatrix} 1&1&-1\\ 1&c&3\\ 2&3&c \end{bmatrix}^{-1} \begin{bmatrix} 1\\2\\3 \end{bmatrix}$$

• yes if the determinant is nonzero ..... but my question is can I find this unique solution concretely? Nov 2, 2019 at 22:52
• yes, of course, by inverting the matrix Nov 2, 2019 at 22:53
• but there are $c's$ in the matrix Nov 2, 2019 at 22:54
• Yes, and there will be c's in the inverse matrix as well. Just find the inverse treating the c's as variables Nov 2, 2019 at 22:56
• got it :) thanks! Nov 2, 2019 at 22:58

If, in your system, you subtract the first line from the second one and twice the first line from the third line, you get$$\left\{\begin{array}{l}X_1+X_2-X_3=1\\(c-1)X_2+4X_3=1\\X_2+(c+2)X_3=1.\end{array}\right.$$Now, if you subtract the third line times $$c-1$$ from the second one, you get$$\left\{\begin{array}{l}X_1+X_2-X_3=1\\(-c^2-c+6)X_3=-c+2\\X_2+(c+2)X_3=1.\end{array}\right.$$Can you take it from here?

• I will try to see if I can Nov 2, 2019 at 23:06
• The next step is to deduce that$$X_3=\frac{-c+2}{-c^2-c+6}.$$ Nov 2, 2019 at 23:47

To obtain in practice the solutions when they exist, you can start from the augmented matrix and use row operations until the submatrix corresponding to the l.h.s. is the unit matrix. The vector of solutions is then the last column.

Here is how it goes, if my computations are correct: \begin{align} \left[\begin{array}{ccc|c} 1&1&-1&1\\1&c&3&2\\2&3&c&3 \end{array}\right]&\rightsquigarrow \left[\begin{array}{ccc|c} 1&1&-1&1\\0&c-1&4&1\\0&1&c+2&1 \end{array}\right]\rightsquigarrow \left[\begin{array}{ccc|c} 1&1&-1&1\\0&1&c+2&1\\0&c-1&4&1 \end{array}\right]\rightsquigarrow \\[1ex] \left[\begin{array}{ccc|c} 1&1&-1&1\\0&1&c+2&1\\0&c-1&4&1 \end{array}\right]&\rightsquigarrow \left[\begin{array}{ccc|c} 1&1&-1&1\\0&1&c+2&1\\0&0&\substack{6-c-c^2\\=-(c-2)(c+3)}&2-c \end{array}\right]\rightsquigarrow \left[\begin{array}{ccc|c} 1&1&-1&1\\0&1&c+2&1\\0&0&1&\frac1{c+3} \end{array}\right]\rightsquigarrow \\[1ex] \text{(we suppose here }c\ne2,-3)\\[1ex]\left[\begin{array}{ccc|c} 1&1&0&\frac{c+4}{c+3}\\0&1&0&\frac1{c+3}\\0&0&1&\frac1{c+3} \end{array}\right]&\rightsquigarrow\left[\begin{array}{ccc|c} 1&0&0&1\\0&1&0&\frac{1}{c+3}\\0&0&1&\frac1{c+3} \end{array}\right]. \end{align}

• I think the solution should be $X_2=X_3=\frac1{c+3}$ and $X_1=1$.
– user
Nov 3, 2019 at 0:21
• Possibly. I did not guarantee the final result and it's a bit too late here to check. Did you check your result in the equations? Nov 3, 2019 at 0:23
• Yes I've checked my derivation twice! I can't find any mistake but I await for your cofirmation too. Bye
– user
Nov 3, 2019 at 0:24
• I'll check that tomorrow morning. For me, the important point was to illustrate the algorithm – without errors if possible. Nov 3, 2019 at 0:27
• @Jack: I've just voted to reopen the post too. Nov 29, 2019 at 13:32

We can proceed by elimination for the augmented matrix

$$\begin{bmatrix} 1&1&-1&1\\ 1&c&3&2\\ 2&3&c&3 \end{bmatrix} \to \begin{bmatrix} 1&1&-1&1\\ 0&c-1&4&1\\ 0&1&c+2&1 \end{bmatrix}\to \begin{bmatrix} 1&1&-1&1\\ 0&c-1&4&1\\ 0&0&(c+2)(c-1)-4&c-2 \end{bmatrix}$$

$$\to \begin{bmatrix} 1&1&-1&1\\ 0&c-1&4&1\\ 0&1&c+2&1 \end{bmatrix}\to \begin{bmatrix} 1&1&-1&1\\ 0&c-1&4&1\\ 0&0&(c-2)(c+3)&c-2 \end{bmatrix}$$

and obtain all from that.

Notably form the third row we obtain that the system is consistent for $$x\neq 2$$ and $$x\neq -3$$ therefore we obtain

$$\to \begin{bmatrix} 1&1&-1&1\\ 0&c-1&4&1\\ 0&0&c+3&1 \end{bmatrix}$$

and we obtain

• from the third row $$X_3=\frac 1{c+3}$$
• from the second row $$X_2=\frac{1-4X_3}{c-1}=\frac{c+3-4}{(c-1)(c-3)}=\frac 1{c+3}$$
• from the first row $$X_1=1-X_2+X_3=1$$
• how can you obtain all from that ? Nov 2, 2019 at 23:09
• From the third line we need that $(c+2)(c-1)-4=c^2+c-6=(c3)(c-2)\neq 0$ which gives the condition for the existence of the unique solution.
– user
Nov 2, 2019 at 23:11
• this is not my question Nov 2, 2019 at 23:12
• Then once we fix $c$ we can obtain from below $X_3$ then $X_2$ and finally $X_1$.
– user
Nov 2, 2019 at 23:12
• how can you obtain $X_{3}$ could you please show me the details? Nov 2, 2019 at 23:13