0

I have a triaxial ellipsoid and I have the center location in 3D space, as well as the x, y, and z radii, and I want to distribute points evenly around the surface of said ellipsoid. I've tried a couple things and I was able to implement the solution I found here: https://stackoverflow.com/a/26127012/6772918, however this function works specifically for spheres. When I stretch the points to fit onto my ellipsoid, the farther from sphere, the less evenly distributed the points appear.

Unfortunately I don't know enough about the equation I've implemented to modify it (I didn't do all that great in trig).

Spektre
  • 45,598
  • 10
  • 100
  • 347
  • [Look here](https://math.stackexchange.com/questions/973101/how-to-generate-points-uniformly-distributed-on-the-surface-of-an-ellipsoid) and [here](https://stackoverflow.com/questions/56404399/how-to-generate-a-random-sample-of-points-from-a-3-d-ellipsoid-using-python) – MBo Oct 26 '20 at 04:53
  • this is pretty big problem and sphere solutions will not help you any bit ... I would start with this: [Algorithm for shape calculation (Ellipse)](https://stackoverflow.com/a/19560243/2521214) and combine with this approach for [Make a sphere with equidistant vertices](https://stackoverflow.com/a/25031737/2521214) to port from 2D to 3D. However there might be also wilder solutions like these: [How to distribute points evenly on the surface of hyperspheres in higher dimensions?](https://stackoverflow.com/a/57240140/2521214) see both my answers more recent one might be very interesting for this – Spektre Oct 26 '20 at 07:31
  • I'd say with n points you can calculate the density. so if you go up in a spiral ( but not necessary ) the dphi/dtheta should depend on the differential length of the path or say dphi on the circumference of the x-y cross section ellipse and dtheta on the change of that length with height. If you are already struggling with trig, I'd say that'll be quite a challenge. Cheers – mikuszefski Oct 26 '20 at 09:35
  • @mikuszefski Challenge it is as the circumference of ellipse is not known ... and known approximations of it will lead to cumulative errors in density which for 3D will be substantial... – Spektre Oct 27 '20 at 05:53
  • @Spectre I think that the approximations for the circumference are no issue as you can have those to a mind-boggling precision with little effort ( [just for fun](https://www.youtube.com/watch?v=5nW3nJhBHL0) ). And even if you know it, it wouldn't help. There is-with a few exceptions (platonic bodies)-no equal density grid for the sphere either. There are extremely high symmetry solutions for some given numbers of points, though. – mikuszefski Oct 27 '20 at 07:11
  • @mikuszefski that sounds like bunch of ideas suitable to be compiled into answer ... – Spektre Oct 27 '20 at 17:03
  • I was also thinking about a typical optimization that is done for the sphere, namely making the points charged particles and minimize the energy. This gives somewhat a good and evenly distributed set. You would need a proper distance function, though, and this is quite a mess on the general ellipsoid. – mikuszefski Oct 28 '20 at 07:09
  • Please define "evenly". Currently it is unclear what you mean exactly, so I'm voting to close. – zabop Jun 04 '22 at 11:31

0 Answers0