Sure I will. The bug is still present  in version 1.1.1 of sympy (Python 
3.6).

On Monday, October 16, 2017 at 1:26:13 PM UTC-4, Aaron Meurer wrote:
>
> This looks like a bug. Can you open an issue for it? 
>
> Aaron Meurer 
>
> On Mon, Oct 16, 2017 at 10:15 AM,  <[email protected] <javascript:>> 
> wrote: 
> > The following code was run using sympy version 1.0, python version 3.4, 
> > Anaconda installation. 
> > 
> > 
> > import sympy as spy 
> > import sympy.abc as abc 
> > 
> > 
> > N, k = spy.symbols('N, k', positive = True) 
> > es = 1 - (1 - 1/(2*N))**k 
> > e = 2*N*es 
> > spy.pprint(e) 
> > c0 = spy.limit(e, N, spy.oo) 
> > spy.pprint(c0) 
> > c1 = spy.limit(N*(e-c0), N, spy.oo) 
> > spy.pprint(c1) 
> > c2 = spy.limit((e-c0-c1/N)*(N*N), N, spy.oo) 
> > spy.pprint(c2) 
> > c2x = spy.limit(e*N*N-c0*N*N-c1*N, N, spy.oo) 
> > spy.pprint(c2x) 
> > 
> > 
> > It prints 
> > 
> > 
> > 
> >     ⎛           k    ⎞ 
> >     ⎜  ⎛     1 ⎞     ⎟ 
> > 2⋅N⋅⎜- ⎜1 - ───⎟  + 1⎟ 
> >     ⎝  ⎝    2⋅N⎠     ⎠ 
> > k 
> >    2 
> >   k    k 
> > - ── + ─ 
> >   4    4 
> > -∞ 
> >  3    2 
> > k    k    k 
> > ── - ── + ── 
> > 24   8    12 
> > 
> > 
> > As you can see, the result for c2 is wrong, although it is able to 
> calculate 
> > c2x correctly. 
> > 
> > Can someone please clarify what is going on? 
> > 
> > Thanks! 
> > 
> > -- 
> > 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 [email protected] <javascript:>. 
> > To post to this group, send email to [email protected] 
> <javascript:>. 
> > Visit this group at https://groups.google.com/group/sympy. 
> > To view this discussion on the web visit 
> > 
> https://groups.google.com/d/msgid/sympy/8dd538f6-5487-4059-bd8c-eb1a86753af8%40googlegroups.com.
>  
>
> > For more options, visit https://groups.google.com/d/optout. 
>

-- 
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sympy.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/10271026-2201-4c06-87df-47f73ad05e3e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to