‘Ugly’ Simultaneous equations with 4 variables

algebra-precalculuselectromagnetismlinear algebraphysics

I have to solve the following 'Ugly' Simultaneous equations to solve a problem on my textbook of physics. The problem is originally discussed on the thread but, it was unfortunately categorized by some user as homework-like question and deleted. You can find the problem from here.

My question:

Solve the simultaneous equations of (1.1) – (1.4) to get $H_2$ , $H_1$ , $m_0$, and $m_1$. I tried to solve this, but, I'm worried whether my answer is correct.

They have 4 variables, $H_2$ , $H_1$ , $m_0$, and $m_1$. Other terms, such as $H_0$, a, b, $\theta$ , … are the constants. This is not a differential equation. It's an algebraic problem.

The simultaneous equations.

$$-{H}_{2}\sin{\theta}
=-{H}_{1}\sin{\theta}
+\frac{{m}_{1}\sin{\theta}}{4\pi{\mu}_{s}{a}^{3}} \tag{1.1}$$

$${\mu}_{0}{H}_{2}\cos{\theta}={\mu}_{0}{\mu}_{s}{H}_{1}\cos{\theta\ }
+\frac{{\mu_0m}_1\cos{\theta}}{2\pi {a}^{3}}  \tag{1.2}$$

$$-{H}_{1}\sin{\theta}+\frac{{m}_{1}\sin{\theta}}{4\pi{\mu}_{s}{b}^{3}}\ \
=\ -{H}_{0}\sin{\theta}+\frac{{m}_{0}\sin{\theta}}{4\pi\ {b}^{3}}\ \tag{1.3}$$

$${\mu}_{0}{\mu}_{s}{H}_{1}\cos{\theta\ }
+\frac{{\mu}_{0}{m}_{1}\cos{\theta}}{2\pi {b}^{3}}\
={\mu}_{0}{H}_{0}\cos{\theta}\
+\frac{{\mu}_{0}{m}_{0}\cos{\theta}}{2\pi {b}^{3}} \tag{1.4}$$

My textbook has the solution of $H_2$ but no solutions for other valuables: The solution of $H_2$ is:

$${H}_{2}\ =\ \frac{\mu_s}{f\left(a,b\right)}{H}_{0} \tag{1.5}$$

Here, the definition of $f \left(a,b\right)$ is as follows.
$$f\left(a,b\right) := {\mu}_{s}+ \frac{2}{9}({\mu}_{s} -1)^{2}(1- \frac{a^3}{b^3}) \tag{1.6}$$

There is a background of Magnetic shielding, behind this problem. But what we should do is solve simultaneous equations like junior high school students, that's all.
I feel that it looks unnatural from the perspective of dimensional analysis, but I forget about it.

I tried to solve this, but, I'm worried whether my answer is correct:

【My answer】 (Modified after 2020/01/06 JST)
We can erase terms including θ and terms including $\mu_0$ , because both sides of each equation have them as common factor. Then, we get
$$-{H}_{2} = -{H}_{1}+ \frac{{m}_{1}}{4\pi{\mu}_{s}{a}^{3}} \tag{1.1'}$$
$${H}_{2}={\mu}_{s}{H}_{1}+\frac{m_1}{2\pi a^3} \tag{1.2'}$$
$$-{H}_{1}+\frac{m_1}{4\pi{\mu}_{s}{b}^{3}}\ \
=\ -{H}_{0}+\frac{{m}_{0}}{4\pi\ {b}^{3}}\ \ \tag{1.3'}$$

$${\mu}_{s}{H}_{1}+\frac{m_1}{2\pi b^3}\
={H}_{0}\ +\frac{m_0}{2\pi b^3} . \tag{1.4'}$$

Move variable to left side:
$${H}_{1} – {H}_{2} – \frac{m_1}{4\pi{\mu}_{s}{a}^{3}}=\ 0 \tag{1.1''}$$
$$\mu_sH_1-H_2+\frac{m_1}{2\pi a^3}\ =\ 0  \tag{1.2''}$$
$${H}_{1}+\frac{m_0}{4\pi\ b^3} – \frac{m_1}{4\pi{\mu}_{s} {b}^{3}}\ \ =\ {H}_{0}\ \ \tag{1.3''}$$
$${\mu}_{s}{H}_{1}\ -\ \frac{m_0}{2\pi {b}^{3}}+\frac{{m}_{1}}{2\pi {b}^{3}}\ ={H}_{0}\ \tag{1.4''}$$

From (1.1') and (1.3') we get
$$2{H}_{2}\ + \ \frac{m_0}{2\pi\ {b}^{3}}
+ \frac{1}{2\pi{\mu}_{s}}\left(\frac{1}{a^3}
– \frac{1}{b^3}\ \right){m}_{1} =\ 2{H}_{0}\ \ \tag{2-1}$$

via
$${H}_{1}
+\frac{m_0}{4\pi\ b^3}
-\frac{m_1}{4\pi\mu_sb^3}\ \
-\ \left({H}_{1}\ -{H}_{2}\
-\ \frac{m_1}{4\pi\mu_sa^3}\right)
=\ {H_0} $$

$${H_2}
+\ \frac{m_0}{4\pi\ b^3}\
+\ {m}_{1}\left(\frac{1}{4\pi{\mu}_{s}{a}^{3}}\
-\ \frac{1}{4\pi{\mu}_{s}{b}^{3}}\ \right)
=\ {H}_{0}\ \ .$$

From (1.2') and (1.4') we get
$${H}_{2}\
-\ \frac{m_0}{2\pi {b}^{3}}\
-\ \frac{{\mu}_{s}}{2\pi{\mu}_{s}}\left(\frac{1}{a^3}\ -\frac{1}{b^3}\right){m}_{1}\ ={H}_{0}\  \tag{2-2}$$

via
$${\mu}_{s}{H}_{1}\
-\ \frac{m_0}{2\pi {b}^{3}}
+\frac{m_1}{2\pi {b}^{3}}
-\ \left({\mu}_{s}{H}_{1}-{H}_{2}
+\frac{{m}_{1}}{2\pi {a}^{3}}\ \right)\
={H}_{0}\ $$

To simplify (2-1) and (2-2), we define constants $P$, $Q$ as follows.
$$P∶=\frac{1}{2\pi\ {b}^{3}}$$
$$Q∶= \frac{1}{2\pi{\mu}_{s}}\left(\frac{1}{a^3}-\frac{1}{b^3}\ \right)$$

Then, the (2-1), (2-2) are denoted as follows.
$$2{H}_{2}\ +\ P{m}_{0}\ +\ Q{m}_{1}=\ 2{H}_{0}\ \tag{2-1'}$$
$${H}_{2}\ -\ P{m}_{0}\ -\ {\mu}_{s}Q{m}_{1}\ ={H}_{0}\ \tag{2-2'}$$

Delete $m_0$ by (2-1') + (2-2') , we get
$$3{H}_{2}\ +\ Q(1- {\mu}_{s}){m}_{1}=\ 3{H}_{0}\ \ \tag{2-3}$$

On the other hand, Multiply $-\mu_s$ on both sides of (1.1'') ,
$$-{\mu}_{s}{H}_{1}\ + {\mu}_{s}{H}_{2}\ + \frac{m_1}{4\pi {a}^{3}}=\ 0$$
and, add above equation and (1-2''),
$$-{\mu}_{s}{H}_{1}\
+{\mu_s}{H}_{2}\
+\ \frac{m_1}{4\pi a^3}\
+\ \left({\mu}_{s}{H}_{1} -{H}_{2}
+ \frac{m_1}{2\pi a^3}\right)=\ 0$$

we get
$${m}_{1}=\ \frac{4\pi a^3}{3}\ (1-{\mu}_{s}){H}_{2}\ \ \tag{2-4}$$
via
$$(1-{\mu}_{s}){H}_{2} +\ \frac{3m_1}{4\pi a^3}\ =\ 0 .$$

Substitute (2-4) for the $m_1$ of (2-3) we get

$${H}_{2} = \frac{{\mu}_{s}{H}_{0}}{f\left(a,b\right)} \tag{2-5}$$

via
$$3{H}_{2}\ + \ Q(1-\ \mu_s\ )\ \frac{4\pi a^3}{3}(1 – {\mu}_{s}){H}_{2}=3{H}_{0}$$
$${H}_{2}+\frac{4\pi a^3}{9}Q\left(\mathbf{1}-\mu_s\right)^2{H}_{2}={H}_{0}$$
$${H}_{2}+\frac{4\pi a^3}{9}\frac{1}{2\pi{\mu}_{s}}\left(\frac{1}{a^3}-\frac{1}{b^3}\ \right){\left(1-{\mu}_{s}\right)}^{2}{H}_{2}
={H}_{0}$$

$${H}_{2}+\frac{2}{9}\frac{1}{\mu_s}\left(1-\frac{a^3}{b^3}\ \right){\left(1-{\mu}_{s}\right)}^{2}{H}_{2}={H}_{0}$$
$${\mu}_{s}{H}_{2}
+\frac{2}{9}\left(1-\frac{a^3}{b^3}\ \right)\left(1-{\mu}_{s}\right)^{2}{H}_{2}={\mu}_{s}{H}_{0} $$

$$f\left(a,b\right){H}_{2}={\mu}_{s}{H}_{0}$$
See the (1-6) for the definition of $f$.

Substitute (2-5) for the ${H}_{2}$ of (2-4) we get

$${m}_{1} = \frac{4\pi a^3}{3\ f\left(a,b\right)}\ (1-{\mu}_{s}){\mu}_{s}{H}_{0} \tag{2-6}$$

Substitute (2-5) and (2-6) for ${H}_{2}$ and $m_1$ of (1.1'') we get

$${H}_{1}=\left(\frac{2{\mu}_{s} +1}{3f\left(a,b\right)}\right)\ {H}_{0} \tag{2-7}$$

via
$${H}_{1} ={H}_{2} + \frac{m_1}{4\pi{\mu}_{s}{a}^{3}}$$
$${H}_{1} =\frac{\mu_s}{f\left(a,b\right)}{H}_{0}
+\frac{1}{4\pi{\mu}_{s}{a}^{3}}\frac{4\pi a^3}{3\ f\left(a,b\right)}\ (1-{\mu}_{s}){\mu}_{s}{H}_{0}$$
 
$${H}_{1}=\frac{\mu_s}{f\left(a,b\right)}{H_0}\ +\frac{1}{3\ f\left(a,b\right)}\ (1-{\mu}_{s}){H}_{0}$$
$${H}_{1}=\left(\frac{3{\mu}_{s}}{3f\left(a,b\right)}\
+\frac{1}{3\ f\left(a,b\right)}(1-{\mu}_{s}) \right){H}_{0}$$
 

Then, the (2-1), (2-2) are denoted as follows.
$$2{H_2} + P{m_0} + Q{m_1} =2{H_0} \tag{2-1'}$$
$${H_2} – P{m_0} – {mu_s}Q{m_1} ={H_0} \tag{2-2'}$$

Delete {m_1} by " $\mu_s$・(2-1') +(2-2') "then we get

$${m}_{0} = \frac{4\pi}{9\ f\left(a,b\right)}(2{\mu}_{s} +1)({\mu}_{s}-1)\left({b^3}-{a^3}\ \right)\ {H_0} \tag{2-8}$$

via
$$2{\mu_s}{H_2} + P{\mu_s}{m_0} + Q{\mu_s}{m_1} =2{\mu_s}{H_0} $$
$${H_2} – P{m_0} – {\mu_s}Q{m_1} ={H_0} $$

$$2{\mu_s}{H_2} + P{\mu_s}{m_0} + Q{\mu_s}{m_1}+
({H_2} – P{m_0} – {\mu_s}Q{m_1})=(2{\mu_s}+1){H_0} $$

$$(2{\mu_s}+1){H_2} + P({\mu_s}-1){m_0} =(2{\mu_s}+1){H_0} $$
$$ P({\mu_s}-1){m_0} =(2{\mu_s}+1)({H_0}-{H_2} ) $$
$$ P({\mu_s}-1){m_0} =(2{\mu_s}+1)({H_0}- \frac{{\mu}_{s}{H}_{0}}{f\left(a,b\right)}) $$
$$ P({\mu_s}-1){m_0} ={H_0} (2{\mu_s}+1)(1 – \frac{{\mu}_{s}}{f\left(a,b\right)}) $$

Here,
$$(1 – \frac{{\mu}_{s}}{f\left(a,b\right)})
=(\frac{f\left(a,b\right)}{f\left(a,b\right)}
– \frac{{\mu}_{s}}{f\left(a,b\right)}) $$

$$=\frac{ f\left(a,b\right)-{\mu}_{s}}{f\left(a,b\right)} $$
$$=\frac{1}{f\left(a,b\right)}(f\left(a,b\right)-{\mu}_{s})$$
$$=\frac{1}{f\left(a,b\right)}(\frac{2}{9}({\mu}_{s} -1)^{2}(1- \frac{a^3}{b^3}))$$
$$=\frac{2}{9f\left(a,b\right)}( ({\mu}_{s} -1)^{2}(1- \frac{a^3}{b^3})) $$

Therefore
$$ P({mu_s}-1){m_0}
= \frac{2}{9f\left(a,b\right)}((2{mu_s}+1)({\mu}_{s} -1)^{2}(1- \frac{a^3}{b^3})){H_0} $$

$$ \frac{1}{2\pi\ {b}^{3}} ({mu_s}-1){m_0}
= \frac{2}{9f\left(a,b\right)}((2{mu_s}+1)({\mu}_{s} -1)^{2}(1- \frac{a^3}{b^3})){H_0} $$

$$ {m_0} = \frac{4\pi\ {b}^{3}}{9f\left(a,b\right)}((2{mu_s}+1)({\mu}_{s} -1)(1- \frac{a^3}{b^3})){H_0} $$

P.S.
I'm not very good at English, so I'm sorry if I have some impolite or unclear expressions. English review is also welcomed. You can download all related files from here.

【Post hoc notes】
(1) Another way to get $H_1$. (Modified after 2020/01/06, JST)

Adding (1.1') and (1.2') we get
$${m_1}=\frac{4\pi {a^3}{\mu_s}}{\left(2{\mu}_{s}+1 \right)}
\left(1-{\mu_s}\right){H_1} \tag{3-1}$$

via
$${H_1}-{H_2}-\frac{m_1}{4\pi{\mu_s}{a^3}}\
-\left({\mu_s}{H_1}-{H_2}+\frac{m_1}{2\pi {a^3}}\right)=\ 0$$

$${H_1}-\frac{m_1}{4\pi{\mu_s}{a^3}}\
-\ \left({\mu_s}{H_1}+\frac{m_1}{2\pi {a^3}}\right)=\ 0$$

$$\left(1-{\mu_s}\right){H_1}-\left(\frac{m_1}{2\pi {a^3}}
+\frac{m_1}{4\pi{\mu_s}{a^3}}\right)=\ 0$$

$$\left(1-{\mu_s}\right){H_1}
-\frac{m_1}{2\pi {a^3}}\left(1+\frac{1}{{2\mu}_s}\right)=\ 0$$

$${2\mu}_{s}\left(1-{\mu_s}\right){H_1}
-\frac{m_1}{2\pi {a^3}}\left({2\mu}_{s}+1\right)=\ 0$$

$$4\pi {a^3}{\mu}_{s}\left(1-\mu_s\right){H_1}-{m_1}\left({2\mu}_s+1\right)=\ 0$$
$${m_1}\left(2{\mu}_{s}+1\right)= 4\pi {a^3}{\mu}_{s}\left(1-{\mu_s}\right){H_1}$$

Subtracting (1.4') from 2 times (1.3'), we get
$${\mu_s}\left(\mu_s+2\right){H_1}\
-\frac{m_1}{2\pi {b^3}}\left(1-{\mu_s}\right)=3{\mu_s}{H_0} \tag{3-2} $$

via
$${\mu_s}{H_1}\ -\ \frac{m_0}{2\pi {b^3}}+\frac{m_1}{2\pi {b^3}}\
+\ 2\left({H_1}+\frac{m_0}{4\pi {b^3}}-\frac{m_1}{4\pi\mu_s{b^3}}\right)={H_0}\ +\ 2{H_0}$$

$${\mu_s}{H_1}\ -\ \frac{m_0}{2\pi {b^3}}
+\frac{m_1}{2\pi {b^3}}\
+\ \left({2H}_{1}+\frac{m_0}{2\pi {b^3}}
-\frac{m_1}{2\pi{\mu_s}{b^3}}\right)=3{H_0}$$

$${\mu_s}{H_1}\ +\frac{m_1}{2\pi b^3}\
+\ \left(2{H}_{1}-\frac{m_1}{2\pi{\mu_s}{b^3}}\right)=3{H_0}$$

$$\left({\mu_s}+2\right){H_1} +
\left(\frac{m_1}{2\pi {b^3}}
-\frac{m_1}{2\pi{\mu_s}{b^3}}\right)=3{H_0}$$

$$\left({\mu_s}+2\right){H_1}\ +\ \frac{m_1}{2\pi {b^3}}\left(1-\frac{1}{\mu_s}\right)=3{H_0}$$

Erase $m_{1}$ from (3-2) using (3-1), we get

$${H_1}=\frac{3\left({2\mu}_{s}+1\right){b^3}{H_0}}{\left({b^3}\left({\mu_s}+2\right)\left({2\mu}_{s}+1\right)\ -\ 2{{a^3}\left(1-{\mu_s}\right)}^{2}\right)} \tag{3-3}$$

via
$$\left({\mu_s}+2\right){H_1}
– \ \frac{a^3}{b^3}\left(1-{\mu_s}\right)^{2}
\frac{2}{\left({2\mu}_{s}+1\right)}{H_1}=3{H_0} $$

$$\left({\mu_s}+2\right)\left({2\mu}_{s}+1\right){H_1}\
-\ \ 2\frac{a^3}{b^3}\left(1-{\mu_s}\right)^{2}{H_1}
=3{H_0}\left({2\mu}_{s}+1\right)$$

$$\left({b^3}\left({\mu_s}+2\right)\left(2{\mu}_{s}+1\right)\
-\ \ 2{{a^3}\left(1-{\mu_s}\right)}^{2}\right){H_1}
=3{H_0}{b^3}\left({2\mu}_{s}+1\right)$$

Further, Dividing the denominator and numerator by $b^3$ we get
$${H_1}=\frac{3\left({2\mu}_{s}+1\right){1}{H_0}}{\left(\left({\mu_s}+2\right)\left({2\mu}_{s}+1\right)\ -\ 2{\frac{a^3}{b^3}\left(1-{\mu_s}\right)}^{2}\right)} \tag{3-3'}$$

The denominator of Equation (3-3') is

$$\left(\left({\mu_s}+2\right) \left({2\mu}_{s}+1\right)
– 2\frac{a^3}{b^3}\left(1-{\mu_s}\right)^{2}\right)$$

$$= 2(1-{\mu_s})^{2} + 9{\mu}_{s}
– 2\frac{a^3}{b^3}\left(1-{\mu_s}\right)^{2} $$

$$=2(1- \frac{a^3}{b^3})(1-{\mu_s})^{2} + 9{\mu}_{s} =9f(a,b) $$

Here,
$$\left({\mu_s}+2\right)\left(2{\mu}_{s}+1\right) $$
$$={2\mu}_{s}^{2} +5{\mu}_{s} + 2$$
$$={2\mu}_{s}^{2} -4{\mu}_{s} + 2 + 9{\mu}_{s} $$
$$=2(1-{\mu_s})^{2} + 9{\mu}_{s}$$
Therefore, we get
$${H}_{1}=\left(\frac{2{\mu}_{s} +1}{3f\left(a,b\right)}\right)\ {H}_{0} \tag{3-3''}$$

That is same as (2-7)'s ${H}_{1}$.

(2)Description of my textbook. (Added on 2020/01/01 JST)
My text book (Written in Japanese) has following description.
The equation are excerpt from the textbook and I add the equation number
to indicate to which formula in this thread corresponds. (See Fig. 1. Equation numbers in following Fig 1 represents corresponding equation number in this thread.)

enter image description here
Fig.1

Comparing my textbook with this thread,
it seem that I correctly quote equations (1-1) through (1-4) and my calculation of ${H}_{2}$ (See 2-5) might be correct.
In my textbook, neither the calculation process nor the answer of other H or m is written, so I do not know about other H and m.

Best Answer

There is a method called $\bf{Cramer’s\space Rule}$, [the rule is described here $\space \rm\color{skyblue}{and} \space$ here] which can be used to solve nonhomogeneous systems of linear simultaneous equations of any size. This method is particularly ideal for your case, because of its straightforwardness. We are not belittling the method you used, but it is prone to propagation of errors. In your method, if you use the erroneous value of an unknown, which you have already determined, to calculate some other unknowns, the error of the former unknown is unwittingly passed on to the latter unknowns. Cramer’s rule does not have this disadvantage, because every unknown is calculated independently. Besides, the method you used can be carried out in many different ways – you yourself have presented two different schemes. If you get different sets of answers, there is no way to tell which set has the correct answers. Comparing the steps of different schemes hoping to find an error is also impossible, because steps are different from scheme to scheme. Unlike the steps of your method, the recipe of the Cramer’s rule is the same for all who use it.

The following solution to your question is worked out using Cramer’s rule. We refrain from giving the intermediate calculations, which consist of computing determinants. First we put the system into matrix form.

System of Equations

Determinant of Matrix A

According to Cramer’s rule, we can write down the solution straight away.

Value of H1

Value of H2

Value of m0

Value of m1

where $f\left(a,b\right) = \mu_s +\frac{2}{9}\left(1-\frac{a^3}{b^3}\right)\left(\mu_s-1\right)^2$

Now, if you closely examine the values given above for the four unknowns, you will find that one of them is different from the value you obtained for the same unknown. If you substitute your values into either the equation (1.3) or (1.4), they will not satisfy them. We leave it to you to find your error.

Related Question