Re: Problem with Solve and O[x]
- To: mathgroup at christensen.cybernetics.net
- Subject: [mg1257] Re: Problem with Solve and O[x]
- From: danl (Daniel Lichtblau)
- Date: Mon, 29 May 1995 02:38:49 -0400
- Organization: Wolfram Research, Inc.
In article <3q3mcr$mc5 at news0.cybernetics.net> steve at tweedledee.ucsb.edu
(Steve Trainoff) writes:
> It appears the Solve and O[x] don't mix. Consider the following.
>
> Mathematica 2.0 for NeXT
> Copyright 1988-91 Wolfram Research, Inc.
>
> In[1]:= Solve[x+z==1,x]
>
> Out[1]= {{x -> 1 - z}}
>
> In[2]:= Solve[x+z==1+O[z],x]
>
> Out[2]= {{x -> 1}} (* I would prefer x -> 1 + O[z] *)
>
> In[3]:= Solve[x+z==1+O[z]^2,x]
>
> Out[3]= {} (* What is wrong with x -> 1 + z + O[z]^2 ??? *)
>
> --
>
> ...STeve
This is caused by the fact that Solve uses LogicalExpand, and
LogicalExpand does not do what one might wish in these cases.
In[1]:= LogicalExpand[x == 1+O[z]]
Out[1]= -1 + x == 0
In[2]:= LogicalExpand[x+z==1+O[z]^2]
Out[2]= False
If I can fix this immediate problem without breaking Solve, I'll do so.
Daniel Lichtblau, WRI