1
$\begingroup$

I need an example of 5 linearly independent equations with 5 variables. How can I write such a equation set. As an example:

                      0   0    0    0   1   |   -4                       0   0    1   -1   0   |    3                       1   0    0    0   1   |    2                       0   7   -8    0   0   |  -14                       2   0    0    0   0   |    2 

But this is wrong. I need to build a correct one.

  • 0
    I don't get it. What's wrong with the above system?2012-12-10
  • 0
    @user1551 - row 1 + 0.5 row 5 =row 32012-12-10
  • 0
    @Belgi Oh I see. The OP wants a full rank coefficient matrix. Thanks.2012-12-10

3 Answers 3

2

You can choose any $\hat{x}_{1} , \ldots , \hat{x}_{5}$, and use the system $$ \begin{bmatrix} 1 & 0 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x_{1} \\ x_{2} \\ x_{3} \\ x_{4} \\ x_{5} \end{bmatrix} = \begin{bmatrix} \hat{x}_{1} \\ \hat{x}_{2} \\ \hat{x}_{3} \\ \hat{x}_{4} \\ \hat{x}_{5} \\ \end{bmatrix}. $$ If you want something that is less obvious, you can start multiplying the rows by nonzero constants: $$ \begin{bmatrix} 2 & 0 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x_{1} \\ x_{2} \\ x_{3} \\ x_{4} \\ x_{5} \end{bmatrix} = \begin{bmatrix} 2 \hat{x}_{1} \\ \hat{x}_{2} \\ \hat{x}_{3} \\ \hat{x}_{4} \\ \hat{x}_{5} \\ \end{bmatrix} $$ (in this example, we multiply the first row by $2$), or adding multiples of one row to another row: $$ \begin{bmatrix} 2 & 0 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 \\ 0 & 0 & 1 & 0 & -3 \\ 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 1 \end{bmatrix} \begin{bmatrix} x_{1} \\ x_{2} \\ x_{3} \\ x_{4} \\ x_{5} \end{bmatrix} = \begin{bmatrix} 2 \hat{x}_{1} \\ \hat{x}_{2} \\ \hat{x}_{3} - 3 \hat{x}_{5} \\ \hat{x}_{4} \\ \hat{x}_{5} \\ \end{bmatrix} $$ (in this example, we add $-3$ times the fifth row to the third row).

  • 0
    This steps will not create linearly dependent equations, right? Because I want all equations to be linearly independent. Sorry for asking too much.2012-12-10
  • 0
    Suppose we use the steps above to generate a system. Then, we can solve the system using Gaussian elimination. But this is just doing the steps above in reverse! Therefore, the equations remain linearly independent.2012-12-10
1

Begin with a 5x5 random matrix, with positive diagonal. For example, $$ A=\begin{pmatrix} 1&0&-3&2&4\\ 5&6&7&8&-9\\ 1&1&1&1&1\\ 0&0&0&1&0\\ 2&-3&2&-3&4 \end{pmatrix} $$ Then compute the absolute row sums (i.e. sum up the absolute values of the entries in each row): \begin{align} 1+0+3+2+4=10\\ 5+6+7+8+9=35\\ 1+1+1+1+1=5\\ 0+0+0+1+0=1\\ 2+3+2+3+4=14. \end{align} Add these row sums to the diagonal of $A$: $$ A=\begin{pmatrix} 1+10&0&-3&2&4\\ 5&6+35&7&8&-9\\ 1&1&1+5&1&1\\ 0&0&0&1+1&0\\ 2&-3&2&-3&4+14 \end{pmatrix}. $$ The rows of $A$ are then linearly independent. If you want to make $A$ looks more random, further scramble the rows or columns of $A$. Then form a random but nice looking solution vector $x$ (so that you may control the look of the solution). Compute $b=Ax$ and let the coefficients of $b$ be the numbers on the RHS of the equations. The resulting system will always have a unique solution, which is your nice $x$.

  • 0
    Why does this work ?2012-12-10
  • 1
    @Belgi Because $A$ will then be strictly diagonally dominant. Hence by Gershgorin disc theorem, $0$ can never be an eigenvalue of $A$.2012-12-10
0

Write in matrix form this system: $x_1=1,...,x_5=5$

  • 0
    ... or if you want something slightly less trivial, take an upper triangular system with nonzero diagonal elements.2012-12-10
  • 0
    Although technically correct, I hesitate to call these "unknowns."2012-12-10
  • 0
    @NicolásKim - you can always mess it up with elementary row operations. I saw no need to make it complicated, I would of written this on an exam since clearly $I$ is invertible so this saves some work in arguing why the example is good2012-12-10
  • 0
    @RobertIsrael - thats true, but the OP may not understand why does this work at this stage...2012-12-10
  • 0
    this has no solution, I am looking for one with a unique solution2012-12-10
  • 0
    @Ersin - Why no solution ?2012-12-10
  • 0
    @Belgi , maybe I have lack of info about this subject. But can you please identify the solution of this. I found from eq1 that x5=-4. from eq3, x1=6 but from eq5, x1=1. What am I missing?2012-12-10
  • 0
    @Ersin - from eq 1 $x_1=1$, from the second: $x_2=2$,...from the fifth $x_5=5$2012-12-10
  • 0
    First eq : x5=-4 Second eq: x3-x4=3 Third eq: x1+x5=2 and go on. Right?2012-12-10
  • 1
    @NicolásKim it is better to call them as variables i think.2012-12-10