[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-22 Thread Robert Bradshaw
On Aug 21, 2009, at 1:47 PM, William Stein wrote: > On Thu, Aug 20, 2009 at 1:37 PM, Golam Mortuza Hossain > wrote: > > Hi, > > On Thu, Aug 20, 2009 at 3:03 PM, Jason Grout s...@creativetrax.com> wrote: > >> I guess, a policy decision is involved here as to whether use > mathematical > >> id

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-21 Thread Golam Mortuza Hossain
Hi. On Fri, Aug 21, 2009 at 5:47 PM, William Stein wrote: > >> Personally, I am for accepting pynac's answer by default as it >> would massively speed up test like "if x in list" for symbolics. > > We must default to pynac, in my opinion.  The question then just becomes > how to make pynac's comp

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-21 Thread William Stein
On Thu, Aug 20, 2009 at 1:37 PM, Golam Mortuza Hossain wrote: > > Hi, > > On Thu, Aug 20, 2009 at 3:03 PM, Jason Grout > wrote: > >> I guess, a policy decision is involved here as to whether use > mathematical > >> identities by default or as an option during comparison. To clarify: > >> > >> ex =

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-20 Thread Golam Mortuza Hossain
Hi, On Thu, Aug 20, 2009 at 3:03 PM, Jason Grout wrote: >> I guess, a policy decision is involved here as to whether use mathematical >> identities by default or as an option during comparison. To clarify: >> >> ex = sin(x)^2 + cos(x)^2 - 1 >> >> In pynac, for above expression "ex.is_zero()" test

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-20 Thread Jason Grout
Golam Mortuza Hossain wrote: > Hi, > > > On Thu, Aug 20, 2009 at 1:28 PM, William Stein wrote: >> On Thu, Aug 20, 2009 at 4:11 AM, Golam Mortuza >> Hossain wrote: >>> Hi, >>> >>> It takes too long to check whether x is in a list in new symbolics >>> >>> - >>> sage: var('x,x1,x2,x3,x4') >

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-20 Thread William Stein
On Thu, Aug 20, 2009 at 9:57 AM, Golam Mortuza Hossain wrote: > > Hi, > > > On Thu, Aug 20, 2009 at 1:28 PM, William Stein wrote: >> >> On Thu, Aug 20, 2009 at 4:11 AM, Golam Mortuza >> Hossain wrote: >>> >>> Hi, >>> >>> It takes too long to check whether x is in a list in new symbolics >>> >>> --

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-20 Thread Golam Mortuza Hossain
Hi, On Thu, Aug 20, 2009 at 1:28 PM, William Stein wrote: > > On Thu, Aug 20, 2009 at 4:11 AM, Golam Mortuza > Hossain wrote: >> >> Hi, >> >> It takes too long to check whether x is in a list in new symbolics >> >> - >> sage: var('x,x1,x2,x3,x4') >> (x, x1, x2, x3, x4) >> sage: f = funct

[sage-devel] Re: It takes too long to check "x in list" in symbolics!

2009-08-20 Thread William Stein
On Thu, Aug 20, 2009 at 4:11 AM, Golam Mortuza Hossain wrote: > > Hi, > > It takes too long to check whether x is in a list in new symbolics > > - > sage: var('x,x1,x2,x3,x4') > (x, x1, x2, x3, x4) > sage: f = function('f') > sage: mylist = [x1,x2,x3,x4,f(x1),f(x2),f(x3),f(x4)] > > sage: t