Ask Your Question
1

How to plot implicit surfaces as scattered points (no interpolation)

asked 2022-10-13 17:17:56 +0100

moon gravatar image

Hi there, I am failing in plotting as scattered an implicit function. In some posts it is suggested to use point3d however can't see how to that ! This is my basic example:

var('x,y,z,yaxis')
#
ff = 0.28  
hh = 0.07
aa=1
bb=1
dd=1
F=(x^2 + y^2 - 1)^2 + (z -0.5)^2 * ( (y^2/aa^2 + (z + hh)^2 -1)^2 - dd^2 * (1 + bb*(z-0.5)^2) )
r = 2
#Below what I need to work on. 
s=implicit_plot3d(F, (x,-r,r), (y,-r,r), (z,-r,r), plot_points=120, color=mycolor, frame=False)
s.show(viewer='threejs')

Unfortunatyely I'm missing some points to share a picture of the desire. Your help is appreciated.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2022-10-14 09:51:55 +0100

rburing gravatar image

updated 2022-10-14 10:00:23 +0100

This works in principle, but displaying it (each point as a circle!) is slow with high point counts:

s=implicit_plot3d(F, (x,-r,r), (y,-r,r), (z,-r,r), plot_points=15)
s.triangulate()
point3d(s.vertex_list())
edit flag offensive delete link more

Comments

Thanks so much. In fact it works however very computation-power consumming especially beacause I'm working to get a high res. good starting tho. Appreciated.

moon gravatar imagemoon ( 2022-10-14 17:21:39 +0100 )edit

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

Stats

Asked: 2022-10-13 17:17:56 +0100

Seen: 207 times

Last updated: Oct 14 '22