Sergey.Bochkanov wrote:
Even with parabolic fitting it is still
linear regression. Take a look at
http://en.wikipedia.org/wiki/Polynomial_regression for discussion of linear vs. nonlinear aspects. But it applies only for cases where you can formulate your problem as dependence Y(X). If your parabola can be rotated arbitrarily in X-Y plane, than you have nonlinear total-least-squares-like regression problem. Such problems can be solved with nonlinear optimizer, but the problem is that functionality you need (nonlinear derivative-free fitting) is accessible in ALGLIB 3.2 only. Delphi version is still 2.6, which is inconvenient and doesn't support modern features you will need.
Can you switch to C++ (at least for computational parts of your application)?
Let's say that switching to C++ would be possible (maybe developing a dedicated DLL), but at the moment I prefer staying in my own language. I will consider anyway your advice if I can't find a way out to parabolic fitting problem.
Let me ask you an advice on
constant curve detection...
I simplyfied the problem by applying a linear regression over a sample of points, considering covered distance over local radius (or curvature) between points.
Let's say: as much distance is growing as much radius shoud remain constant.
So, putting distance in X and radius in Y (where Y(X)), applying the regression, I should get a correlation coefficient (Pearson) that shoud tell me how much distance and radius are related together. Strong correlation should return a value tending to 1. Weak correlation should return a value tending to 0.
But that's a correlation coefficient, and maybe I should verify some other normalized index telling me that there is "no correlation" between X and Y, or that the values are almost uncorrelate...
Anyway I don't get a "good" parametrable regression coefficient, talking about method decribed above.
Is this a good approach, or there may be better approaches to this problem?
Thank you.