Hello! I'm trying to get my head wrapped around how to use SolveSet (and 
whether I should be using solve or some other method instead), and I ran 
into the following problem.

I have two sets:

Solution_Set=solveset(Eq(y,x+x/2),y,S.Reals)
Solution_Set2=solveset(Eq(y,1.5*x),y,S.Reals)

Now I want to compare these sets and I was expecting the sets to be 
equivalent. I know they're not "equal" (different forms), but I was 
expecting them to be the same set.

I don't see how I can use simplify here, so I tried the following:

Contains(Solution_Set,Solution_Set2)
    False
Contains(Solution_Set2,Solution_Set)
    False

Intersection(Solution_Set,Solution_Set2)
[25]:   R∩{1.5x}

Solution_Set2-Solution_Set
[37]:   ∅
Solution_Set-Solution_Set2
[38]:   (R∩{3x2})∖(R∩{1.5x})

It would appear that solveset(Eq(y,x+x/2),y,S.Reals) is a superset of 
solveset(Eq(y,1.5*x),y,S.Reals) solveset(Eq(y,1.5*x),y,S.Reals), but 
Contains didn't work!

Is there another way that I should be doing this, or a better way to do 
this comparison? Note that I can't just simplify 3*x/2-1.5*x for a variety 
of reasons - the application might not make it that simple (I've simplified 
my issue to this test case).

Thanks!
Kevin

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sympy+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/29c9fb93-d4f5-4bc5-85af-3f7abcad4e41n%40googlegroups.com.

Reply via email to