3

Solve the linear system

$ \begin{array}{ c c c c c c c c c c c c c c } & & x_{2} & + & x_{3} & + & \dotsc & + & x_{n-1} & + & x_{n} & = & 2 & \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ( 1)\\ x_{1} & & & + & x_{3} & + & \dotsc & + & x_{n-1} & + & x_{n} & = & 4 & \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ( 2)\\ x_{1} & + & x_{2} & & & + & \dotsc & + & x_{n-1} & + & x_{n} & = & 6 & \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ( 3)\\ \vdots & & \vdots & & \vdots & & \ddots & & \vdots & & \vdots & & \vdots & \ \ \ \ \ \ \ \ \ \ \ \\ x_{1} & + & x_{2} & + & x_{3} & + & \dotsc & + & x_{n-1} & & & = & 2n & \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ ( n) \end{array} $


Attempt

I am not confident yet with my linear algebra, so I tried approaching this problem by adding all of the equations, which gives us

$ \begin{align*} (n-1)(x_1+x_2+x_3+\ldots+x_{n-1}+x_n)=2+4+6+\ldots+2n \tag*{} \end{align*} $

since $x_i$ ($i \in \mathbb{N}, i \leq n$) always appear in every equation except the $i$-th equation. The right-hand side is the sum of first $n$ positive even number, which can be simplified further as

$ \begin{align*} (n-1)(x_1+x_2+x_3+\ldots+x_{n-1}+x_n) &= n(n+1) \\[.5em] x_1+x_2+x_3+\ldots+x_{n-1}+x_n &= \dfrac{n(n+1)}{n-1} \tag*{} \end{align*} $

Subtracting respectively Eq. (1), Eq. (2), up to Eq. (n) from Eq. (A), gives us

$ \begin{align*} x_1 &= \dfrac{n(n+1)}{n-1} - 2 = \dfrac{n(n+1) - 2(n-1)}{n-1} = \dfrac{n^2 - n + 2}{n-1} \tag*{}\\ x_2 &= \dfrac{n(n+1)}{n-1} - 4 = \dfrac{n(n+1) - 4(n-1)}{n-1} = \dfrac{n^2 - 3n + 4}{n-1} \\ \vdots \\ x_n &= \dfrac{n(n+1)}{n-1} - 2n = \dfrac{n(n+1) - 2n(n-1)}{n-1} = \dfrac{3n-n^2}{n-1} \end{align*} $
However, I'm rather concerned with the denominator ($n-1$) which causes division by zero when $n = 1$. Did I do a mistake, or maybe did I misunderstand something in the process? And what would be the correct approach to this problem? Thanks.

Note: I found the problem here.

ZNayaka
  • 33
  • 2
    then just do the work separately when $n = 1. $ Is there even a work to do in that case? – dezdichado Jan 10 '23 at 16:00
  • 1
    If $n=1$ then there is one equation in the linear system. That equation would be $0=2$. (recall that an empty sum is equal to zero). – JMoravitz Jan 10 '23 at 16:01
  • 1
    If you let $\mathbf{1}$ denote the matrix of all ones, your system looks like $\mathbf{1} - \mathbb{I} = \vec{b}$, so I don't think the problem is defined for $n=1$ as the only equation reads $0=0$ – gt6989b Jan 10 '23 at 16:25
  • 1
    Good news at your link from $2010$: "I will make solutions to these problems available later if there are students working with them." Now $13$ years later the students certainly have finished and the solutions can be obtained there. – Dietrich Burde Jan 10 '23 at 17:00
  • @dezdichado `@JMoravitz,@gt6989 thanks for the feedback. I think now I get it :D – ZNayaka Jan 10 '23 at 18:44
  • @DietrichBurde Unfortunately, I couldn't find any of the solution after browsing through their website. I guess I have to figure it out myself. ;( – ZNayaka Jan 10 '23 at 18:46

2 Answers2

3

Let $A_n\in M_n(K)$ be the matrix with $0$ on the diagonal and entry $1$ everywhere else. Then $\det(A)\neq 0$ for $n\ge 2$. In fact, there is an easy formula for the determinant on this site, namely $\det(A)=(-1)^{n-1}\cdot (n-1)$, see here:

Determinant of a matrix with diagonal entries $a$ and off-diagonal entries $b$

The system then is given by $Ax=b$ with $b=(2,4,\ldots ,2n)^T$. The unique solution is given by $$ x=A^{-1}b, $$ because $Ax=b$ gives $x=A^{-1}Ax=A^{-1}b$. One can also find an explicit formula for the inverse of $A$, and thus obtain an explicit solution (which you can also derive directly from the equations).

Dietrich Burde
  • 130,978
1

When $n=1$, you have just a single equation, but the left side is an empty sum ($0$) and the right side is $2$. Thus for $n=1$ your system devolves to a contradiction, and with that you should expect the division to break down.

Oscar Lanzi
  • 39,403