Questions about (linear or nonlinear) least-squares, an estimation method used in statistics, signal processing and elsewhere.
Questions tagged [least-squares]
1853 questions
0
votes
1 answer
Least-squares with equality constraints
So I have a problem in the form of $y = Ax$, where $A$ is a matrix and $x$ and $y$ are vectors. $A$ is a skinny matrix and I would like to do a least squares solution to solve for $x$. Let's say though that $x$ has $10$ rows. In my solution I…
PumpkinPie
- 25
0
votes
1 answer
Minimize the various norms given a set of linear equations.
Given $Ax=b$, I know how to use least squares to minimize $\|Ax−b\|^2$. How do I minimize the 2-norm $(\|x\|^2)$ and the Frobenius norm of $x$? A is $3 \times 2$. B is $3 \times 1$.
user100503
- 449
0
votes
1 answer
Minimize sum of Least Squares
If xi minimizes ||Ax-bi||^2, how do I solve minimize ||Ax-b1||^2 + ... ||Ax-bk||^2 in terms of x1 through xk? I am looking for some direction.
user100503
- 449
0
votes
1 answer
Deriving the least squares method
I would like to understand more about the Least Squares, but it remains unclear to me, where these equations come from.
for a linear approximation $y=ax+b$
$a=\frac{m\sum_{i=1}^{m} x_iy_i-(\sum_{i=1}^{m}x_i)(\sum_{i=1}^{m}y_i)}
{m\sum_{i=1}^{m}x_i^2…
0
votes
0 answers
Why is the norm the last $m - n$ elements of $Q^Tb$ in least squares?
The answer to this question says that
If you're solving the Least Squares problem minimizing $||Ax - b||_2$ then the error, or residual, is the norm of the last m-n elements of the vector $Q^Tb$.
where $Q$ is from the $QR$ decomposition. Why is…
greg115
- 443
0
votes
0 answers
C/C++ library for linear least squares with linear inequalities
Lawson and Hanson provide an algorithm for linear least squares with inequalities (LSI) (https://epubs.siam.org/doi/abs/10.1137/1.9781611971217.ch23) and the Fortran code for it
(https://www.netlib.org/lawson-hanson/all). Does anyone know a C/C++…
cookie
- 31
0
votes
0 answers
Is Least Squares a flawed method? (Is ABS better?)
Okay I watched this video. https://www.youtube.com/watch?v=PaFPbb66DxQ Guy seems to have based Sheldon vibes, but he just says people don't use abs because its mathematically tricky. Any particular reason for this? Seems like Abs would be…
proj786
- 11
0
votes
1 answer
Least Squares (LS) fitting
I Have a Least Squares problem. I have a very large data set $Z$, define as follows:
$Z = \begin{bmatrix} z_0 \\ z_1 \\ \vdots \\ z_{N} \end{bmatrix}$
First, I want to fit it into the following polynomial:
$z_k = a + cx_{k}^2$. after that, the…
0
votes
0 answers
Discrete Least Mean Squared / Least Means Regresssion for multiple samples
I understand how to perform a least means regression of a given set of $x$ points to approximate a line that best fits them. In this case I observe a set of $x$ inputs and y corresponding outputs. Then I can create$ a \hat y = m\hat x+ b$ which is a…
0
votes
1 answer
Finding a parabola with least squares
We are asked to find the equation of the parabola in the xy-plane that passes through the origin, has a vertical axis parallel to the y-axis, and passes closest - in the sense of least squares - to the points (-1,3), (1,1), and (2,5).
I tried to…
Θάνος Κ.
- 41
0
votes
2 answers
Find frequency of sinusoidal fit to a data which covers only part of a period
I am trying to fit a general Sinusoidal curve on a set of data points with following features:
Data covers only part of the period
Data points are not equally distanced apart
What would be the best way to approximate the frequency in this specific…
0
votes
0 answers
How to create formula for this lookup table
I have a lookup table.
$X$ values are:
$\{230, 220, 210, 200, 190, 180, 170, 160, 150, 140, 130, 120, 110, 100, 90, 80\}$
$Y$ values are:
$\{2590, 2590, 2590, 2580, 2540, 2460, 2260, 1870, 1240, 1040, 960, 800, 680, 480, 360, 160\}$
This is the…
Bowman
- 103
0
votes
1 answer
Simplifying this least squares cost function
I am beginning to study normal equations and am looking at the cost functions.
I wish to get from this equation where w is the weight vector, x is the feature vector
$g(w) = \frac{1}{N} \sum_{i=1}^n(y_i-w^Tx_i)^2 $
To this
$g(w) =…
Tam
- 15
0
votes
0 answers
Should I use all data to make predictions in least square method or would it be better part of the data?
Suppose I want to know the number of people infected by Covid-19 in a week and a month using least squares method, assuming the function to be approximated is such that F(t) is the number of people infected in day t, and t is always >= 0.
Should I…
Gabriel
- 1
0
votes
1 answer
How to translate least mean square regression equation to prercentage
Suppose that I have temperatures (T1) in x-axis and temperatures' frequencies (F1) in y-axis. So, that for each of the 10 temperatures in x-axis I get related frequencies in y-axis. I have also temperatures (T2) in another graph (in x-axis) and…
just_learning
- 117