If we're finding an interpolating polynomial for 10 data pairs, the order of the polynomial has to be 9.
In class, my professor said that when doing a polynomial least squares fit, if you have 10 data pairs, then the polynomial with the maximum order will have an order of 9.
However, I've seen in some numerical methods book that they use that the maximum is 8 (which I think is wrong).
Wolfram's page includes no restriction whatsoever.
And as a homework I have been given the task to create a program for polynomial least squares fitting, where the user specifies the maximum order polynomial that is to be calculated.
I don't know if I should include a certain restriction here.
It seems arbitrary to include a restriction. What do you guys think? What is more mathematically sound/accepted/correct ?