# Question on solving system of equations with constants...

#### datahead8888

##### New member
It's fairly straight forward to find information on how to solve a system of equations like this:

2x + 3y + 4z = 1
3x + 4y + 3z = 2
4x + 5y + 3z = 3

It has numerical constants in front of each term. You could use Gaussian elimination and solve for one, infinite, or no solutions. (The above example is completely random). It works because you can cancel terms out.

It's a bit less straightforward to find information on how to solve it when you have constants represented by symbols:
ua*x + ub*y + uc*z = 1
va*x + vb*y + vy*z = 2
x + y + z = 3

Here we want to solve for x, y, and z, each expressed in terms of ua/ub/uc/va/vb/vc only. You can't use elimination here because terms such as ua and va will not cancel out. (This example is slightly random too - I just need to learn the technique).

The only method I'm aware of is substitution, though it seems to spill onto multiple pages (the above system is simpler than what I need to solve). Is there any easier way to attack something like this? Any links to online references would be much appreciated.

#### Ackbach

##### Indicium Physicus
Staff member
For a 3 x 3 system such as you have here, Cramer's Rule isn't too bad. Because it's all determinants, though, it gets computationally unwieldy very quickly.

#### datahead8888

##### New member
For a 3 x 3 system such as you have here, Cramer's Rule isn't too bad. Because it's all determinants, though, it gets computationally unwieldy very quickly.
That looks extremely helpful. It probably still requires mangling, but it least it gives a lot of order to the mangling. I especially like how wikipedia already has standard forms posted.

I'll post back if I have issues - thanks a lot!

#### Ackbach

##### Indicium Physicus
Staff member
I'm not so sure elimination doesn't work here. Assuming you meant subscripts $u_{a}$, etc., we have:

\left[ \begin{array}{ccc|c} u_a &u_b &u_c &1 \\ v_a &v_b &v_c &2 \\ 1 &1 &1 &3 \end{array}\right]_{ \begin{align*}R_{1} & \leftrightarrow R_{3} \\ R_3 & \leftrightarrow R_2 \end{align*}} \to
\left[\begin{array}{ccc|c}1 &1 &1 &3 \\ u_a &u_b &u_c &1 \\ v_a &v_b &v_c &2 \end{array}\right]_{ \begin{align*}-u_a R_1+R_2 &\mapsto R_2 \\ -v_a R_1 + R_3 &\mapsto R_3 \end{align*}} \to
$$\left[\begin{array}{ccc|c}1 &1 &1 &3 \\ 0 &u_b-u_a &u_c-u_a &1-3u_a \\ 0 &v_b-v_a &v_c-v_a &2-3v_a \end{array}\right]_{R_2/(u_b-u_a) \mapsto R_2} \to \left[\begin{array}{ccc|c}1 &1 &1 &3 \\ 0 &1 &\frac{u_c-u_a}{u_b-u_a} &\frac{1-3u_a}{u_b-u_a} \\ 0 &v_b-v_a &v_c-v_a &2-3v_a \end{array}\right], \quad \text{for } u_b-u_a\not=0.$$
Continuing on with the row operation $-(v_b-v_a)R_2+R_3 \mapsto R_3$ yields
$$\left[\begin{array}{ccc|c}1 &1 &1 &3 \\ 0 &1 &\frac{u_c-u_a}{u_b-u_a} &\frac{1-3u_a}{u_b-u_a} \\ 0 &0 &\frac{(v_a-v_b)(u_c-u_a)}{u_b-u_a}+v_c-v_a &\frac{(1-3u_a)(v_a-v_b)}{u_b-u_a}+2-3v_a \end{array}\right].$$
Now you can do back substitution to finish.