The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 795 - File: showthread.php PHP 7.4.33 (FreeBSD)
File Line Function
/showthread.php 795 errorHandler->error





Post Reply 
Mean value by Least Squares Method
08-02-2019, 07:17 PM (This post was last modified: 08-02-2019 09:14 PM by Hans Wurst.)
Post: #1
Mean value by Least Squares Method
The mean is the average of the numbers or in other words \(\bar{x} = \displaystyle \frac{1}{n}\displaystyle\sum_{k=1}^{n}x_k\)
How may I derive this simple formula using the Least Squares Method on an HP Prime?
I get quite close to it
\(\displaystyle \frac{\partial \displaystyle \sum_{k=1}^{n}(x(k)-m)^2}{\partial m} = sum(-2*(x(k)-m),k,1,n)\)
alas neither FNROOT nor solve are of much help for the last algebraic step. What do I wrong?

Another problem I was not able yet to solve on an HP Prime: How to prove which of the roots of a quadratic equation is the correct one. It's about orthogonal linear regression (sorry for the link to Wikipedia in german, but I could not find similar in English -- but honestly, the formulas are international), the Least Squares Method is applied to find both coefficients, where for m there are two solutions. One may be eliminated by fiddling out the sign of the third second derivative at the roots (or one root at least). I did so using Reduce, but all I tried so far on a Prime failed.

So in both cases it is not about the result, I'd like to know how to get there using a Prime.

TIA
Hans
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Mean value by Least Squares Method - Hans Wurst - 08-02-2019 07:17 PM



User(s) browsing this thread: 1 Guest(s)