Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread computational . group
Looks great, thanks for all the help! I'll see about messing around with complex_plot a bit to support pure zero plots, if it amounts to something I'll get back in touch... On Monday, June 10, 2013 11:55:28 AM UTC-5, William wrote: > > Try this: > > z,n = var('z,n') > > @interact > def _(f = (

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread William Stein
Try this: z,n = var('z,n') @interact def _(f = ((z+1)^n-abs(z^n+1)), n = (2..10), B=(2..10)): f = f.subs(n=n) show(f) show(complex_plot(f, (-B,B), (-B,B))) On Mon, Jun 10, 2013 at 9:42 AM, wrote: > Okay, so the following works: > > > z = var('z') > n = 2 > @interact > def _(f = ((z

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread computational . group
Okay, so the following works: z = var('z') n = 2 @interact def _(f = ((z+1)^n-abs(z^n+1)), B=(2..10)): show(complex_plot(f, (-B,B), (-B,B))) But the following doesn't: z = var('z') @interact def _(f = ((z+1)^n-abs(z^n+1)), n = (2..10), B=(2..10)): show(complex_plot(f, (-B,B), (-B,B)))

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread William Stein
On Mon, Jun 10, 2013 at 9:24 AM, wrote: > Ah, that's unfortunate. Might be a fun summer project to try to implement, > if I knew where to start. 1. http://www.sagemath.org/development.html 2. SAGE_ROOT/devel/sage/sage/plot/complex_plot.pyx which I found by doing search_src('complex_plot') > O

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread computational . group
Ah, that's unfortunate. Might be a fun summer project to try to implement, if I knew where to start. On another note: I really like the @interact annotation. I'm messing around with it, because I would like to add another parameter to my plot - an integer representing an index in a discrete fam

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread William Stein
On Mon, Jun 10, 2013 at 9:09 AM, wrote: > Thanks, this is exactly what I was looking for! > > In fact, I had tried out complex_plot but I must have been using a different > color function or something, because the roots were much less apparent to > me. Not sure why I couldn't figure this out on m

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread computational . group
Thanks, this is exactly what I was looking for! In fact, I had tried out complex_plot but I must have been using a different color function or something, because the roots were much less apparent to me. Not sure why I couldn't figure this out on my own... I suppose I have two follow-up question

Re: [sage-support] Plot the zeros of a complex function

2013-06-10 Thread William Stein
On Sun, Jun 9, 2013 at 3:25 PM, wrote: > Suppose I have a complex function f(z) with a continuous family of zeros > (e.g., f(z)=z-|z|) > > Is there a way to easily plot the set of zeros of f in sage, regardless of > how complicated the function f is? > You might find complex_plot useful. For

[sage-support] Plot the zeros of a complex function

2013-06-09 Thread computational . group
Suppose I have a complex function f(z) with a continuous family of zeros (e.g., f(z)=z-|z|) Is there a way to easily plot the set of zeros of f in sage, regardless of how complicated the function f is? -- You received this message because you are subscribed to the Google Groups "sage-support"