Solving a linear equation using least-squares (Calibration Matrix)

2 views (last 30 days)
Hi,
I need to find the calibration matrix C and offset A in the equation:
F = A + CX
F is a [2x1] vector and X is [3x1] vector. These are known from experimental data.
The offset vector A is [2x1] and the calibration matrix C is [2x3].
I have multiple data such that F becomes a matrix of size [2xn] and X becomes a matrix of size [3xn].
I need to find a way to approximate matrices A and C using a least-squares approach.
It is not clear to me how to proceed however.
Thanks!

Accepted Answer

Matt J
Matt J on 8 May 2019
W=[ones(1,n);X];
Z=F/W;
A=Z(:,1);
C=Z(:,2:end);
  1 Comment
Omar Alahmad
Omar Alahmad on 9 May 2019
Thanks Matt, it seems to have done the job. Although I still do not have a complete understanding of how it worked. I will have to look a bit further.

Sign in to comment.

More Answers (1)

Matt J
Matt J on 8 May 2019
Edited: Matt J on 9 May 2019
Are these equations for projective transformations? If so, they are not really linear equations. They are accurate only up to some multiplicative factor. You would need to use methods from projective geometry like the DLT to solve it,

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!