# How to express a variable in terms of other variables in a system of equations?

I want to know how to express $a$ in terms of $x$, $y$ and $z$ in the following system (i.e., I want to find the function $a(x,y,z)$). And how to investigate (and to play with the equations) to know whether a variable can expressed in terms of $x, y, z$ or not in similar situations?

$$\begin{cases} x + 2y -z = 2\\ 2x + 5y -(a+2)z = 3\\ -x + (a+5)y + z = 1 \end{cases}$$

P.S.: I would enjoy the solutions written in Maple or Mathematica format too.

-
I think you may want to express $x,y$ and $z$ in terms of $a$. If you still insist in doing it the other way around, solving the problem like an ordinary linear system in the unknown variables $x,y$ and $z$ is still the way to go. You can always invert the relationships afterward if necessary. – Raskolnikov Mar 24 '11 at 11:56
The try the following link. You'll have to copy the rest of the line into your browser: wolframalpha.com/input/?i=solve+x%2B2y-z%3D2%2C+2x%2B5y−%28a%2B2%29z%‌​3D3%2C+−x%2B%28a%2B5%29y%2Bz%3D1++for+a – lhf Mar 24 '11 at 12:27
Here's @lhf's link in a single clickable version: wolframalpha.com/input/… – t.b. Mar 24 '11 at 12:54
@Theo, thanks. How did you do it? – lhf Mar 24 '11 at 13:01
@lhf: I tweaked the link using percent encoding (I replaced two or three - signs by %2D), see en.wikipedia.org/wiki/Percent-encoding for an explanation. You can test if a link works in an answer field and wherever the link breaks in the preview you need to do something. – t.b. Mar 24 '11 at 13:04

Solving the system for $x$, $y$, and $z$ in terms of $a$ gives equations that relate $a$ to each of $x$, $y$, and $z$, each of which can be solved for $a$ in terms of one of the other variables. (Having three equations and four unknowns, it is most likely that any three of the variables can be expressed in terms of the fourth, or alternately that any one variable can be expressed solely in terms of each of the other three variables.)

Using Mathematica:

Solve[
x + 2 y - z == 2 &&
2 x + 5 y - (a + 2) z == 3 && -x + (a + 5) y + z == 1, {x, y, z}]

(*
==> {{x -> -((-10 - 9 a - 2 a^2)/(a (7 + a))), y -> 3/(7 + a),
z -> -2 + 15/(7 + a) + 10/(a (7 + a)) + (2 a)/(7 + a)}}
*)


So, for example, $y=\frac{3}{7+a}$, which gives $a=\frac{3-7y}{y}$.

-