0
$\begingroup$

I am in pickle to figure out a way to input this somewhat odd system of simultaneous equations in Mathematica

The system reads

$$a_1+2 a_2-2 a_3=3 a_2-a_3=-a_6=-a_7=a_2-a_3$$ $$a_1+a_2-a_3-a_6=2 a_2-a_6=4 a_2-2 a_3=-a_6$$ $$a_1+a_2-a_3-a_7=2 a_2-a_7$$

The solution to this peculiar system is $a_2=\frac{1}{4}a_1=\frac{1}{3}a_3$, $a_6=a_7=0$.

Here is my try

Clear[a1, a2, a3, a6, a7];
Eq1=a1+2 a2-2 a3==3 a2-a3
Eq2=a1+2 a2-2 a3==-a6
Eq3=a1+2 a2-2 a3==-a7
Eq4=a1+2 a2-2 a3==a2-a3
Eq5=a1+a2-a3-a6==2 a2-a6
Eq6=a1+a2-a3-a6==4 a2-2 a3
Eq7=a1+a2-a3-a6==-a6
Eq8=a1+a2-a3-a7==2 a2-a7
Solve[{Eq1, Eq2, Eq3, Eq4, Eq5, Eq6, Eq7, Eq8}, {a1, a2, a3, a6,a7}]

gives me a trivial solution.

Is there a way around?

$\endgroup$
  • $\begingroup$ What does {Eq1, Eq2, Eq3, Eq4, Eq5, Eq6, Eq7, Eq8} /. {a1 -> 4 a2, a3 -> 3 a2, a6 -> 0, a7 -> 0} return ? $\endgroup$ – b.gates.you.know.what Oct 2 '16 at 7:54
  • $\begingroup$ Last[CoefficientArrays[List @@ FullSimplify[And @@ {a[1] + 2 a[2] - 2 a[3] == 3 a[2] - a[3] == -a[6] == -a[7] == a[2] - a[3], a[1] + a[2] - a[3] - a[6] == 2 a[2] - a[6] == 4 a[2] - 2 a[3] == -a[6], a[1] + a[2] - a[3] - a[7] == 2 a[2] - a[7]}], {a[1], a[2], a[3], a[6], a[7]}]] yields a nonsingular coefficient matrix (hence, no null space, and only the all-zeros solution is possible). $\endgroup$ – J. M. will be back soon Oct 2 '16 at 8:00
  • $\begingroup$ From your first line: $3a_2-a_3=a_2-a_3$. How should that be true for $a_2\neq 0$? $\endgroup$ – Lukas Oct 2 '16 at 8:28
  • $\begingroup$ Lets take $a_2-a_3=-a_6$ and subtract it from $4 a_2-2 a_3=-a_6$, which gives $a_2=\frac{1}{3}a_3$. Subing this to $a_1-a_2-a_3=0$ gives $a_2=\frac{1}{4} a_1$. By hand I can manage it, looking at the answer. But if we do not know the answer then how we can approach such situations? $\endgroup$ – zhk Oct 2 '16 at 8:55
  • 4
    $\begingroup$ I'm voting to close this question as off-topic because the system has no answer aside from the trivial solution. $\endgroup$ – Feyre Oct 2 '16 at 10:46
4
$\begingroup$

Let's move the rhs of the equations to the lhs:

eqs = (#[[1]] - #[[2]]) & /@ {Eq1, Eq2, Eq3, Eq4, Eq5, Eq6, Eq7, Eq8}

{a1 - a2 - a3, a1 + 2 a2 - 2 a3 + a6, a1 + 2 a2 - 2 a3 + a7, a1 + a2 - a3, a1 - a2 - a3, a1 - 3 a2 + a3 - a6, a1 + a2 - a3, a1 - a2 - a3}

There are indeed five variables:

Variables @ eqs

{a1, a2, a3, a6, a7}

Construct the coefficient matrix:

mat = Part[#, 2] & @ Normal @ CoefficientArrays[#, Variables @ eqs] & /@ eqs;

MatrixForm @ mat

enter image description here

Dimensions @ mat

{8, 5}

There are $M=8$ equations and $N=5$ variables (which is called an overdetermined system), and the system of linear equations is homogeneous. There is a non-trivial solution only if the number of independent equations (i.e., rank of matrix mat) is $\leq N-1=5-1=4$:

MatrixRank @ mat

5

so the trivial solution is the only solution of this system.

$\endgroup$

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