Unexpected bahaviour



Hello David,
thank you answering my question.
Now I changend the code, using a variable:


(%i2) eq10: w1-w2=-a*(p-d-m)^2+a*(p-m)^2;



(%i3) eq11: w3-w2=-s*(p+d-m)^2+s*(p-m)^2;


(%i4) q: solve(eq10,[a]);


(%i5) eq12: subst(q,s,eq11);

now here I get the result I wanted to have.
Finelly, I was interested in m, with no deopendeny to a or s.
So, I wanted to have
m= expression

(%i6) solve(eq12,[m]);

Instead, I get no calculation result...

Thanks in advance
ERik








2010/7/13 David Billinghurst <dbmaxima at gmail.com>

> Mein Linuxrechner Arbeit wrote:
>
>>
>> Hello,
>> I tried to replase a in eq11 by the expression on the right side of "=".
>> [a=-(w2-w1)/(2*d*p-2*d*m-d^2)]
>> Bit instead of doing that, s is simply replaced by a.
>> How can I make maxima do what I want?
>>
>> (%i1) eq10: w1-w2=-a*(p-d-m)^2 + a*(p-m)^2;
>> (%i2) eq11: w3-w1=-s*(p+d-m)^2 + s*(p-m)^2;
>> (%i3) linsolve(eq10,[a]);
>> (%i4) eq11: subst(a,s,eq11);
>>
> I would use an intermediate variable s to store the solution, but % would
> work too.
>
>
> (%i1) eq10: w1-w2=-a*(p-d-m)^2 + a*(p-m)^2$
> (%i2) eq11: w3-w1=-s*(p+d-m)^2 + s*(p-m)^2$
> (%i3) s:solve(eq10,[a]);
>                                     w2 - w1
> (%o3)                     [a = - ------------------]
>                                                 2
>
>                                2 d p - 2 d m - d
> (%i4) subst(s,eq11);
>                                     2                2
> (%o4)                w3 - w1 = (p - m)  s - (p - m + d)  s
>
>