polynomial curve fitting: higher order models' root mean square error does not decrease The 2019 Stack Overflow Developer Survey Results Are In Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Fitting a polynomial + exponential curve of a given form to dataWhen does Mean Square Error increase?Mean Square Error & BiasNegative Mean Square ErrorRoot Mean Square Error - How did he get this number?liner regression not using mean square error to estimate parameterpolynomial curve fitting without regression (power law)What does the derivative mean in least squares curve fitting?Mean Integrated Square Errorpolynomial curve fitting and linear algebra

Can withdrawing asylum be illegal?

The following signatures were invalid: EXPKEYSIG 1397BC53640DB551

Is this wall load bearing? Blueprints and photos attached

Why did all the guest students take carriages to the Yule Ball?

What is this lever in Argentinian toilets?

How does ice melt when immersed in water?

High Q peak in frequency response means what in time domain?

Why can't wing-mounted spoilers be used to steepen approaches?

What was the last x86 CPU that did not have the x87 floating-point unit built in?

How do I add random spotting to the same face in cycles?

What information about me do stores get via my credit card?

How did passengers keep warm on sail ships?

Why is superheterodyning better than direct conversion?

Why does the Event Horizon Telescope (EHT) not include telescopes from Africa, Asia or Australia?

Can smartphones with the same camera sensor have different image quality?

Am I ethically obligated to go into work on an off day if the reason is sudden?

Simulation of a banking system with an Account class in C++

Who or what is the being for whom Being is a question for Heidegger?

Road tyres vs "Street" tyres for charity ride on MTB Tandem

Is above average number of years spent on PhD considered a red flag in future academia or industry positions?

Why can't devices on different VLANs, but on the same subnet, communicate?

Are my PIs rude or am I just being too sensitive?

Typeface like Times New Roman but with "tied" percent sign

Is every episode of "Where are my Pants?" identical?



polynomial curve fitting: higher order models' root mean square error does not decrease



The 2019 Stack Overflow Developer Survey Results Are In
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)Fitting a polynomial + exponential curve of a given form to dataWhen does Mean Square Error increase?Mean Square Error & BiasNegative Mean Square ErrorRoot Mean Square Error - How did he get this number?liner regression not using mean square error to estimate parameterpolynomial curve fitting without regression (power law)What does the derivative mean in least squares curve fitting?Mean Integrated Square Errorpolynomial curve fitting and linear algebra










0












$begingroup$


I am trying to fit a curve for 15 data points. I started by creating a linear model and observing the root mean square difference, followed by quadratic, cubic and increasing the degree of polynomial at each iteration and also measuring the root mean square difference for each model. My data points are as follows:



x = -1.45, -1.12, -0.50, 1.40, 2.28, 3.50, 3.75, 4.50, 5.21, 5.98,6.65, 7.76, 8.56, 9.64, 10.87;
y = 4.30, 4.24, 3.10, 1.50, 5.73, 2.30, 5.31, 3.76, 7.40, 4.13, 9.45, 5.40, 12.67, 8.42, 14.86;


So far the results I got are as follows:



d - the degree of the model. d=2 is quadratic model and d=3 is cubic model



d rmsd
1 2.42613
2 1.95418
3 1.95373
4 1.91411
5 1.90665
6 1.86912
7 1.81113
8 1.80812
9 1.66018
10 1.36661
11 1.36122
12 1.75445
13 0.993169
14 1.795
15 3.52391


For degree 15, root mean square difference should be closer to zero, regardless of over fitting concerns. Reason being, if you think about it mathematically, it will be fifteen equations and fifteen unknowns and should have a solution. My question is what could have gone wrong in the polynomial curve fitting? I am just testing the linear algebra concepts here. I understand higher degree models may not be right choice.










share|cite|improve this question









$endgroup$











  • $begingroup$
    Your fitting is incorrect if (as you have stated) all $x$ values are distinct. The 14th degree best fit polynomial will interpolate all data points exactly.
    $endgroup$
    – hardmath
    Oct 1 '15 at 21:58
















0












$begingroup$


I am trying to fit a curve for 15 data points. I started by creating a linear model and observing the root mean square difference, followed by quadratic, cubic and increasing the degree of polynomial at each iteration and also measuring the root mean square difference for each model. My data points are as follows:



x = -1.45, -1.12, -0.50, 1.40, 2.28, 3.50, 3.75, 4.50, 5.21, 5.98,6.65, 7.76, 8.56, 9.64, 10.87;
y = 4.30, 4.24, 3.10, 1.50, 5.73, 2.30, 5.31, 3.76, 7.40, 4.13, 9.45, 5.40, 12.67, 8.42, 14.86;


So far the results I got are as follows:



d - the degree of the model. d=2 is quadratic model and d=3 is cubic model



d rmsd
1 2.42613
2 1.95418
3 1.95373
4 1.91411
5 1.90665
6 1.86912
7 1.81113
8 1.80812
9 1.66018
10 1.36661
11 1.36122
12 1.75445
13 0.993169
14 1.795
15 3.52391


For degree 15, root mean square difference should be closer to zero, regardless of over fitting concerns. Reason being, if you think about it mathematically, it will be fifteen equations and fifteen unknowns and should have a solution. My question is what could have gone wrong in the polynomial curve fitting? I am just testing the linear algebra concepts here. I understand higher degree models may not be right choice.










share|cite|improve this question









$endgroup$











  • $begingroup$
    Your fitting is incorrect if (as you have stated) all $x$ values are distinct. The 14th degree best fit polynomial will interpolate all data points exactly.
    $endgroup$
    – hardmath
    Oct 1 '15 at 21:58














0












0








0





$begingroup$


I am trying to fit a curve for 15 data points. I started by creating a linear model and observing the root mean square difference, followed by quadratic, cubic and increasing the degree of polynomial at each iteration and also measuring the root mean square difference for each model. My data points are as follows:



x = -1.45, -1.12, -0.50, 1.40, 2.28, 3.50, 3.75, 4.50, 5.21, 5.98,6.65, 7.76, 8.56, 9.64, 10.87;
y = 4.30, 4.24, 3.10, 1.50, 5.73, 2.30, 5.31, 3.76, 7.40, 4.13, 9.45, 5.40, 12.67, 8.42, 14.86;


So far the results I got are as follows:



d - the degree of the model. d=2 is quadratic model and d=3 is cubic model



d rmsd
1 2.42613
2 1.95418
3 1.95373
4 1.91411
5 1.90665
6 1.86912
7 1.81113
8 1.80812
9 1.66018
10 1.36661
11 1.36122
12 1.75445
13 0.993169
14 1.795
15 3.52391


For degree 15, root mean square difference should be closer to zero, regardless of over fitting concerns. Reason being, if you think about it mathematically, it will be fifteen equations and fifteen unknowns and should have a solution. My question is what could have gone wrong in the polynomial curve fitting? I am just testing the linear algebra concepts here. I understand higher degree models may not be right choice.










share|cite|improve this question









$endgroup$




I am trying to fit a curve for 15 data points. I started by creating a linear model and observing the root mean square difference, followed by quadratic, cubic and increasing the degree of polynomial at each iteration and also measuring the root mean square difference for each model. My data points are as follows:



x = -1.45, -1.12, -0.50, 1.40, 2.28, 3.50, 3.75, 4.50, 5.21, 5.98,6.65, 7.76, 8.56, 9.64, 10.87;
y = 4.30, 4.24, 3.10, 1.50, 5.73, 2.30, 5.31, 3.76, 7.40, 4.13, 9.45, 5.40, 12.67, 8.42, 14.86;


So far the results I got are as follows:



d - the degree of the model. d=2 is quadratic model and d=3 is cubic model



d rmsd
1 2.42613
2 1.95418
3 1.95373
4 1.91411
5 1.90665
6 1.86912
7 1.81113
8 1.80812
9 1.66018
10 1.36661
11 1.36122
12 1.75445
13 0.993169
14 1.795
15 3.52391


For degree 15, root mean square difference should be closer to zero, regardless of over fitting concerns. Reason being, if you think about it mathematically, it will be fifteen equations and fifteen unknowns and should have a solution. My question is what could have gone wrong in the polynomial curve fitting? I am just testing the linear algebra concepts here. I understand higher degree models may not be right choice.







linear-algebra statistics systems-of-equations algebraic-curves regression






share|cite|improve this question













share|cite|improve this question











share|cite|improve this question




share|cite|improve this question










asked Oct 1 '15 at 19:54









kpnanekpnane

11




11











  • $begingroup$
    Your fitting is incorrect if (as you have stated) all $x$ values are distinct. The 14th degree best fit polynomial will interpolate all data points exactly.
    $endgroup$
    – hardmath
    Oct 1 '15 at 21:58

















  • $begingroup$
    Your fitting is incorrect if (as you have stated) all $x$ values are distinct. The 14th degree best fit polynomial will interpolate all data points exactly.
    $endgroup$
    – hardmath
    Oct 1 '15 at 21:58
















$begingroup$
Your fitting is incorrect if (as you have stated) all $x$ values are distinct. The 14th degree best fit polynomial will interpolate all data points exactly.
$endgroup$
– hardmath
Oct 1 '15 at 21:58





$begingroup$
Your fitting is incorrect if (as you have stated) all $x$ values are distinct. The 14th degree best fit polynomial will interpolate all data points exactly.
$endgroup$
– hardmath
Oct 1 '15 at 21:58











1 Answer
1






active

oldest

votes


















0












$begingroup$

I tried working out the same as you using Excel. My results agree with yours up to $d=11$. From that point on we begin to differ. The reason is that the difference in size of the values becomes so great that no meaningful analysis is possible. In Excel, by the time you are trying to work with $d=11$ you have to find the 11th power of each x-value and these range from $4.9 times 10^-4$ to $2.5 times 10^9$. Depending on the software you are using to find the fit, it will fail earlier or later, but eventually the results will start to be meaningless.






share|cite|improve this answer











$endgroup$













    Your Answer








    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "69"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    noCode: true, onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f1460080%2fpolynomial-curve-fitting-higher-order-models-root-mean-square-error-does-not-d%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0












    $begingroup$

    I tried working out the same as you using Excel. My results agree with yours up to $d=11$. From that point on we begin to differ. The reason is that the difference in size of the values becomes so great that no meaningful analysis is possible. In Excel, by the time you are trying to work with $d=11$ you have to find the 11th power of each x-value and these range from $4.9 times 10^-4$ to $2.5 times 10^9$. Depending on the software you are using to find the fit, it will fail earlier or later, but eventually the results will start to be meaningless.






    share|cite|improve this answer











    $endgroup$

















      0












      $begingroup$

      I tried working out the same as you using Excel. My results agree with yours up to $d=11$. From that point on we begin to differ. The reason is that the difference in size of the values becomes so great that no meaningful analysis is possible. In Excel, by the time you are trying to work with $d=11$ you have to find the 11th power of each x-value and these range from $4.9 times 10^-4$ to $2.5 times 10^9$. Depending on the software you are using to find the fit, it will fail earlier or later, but eventually the results will start to be meaningless.






      share|cite|improve this answer











      $endgroup$















        0












        0








        0





        $begingroup$

        I tried working out the same as you using Excel. My results agree with yours up to $d=11$. From that point on we begin to differ. The reason is that the difference in size of the values becomes so great that no meaningful analysis is possible. In Excel, by the time you are trying to work with $d=11$ you have to find the 11th power of each x-value and these range from $4.9 times 10^-4$ to $2.5 times 10^9$. Depending on the software you are using to find the fit, it will fail earlier or later, but eventually the results will start to be meaningless.






        share|cite|improve this answer











        $endgroup$



        I tried working out the same as you using Excel. My results agree with yours up to $d=11$. From that point on we begin to differ. The reason is that the difference in size of the values becomes so great that no meaningful analysis is possible. In Excel, by the time you are trying to work with $d=11$ you have to find the 11th power of each x-value and these range from $4.9 times 10^-4$ to $2.5 times 10^9$. Depending on the software you are using to find the fit, it will fail earlier or later, but eventually the results will start to be meaningless.







        share|cite|improve this answer














        share|cite|improve this answer



        share|cite|improve this answer








        edited Oct 2 '15 at 14:22

























        answered Oct 2 '15 at 0:20









        tomitomi

        6,21411232




        6,21411232



























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Mathematics Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            Use MathJax to format equations. MathJax reference.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f1460080%2fpolynomial-curve-fitting-higher-order-models-root-mean-square-error-does-not-d%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Bosc Connection Yimello Approaching Angry The produce zaps the market. 구성 기록되다 변경...

            WordPress Information needed

            Hidroelektrana Sadržaj Povijest | Podjela hidroelektrana | Snaga dobivena u hidroelektranama | Dijelovi hidroelektrane | Uloga hidroelektrana u suvremenom svijetu | Prednosti hidroelektrana | Nedostaci hidroelektrana | Države s najvećom proizvodnjom hidro-električne energije | Deset najvećih hidroelektrana u svijetu | Hidroelektrane u Hrvatskoj | Izvori | Poveznice | Vanjske poveznice | Navigacijski izbornikTechnical Report, Version 2Zajedničkom poslužiteljuHidroelektranaHEP Proizvodnja d.o.o. - Hidroelektrane u Hrvatskoj