Re: Re[2]: cannot solve *trivial* equation
- To: mathgroup at smc.vnet.net
- Subject: [mg34415] Re: Re[2]: [mg34380] cannot solve *trivial* equation
- From: Andrzej Kozlowski <andrzej at platon.c.u-tokyo.ac.jp>
- Date: Sun, 19 May 2002 04:14:27 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
On Friday, May 17, 2002, at 09:49 PM, Marco Manfredini wrote: > > I [=Mathematica newbie] did not understand that Mathematica can solve > for A {A->3*S} but > not for S ({} while I expected S->A/3). I had the idea that solving > for X means to find an equation X==Y (with Y X-free) which can be > added to the set of equations without restrictions. > Note that your two examples are interpreted differently by Mathematica. In the first case: Solve[{A == S + Q, Q == 2*S}, A] Q == 2*S is a relation between the parameters (not variables) which mathematica takes as assumption. But in the second case: Solve[{A == S + Q, Q == 2*S}, S] there is now assumption made about the parameters. So of course if you add to the equations one more condition: In[8]:= Solve[{A == S + Q, Q == 2*S, 2*A == 3*Q}, S] Out[8]= {{S -> Q/2}} You get the answer you were expecting. In fact, if you prefer to get the answer it in terms of A you should use: In[11]:= Solve[{A == S + Q, Q == 2*S, 2*A == 3*Q}, S, {Q}] Out[11]= {{S -> A/3}} Andrzej