Hey, sorry if this is not the right section to post in, the topic is a bit ambiguous.(adsbygoogle = window.adsbygoogle || []).push({});

I've generated a set of coordinate points for the orbit of Mercury (3d cartesian) and now I want to fit an ellipse through it so I can get an accurate estimate of the location of the perihelion. I am using python (as an excuse to learn the language) and I find this task to be a lot more complicated than I've initially hoped:

So far I only managed to plot the 2dprojectionof the ellipse onto the xy plane, using least squares fitting (alternatively I can do the same with the other two planes) but I am struggling to come up with a way to take it to the third dimension.

I thought maybe I can fit an ellipsoid, or fit a plane through Mercury's ecliptic and somehow reduce it back to a 2d problem, but quite frankly after a lot of googling and browsing of papers I came to the conclusion that I just don't know how to do either of these things. I need some advice.

Could someone please give me a few pointers?

Thank you.

**Physics Forums | Science Articles, Homework Help, Discussion**

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Fitting an ellipse through 3-d data

Loading...

Similar Threads for Fitting ellipse through |
---|

Bi-exponential function fitting in Origin Lab SW |

MATLAB Parameter fitting with a numerical solution |

Mathematica Chisquare fit to multiple data sets |

MATLAB Weighting data points with fitted curve in Matlab |

**Physics Forums | Science Articles, Homework Help, Discussion**