Verifying the correctness of the vector solution for linear equation in three variables
In one of the earlier blogs it was shown that the solution of linear equations could be written entirely in vector form
In this blog I will verify the vector form of solution with the determinant form. Linear equation problem is given below
$$ a_1x+a_2y+a_3z=d_1\\ b_1x+b_2y+b_3z=d_2\\ c_1x+c_2y+c_3z=d_3\\ $$ Given below is the determinant form of solution. $$ x = \frac{\left| \begin{array}{ccc} d_1 & a_2 & a_3 \\ d_2 & b_2 & b_3 \\ d_3 & c_2 & c_3\end{array} \right|}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|} \space\space\space = \frac{d_1b_2c_3-d_1b_3c_2-d_2a_2c_3+d_2a_3c_2+d_3a_2b_3-b_3b_2a_3}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|}\\ \space\space\\ y = \frac{\left| \begin{array}{ccc} a_1 & d_1 & a_3 \\ b_2 & d_2 & b_3 \\ c_3 & d_3 & c_3\end{array} \right|}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|} \space\space\space = \frac{d_1b_3c_1-d_1b_1c_3+d_2a_1c_3-a_3c_1d_2+b_1a_3d_3-d_3a_1b_3}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|}\\ \space\space\\ z = \frac{\left| \begin{array}{ccc} a_1 & a_2 & d_1 \\ b_2 & b_2 & d_2 \\ c_3 & c_2 & d_3\end{array} \right|}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|} \space\space\space = \frac{d_1b_1c_2-d_1c_1b_2+d_2a_2c_1-d_2a_1c_2+d_3a_1b_2-d_3b_1a_2}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|}\\ $$ Solving the same using the vector formula provided in earlier blog. Vector form of the above linear equations is given below. $$\overrightarrow{A}.\overrightarrow{r} = d_1\\ \overrightarrow{B}.\overrightarrow{r} = d_2\\ \overrightarrow{C}.\overrightarrow{r} = d_3\\ $$
Where
$$ \overrightarrow{A} = a_1\mathbf{i}+a_2\mathbf{j}+a_3\mathbf{k}\\ \overrightarrow{B} = b_1\mathbf{i}+b_2\mathbf{j}+b_3\mathbf{k}\\ \overrightarrow{C} = c_1\mathbf{i}+c_2\mathbf{j}+c_3\mathbf{k}\\ \overrightarrow{r} = x\mathbf{i}+y\mathbf{j}+z\mathbf{k}\\ $$
$.$ is the usual dot product in vectors
$\mathbf{i},\mathbf{j},\mathbf{k}$ are unit vectors
$$ \overrightarrow{r} = \frac{(\overrightarrow{B}\times\overrightarrow{C}d_1+\overrightarrow{C}\times\overrightarrow{A}d_2+\overrightarrow{A}\times\overrightarrow{B}d_3)}{\overrightarrow{A}\times\overrightarrow{B}.\overrightarrow{C}} $$ The denominator in the above equation is the volume of the parallelopipe. Which can be written in determinant form as below. The cross and dot product also solves to the same expression. $$ D = {\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}\\ $$ All we need to do is show that the numerator is equal to the numerator of the determinant form. $$ \space\\ \overrightarrow{B}\times\overrightarrow{C}d_1 = {\left| \begin{array}{ccc} i & j & k \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}d_1\space =\space i(b_2c_3-c_2b_3)d_1+j(c_1b_3-b_1c_3)d_1+k(b_1c_2-c_1b_2)d_1\\ \space\\ \overrightarrow{C}\times\overrightarrow{A}d_2 = {\left| \begin{array}{ccc} i & j & k \\ c_1 & c_2 & c_3 \\ a_1 & a_2 & a_3\end{array} \right|}d_2\space =\space i(c_2a_3-a_2c_3)d_2+j(a_1c_3-c_1a_3)d_2+k(c_1a_2-a_1c_2)d_2\\ \space\\ \overrightarrow{A}\times\overrightarrow{B}d_3 = {\left| \begin{array}{ccc} i & j & k \\ a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3\end{array} \right|}d_3\space =\space i(a_2b_3-b_2a_3)d_3+j(b_1a_3-a_1b_3)d_3+k(a_1b_2-a_2b_1)d_3\\ \space\\ \space\\ \space\\ \frac{\overrightarrow{B}\times\overrightarrow{C}d_1+\overrightarrow{C}\times\overrightarrow{A}d_2+\overrightarrow{A}\times\overrightarrow{B}d_3}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}\\\\\space\\ =\frac{i(b_2c_3d_1-c_2b_3d_1+c_2a_3d_2-a_2c_3d_2+a_2b_3d_3-b_2a_3d_3)+j(c_1b_3d_1-b_1c_3d_1+a_1c_3d_2-c_1a_3d_2+b_1a_3d_3-a_1b_3d_3)+k(b_1c_2d_1-c_1b_2d_1+c_1a_2d_2-a_1c_2d_2+a_1b_2d_3-a_2b_1d_3)}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}\\ $$ The components of the above vector are same as the solution of x,y,x arrived at by using the determinant method. Hence the two results are verified to be correct.
RP
info@softanalytics.net
In one of the earlier blogs it was shown that the solution of linear equations could be written entirely in vector form
In this blog I will verify the vector form of solution with the determinant form. Linear equation problem is given below
$$ a_1x+a_2y+a_3z=d_1\\ b_1x+b_2y+b_3z=d_2\\ c_1x+c_2y+c_3z=d_3\\ $$ Given below is the determinant form of solution. $$ x = \frac{\left| \begin{array}{ccc} d_1 & a_2 & a_3 \\ d_2 & b_2 & b_3 \\ d_3 & c_2 & c_3\end{array} \right|}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|} \space\space\space = \frac{d_1b_2c_3-d_1b_3c_2-d_2a_2c_3+d_2a_3c_2+d_3a_2b_3-b_3b_2a_3}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|}\\ \space\space\\ y = \frac{\left| \begin{array}{ccc} a_1 & d_1 & a_3 \\ b_2 & d_2 & b_3 \\ c_3 & d_3 & c_3\end{array} \right|}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|} \space\space\space = \frac{d_1b_3c_1-d_1b_1c_3+d_2a_1c_3-a_3c_1d_2+b_1a_3d_3-d_3a_1b_3}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|}\\ \space\space\\ z = \frac{\left| \begin{array}{ccc} a_1 & a_2 & d_1 \\ b_2 & b_2 & d_2 \\ c_3 & c_2 & d_3\end{array} \right|}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|} \space\space\space = \frac{d_1b_1c_2-d_1c_1b_2+d_2a_2c_1-d_2a_1c_2+d_3a_1b_2-d_3b_1a_2}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_2 & b_2 & b_3 \\ c_3 & c_2 & c_3\end{array} \right|}\\ $$ Solving the same using the vector formula provided in earlier blog. Vector form of the above linear equations is given below. $$\overrightarrow{A}.\overrightarrow{r} = d_1\\ \overrightarrow{B}.\overrightarrow{r} = d_2\\ \overrightarrow{C}.\overrightarrow{r} = d_3\\ $$
Where
$$ \overrightarrow{A} = a_1\mathbf{i}+a_2\mathbf{j}+a_3\mathbf{k}\\ \overrightarrow{B} = b_1\mathbf{i}+b_2\mathbf{j}+b_3\mathbf{k}\\ \overrightarrow{C} = c_1\mathbf{i}+c_2\mathbf{j}+c_3\mathbf{k}\\ \overrightarrow{r} = x\mathbf{i}+y\mathbf{j}+z\mathbf{k}\\ $$
$.$ is the usual dot product in vectors
$\mathbf{i},\mathbf{j},\mathbf{k}$ are unit vectors
$$ \overrightarrow{r} = \frac{(\overrightarrow{B}\times\overrightarrow{C}d_1+\overrightarrow{C}\times\overrightarrow{A}d_2+\overrightarrow{A}\times\overrightarrow{B}d_3)}{\overrightarrow{A}\times\overrightarrow{B}.\overrightarrow{C}} $$ The denominator in the above equation is the volume of the parallelopipe. Which can be written in determinant form as below. The cross and dot product also solves to the same expression. $$ D = {\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}\\ $$ All we need to do is show that the numerator is equal to the numerator of the determinant form. $$ \space\\ \overrightarrow{B}\times\overrightarrow{C}d_1 = {\left| \begin{array}{ccc} i & j & k \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}d_1\space =\space i(b_2c_3-c_2b_3)d_1+j(c_1b_3-b_1c_3)d_1+k(b_1c_2-c_1b_2)d_1\\ \space\\ \overrightarrow{C}\times\overrightarrow{A}d_2 = {\left| \begin{array}{ccc} i & j & k \\ c_1 & c_2 & c_3 \\ a_1 & a_2 & a_3\end{array} \right|}d_2\space =\space i(c_2a_3-a_2c_3)d_2+j(a_1c_3-c_1a_3)d_2+k(c_1a_2-a_1c_2)d_2\\ \space\\ \overrightarrow{A}\times\overrightarrow{B}d_3 = {\left| \begin{array}{ccc} i & j & k \\ a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3\end{array} \right|}d_3\space =\space i(a_2b_3-b_2a_3)d_3+j(b_1a_3-a_1b_3)d_3+k(a_1b_2-a_2b_1)d_3\\ \space\\ \space\\ \space\\ \frac{\overrightarrow{B}\times\overrightarrow{C}d_1+\overrightarrow{C}\times\overrightarrow{A}d_2+\overrightarrow{A}\times\overrightarrow{B}d_3}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}\\\\\space\\ =\frac{i(b_2c_3d_1-c_2b_3d_1+c_2a_3d_2-a_2c_3d_2+a_2b_3d_3-b_2a_3d_3)+j(c_1b_3d_1-b_1c_3d_1+a_1c_3d_2-c_1a_3d_2+b_1a_3d_3-a_1b_3d_3)+k(b_1c_2d_1-c_1b_2d_1+c_1a_2d_2-a_1c_2d_2+a_1b_2d_3-a_2b_1d_3)}{\left| \begin{array}{ccc} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3\end{array} \right|}\\ $$ The components of the above vector are same as the solution of x,y,x arrived at by using the determinant method. Hence the two results are verified to be correct.
RP
info@softanalytics.net
This was brilliant!
ReplyDelete