How to plot a surface (something like outer part of a torus) tangent to the given 3-D points?

2 views (last 30 days)
Majid on 24 Sep 2021
Commented: Majid on 25 Sep 2021
I have many 3-D points on the space and want to plot something like a torus (only its outside) over them which covers all the available points. I used the convhull() and alphaShape() functions of Matlab to do so, but it did not work very well in this case. In fact, these functions gave me something like an ellipsoid which covers all the points. Please see the attached photos.
Where do I have these points?
From solving an equation on the points of a closed curve (the blue curve in the figures), I have found several solutions (the blue points). To make it easier to understand, I added a photo which shows the lines from corresponding points on the curve to the found solutions.
The photos:
Figure 1: the plot of curve with the lines from the points on the curve to the solutions.
Figure 2: the curve and the solutions (the blue points)
Figure 3: the result obtianed byusing alphaShape().
Figure 4: the result obtained by simplified alphaShape(). In this figure, I added a red circle in paint to show that there is no solutions in this circle and so I want to have a hole here (somehow, the difference between ellipsoid and torus).
However, as I said, these figures (3 and 4) are something like an ellipsoid, but I need something like a torus.
Any help would be appreciated.
  1 Comment
Majid on 25 Sep 2021
Something that I have tried and is the best one which I could have plotted is the following figures. In fact, I increased the number of points on the curve. Then, I used the plot3() function to plot a separate line on all the solutions corresponding to each point on the curve. This way, I have many lines which somehow show the surface which I am looking for.
Here are the photos.

Sign in to comment.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!