# 3dplot of modulus of complex function

Even though abs(x+I*y) should always be real... I get the following error:

plot3d(abs(x+I*y),(x,-5,5),(y,-5,5)) ERROR: unable to coerce to a real number

3dplot of modulus of complex function

Even though abs(x+I*y) should always be real... I get the following error:

plot3d(abs(x+I*y),(x,-5,5),(y,-5,5)) ERROR: unable to coerce to a real number

add a comment

1

This is may not be a good answer explaining why is the `Symbolic Ring`

not working here, but at least a workaround: forget about symbolic functions and use Python lambda functions instead:

```
sage: plot3d(lambda x,y: abs(x+I*y), (x,-5,5), (y,-5,5))
```

or even:

```
sage: plot3d(lambda x,y: abs(x+I*y), (x,-5,5), (y,-5,5), adaptive=True)
```

Asked: **
2013-09-04 06:55:44 -0600
**

Seen: **120 times**

Last updated: **Sep 04 '13**

Absolute value of complex numbers in 3D plot

How to save a 3d plot from sage cell

Computations with complex algebraic numbers?

complex numbers and parametric curves

filling in an area under a function or curve in 3 dimensions

How to export a 3D plot to a jpg/png file (OSX)

Complex argument of an algebraic number

typeset complex norm is missing absolute value [closed]

How I can plot functions of the kind $f:\Bbb R\to\Bbb C$ in 3D properly?

Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.