How do you model a linear equation when there's no apparent pattern between x and y? For example x=30, y=134, x=31, y=155, x=33, y=165, x=35,...

Hello!


It is obvious that there is no linear formula exactly connecting these x's and y's, if we consider the slopes between neighbor points:



For a single line, all these slopes must be the same.


But this isn't the whole story. We may seek such a line that would be the closest to...

Hello!


It is obvious that there is no linear formula exactly connecting these x's and y's, if we consider the slopes between neighbor points:



For a single line, all these slopes must be the same.


But this isn't the whole story. We may seek such a line that would be the closest to all these points. The simplest criteria of such a proximity is the least squares one, which means we try to minimize



This problem has the exact unique answer (see for example the link attached). We have to compute the numbers


     and  


In our case   and Then we solve the linear system for the unknowns a and b,


   (here n=4).


I hope you know how to solve such systems, the solution for this is


No comments:

Post a Comment

What are the problems with Uganda's government?

Youth unemployment and corruption are two problems that face the Ugandan government. Modern governments all over the world face many problem...