Effacer les filtres
Effacer les filtres

how to get points inside a cone ?

3 vues (au cours des 30 derniers jours)
yogesh jain
yogesh jain le 24 Nov 2015
Commenté : M.S. Khan le 18 Août 2020
Hello all , I have a conical section which is hollow and having variable radius and height . how to get all points inside the cone so that I can make it filled cone . I used this code -
r1=input('enter radius');
r=r1:-0.5:0;
[xc,yc,zc] = cylinder(r);
h=input('enter ht');
zc=zc*h;
figure(1)
surf(xc,yc,zc,'Facecolor','w');
grid on
axis equal

Réponse acceptée

Walter Roberson
Walter Roberson le 24 Nov 2015
There are an infinite number of points inside a cone.
To make a 3D object "filled", normally you just use opaque faces to draw it.
  6 commentaires
yogesh jain
yogesh jain le 19 Fév 2016
and if I know starting and ending points of cone , then ? Means it is not in generic way .
M.S. Khan
M.S. Khan le 18 Août 2020
Hi Dr. Walter Roberson, can i consider your code as a point cloud of the cone.
Regards,
M. Shafiq

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur 3-D Scene Control dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by