Software for finding a best-fit ellipse ()?

Click For Summary
Calibrating a magnetometer sensor involves transforming uncalibrated output, which graphs as an ellipse, into a calibrated output that graphs as a circle. To achieve this, software that can compute a best-fit ellipse from data points is needed, along with the ability to calculate eccentricity to verify calibration success. While dedicated libraries exist for this purpose, users with limited coding skills prefer ready-to-use applications. Recommendations include the MATLAB function "fit_ellipse," which can also calculate eccentricity. However, purpose-built Windows executables for this specific task are rare, and users are encouraged to learn mathematical software like MATLAB, Mathematica, or GNU Octave for broader functionality.
jesusu2
Messages
5
Reaction score
0
Hello all, I'm calibrating a magnetometer sensor. An uncalibrated sensor will output values that will graph an ellipse. A calibrated sensor will output values that will graph a circle. Since there's data points all over the place, I'd like to find a piece of software that will take my data and give me a best-fit ellipse, with its equation, and with this I'll be able to calculate the eccentricity and see whether my calibrations actually worked.
I'm not versed in coding whatsoever, so I would prefer if there was some sort of .exe program I could use that would automatically calculate based off my values.
I've attached an picture of the type of data I'm dealing with.
 

Attachments

  • plot.png
    plot.png
    8.7 KB · Views: 807
Physics news on Phys.org
This would normally be done with a math package and hand-writing the code.
http://www.emis.de/journals/BBMS/Bulletin/sup962/gander.pdf

There are dedicated libraries for this it seems - for the googling. i.e.
http://www.codeproject.com/Articles/692787/Best-fitting-line-circle-and-ellipse
... but you are not so much of a programmer... hmmm...

For ready-to-use I'd suggest the Matlab function "fit_ellipse"
http://www.mathworks.com/matlabcentral/fileexchange/3215-fit-ellipse
... you can also get MATLAB to calculate the eccentricity and just output that.

I would not expect to find a purpose built windows executable for your purpose - I think I saw a geology program "ellipsefit" a while ago tho - it is the kind of functionality that gets built into math programs and you are encouraged to learn to use at least one of Matlab, Mathematica, GNU Octave. I know that seems like overkjill for just this one task but it pays off in the long run.
 

Similar threads

  • · Replies 9 ·
Replies
9
Views
4K
  • · Replies 14 ·
Replies
14
Views
3K
  • · Replies 12 ·
Replies
12
Views
4K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K
Replies
4
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 6 ·
Replies
6
Views
5K
  • · Replies 3 ·
Replies
3
Views
4K
  • · Replies 8 ·
Replies
8
Views
4K