ASKSAGE: Sage Q&A Forum - Individual question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Sat, 20 Jul 2013 15:31:16 -0500Graphing Compex Functions 3D (x,y,i axes) Instead Of Color-Coded 2D (x,i)http://ask.sagemath.org/question/10368/graphing-compex-functions-3d-xyi-axes-instead-of-color-coded-2d-xi/Following [this guide to Sage][1]: and using [Sage Online][2] produced the following graphs:
![enter image description here][3]
![enter image description here][4]
It would be nice to see it in 3D instead of merely color coded. The y-axis is coming out of the picture toward us and instead of seeing the 3D surface (in x,y,i coordinates) we see a color-graph on the x-i plane.
You can do what I wish [using Maple:](http://math.stackexchange.com/questions/448397/graphing-compex-functions-3d-x-y-i-axes-instead-of-color-coded-sage/448410?noredirect=1#448410)
[1]: http://www.sagemath.org/doc/reference/plotting/sage/plot/complex_plot.html
[2]: http://www.sagenb.org/
[3]: http://i.stack.imgur.com/gw8Aj.png
[4]: http://i.stack.imgur.com/NYP76.jpgSat, 20 Jul 2013 13:50:24 -0500http://ask.sagemath.org/question/10368/graphing-compex-functions-3d-xyi-axes-instead-of-color-coded-2d-xi/Answer by calc314 for <p>Following <a href="http://www.sagemath.org/doc/reference/plotting/sage/plot/complex_plot.html">this guide to Sage</a>: and using <a href="http://www.sagenb.org/">Sage Online</a> produced the following graphs: </p>
<p><img alt="enter image description here" src="http://i.stack.imgur.com/gw8Aj.png"/></p>
<p><img alt="enter image description here" src="http://i.stack.imgur.com/NYP76.jpg"/></p>
<p>It would be nice to see it in 3D instead of merely color coded. The y-axis is coming out of the picture toward us and instead of seeing the 3D surface (in x,y,i coordinates) we see a color-graph on the x-i plane. </p>
<p>You can do what I wish <a href="http://math.stackexchange.com/questions/448397/graphing-compex-functions-3d-x-y-i-axes-instead-of-color-coded-sage/448410?noredirect=1#448410">using Maple:</a></p>
http://ask.sagemath.org/question/10368/graphing-compex-functions-3d-xyi-axes-instead-of-color-coded-2d-xi/?answer=15259#post-id-15259One approach would be to use `plot3d`. For example,
var('x,y')
plot3d(lambda x,y: norm(1/(((x+i*y)-3)*((x+y*i)+2))),(x,-4,4),(y,-4,4))
gives
![image description](/upfiles/1374370159956205.jpg)
I've not been able to get the coloring that you'd probably like, but this does give the 3d plot rather than the 2d plot you were getting.
Sat, 20 Jul 2013 15:31:16 -0500http://ask.sagemath.org/question/10368/graphing-compex-functions-3d-xyi-axes-instead-of-color-coded-2d-xi/?answer=15259#post-id-15259