>>11574590You can do least squares using various test functions such as x^n, e^(nx), log(x), (x^n)*e^(mx), (x^n)*log(x).
The least squares will find the best linear combination of test functions.
If you have N sample points, usually any N functions can be made to fit them (so it doesn't seem very useful).
What you want is the linear combination that uses the least amount of functions (<N) and still achieves a perfect fit.