Ask Your Question

How to draw geometrical figures with coordinate axes

asked 2018-02-10 04:08:29 +0200

MKS gravatar image

I would like to draw geometrical figures with coordinate axes. suppose I want to draw a sphere with three coordinate axes x,y,z. How can I do this?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2018-02-10 14:37:37 +0200

eric_g gravatar image

Like this:

from sage.plot.plot3d.plot3d import axes
g = sphere(opacity=0.8)
show(g + axes(scale=1.5, radius=0.5, color='red'), viewer='threejs')

Note that if you don't want the bounding box (frame) to be drawn, you can do

show(g + axes(scale=1.5, radius=0.5, color='red'), frame=False, viewer='threejs')

For more details on the function axes, see the documentation here.

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

1 follower


Asked: 2018-02-10 04:08:29 +0200

Seen: 254 times

Last updated: Feb 10 '18