Discretize sphere into 3xN points

7 views (last 30 days)
I need to discretize a sphere into 3xN points. I know the sphere function in Matlab will generate points, but it generates the X, Y, Z coordinates as matrices. I don't really understand how these matrices work to convert them into a list of 3XN cartesian coordinates. Thanks
  2 Comments
Jan
Jan on 15 Apr 2021
Then sphere is not the best point to start. Do you have any specifications for discretization? Do you want radom point, equi-distributed points, or do you have a specific set of values for N?
Hannah Rosenberg
Hannah Rosenberg on 15 Apr 2021
I have a specified radius and centre. Being able to specify a set value of N would be nice but not necessary.

Sign in to comment.

Accepted Answer

Jan
Jan on 15 Apr 2021
  1 Comment
Hannah Rosenberg
Hannah Rosenberg on 15 Apr 2021
I just used the mysphere function and multiplied by the radius, added the centre. Thanks.

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!