Ask Your Question
0

3dplot of modulus of complex function

asked 2013-09-04 06:55:44 -0500

david8381 gravatar image

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

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2013-09-04 07:13:04 -0500

tmonteil gravatar image

updated 2013-09-04 07:20:53 -0500

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)
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2013-09-04 06:55:44 -0500

Seen: 110 times

Last updated: Sep 04 '13