Am Freitag, den 03.09.2010, 07:58 -0700 schrieb kcrisman:
> Yes, complex_plot is similar to a Mathematica function of the same
> type.
> 
> To plot such a function the way you are indicating, we need to have
> the fast_float/fast_callable functions which do (very fast, as the
> name indicates) evaluation of functions to be plotted to work with
> complex input.  This is largely done, but still needs review and/or
> work.
> 
> Obviously one could work around this by doing everything in x and y
> only (without i, even) but this is not a long-term solution.  I have
> been frustrated by this not working as well in the past.
> 
> Sorry this is not as easily available as it should be.
May I propose a workaround:

sage: var('x,y,z,z0')
(x, y, z, z0)
sage: z0 = 1+i
sage: f(z) = abs(1/(z-z0))
sage: plot3d(lambda x,y: f(x+i*y), (x,0,2), (y,0,2))


I don't know why I can't plot f without the use of lambda:

sage: plot3d(f(x+i*y), (x,0,2), (y,0,2))
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call
last)

/home/ecki/<ipython console> in <module>()

... <snip> ...

TypeError: float() argument must be a string or a number

Is this bug?

sage: version()
'Sage Version 4.3.3, Release Date: 2010-02-21'


Regards

         Eckhard
> 
> - kcrisman
> 
> On Sep 3, 5:52 am, sps <[email protected]> wrote:
> > Can I have a 3d plot graph about a complex funtion in sage?
> > For example:
> > f(z)=abs(1/(z-z0))?
> >
> > I've just tried by the function complex_plot but output is 2d graph!
> > What command I have to use?
> > Thanks
> 
-- 
  Service für Mathematik und Simulation
  Dr. Eckhard Kosin, selbständiger Diplom-Mathematiker

  Am Nymphenbad 14
D-81245 München, Germany

  Tel.: (+49)(+89) 88 88 479
  Tel.,Fax: (+49)(+89) 835 844
  mailto:[email protected]
  http://www.mathematik-service-kosin.de

-- 
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to