A simple error minimization (optimization) problem

6 vues (au cours des 30 derniers jours)
Ravi Challa
Ravi Challa le 16 Mai 2022
Commenté : Ravi Challa le 16 Mai 2022
I am trying to minimize the error between the calculated force from three different sensors and expected force from them.
The expected force data is given. The calculated force is well, calculated, and I have that data too.
Calculated force data:
P1, P2, and P3 are calculated force vectors (400x1 Double) who values I calculated from my code.
Expected force data:
L1, L2, and L3 are expected force vectors (400 x 1 double) whose values are provided.
Problem:
Ideally, the total calculated force (P1 + P2 + P3) should be equal to (L1 + L2 + L3).
In an ideal world that is not possible, so my goal is to minimize the error by identifying multiplication factors for P1, P2, and P3 so that the error can stay as minimum as possible.
Meaning, if we formulate a function F as ((C1*P1 + C2*P2 + C3*P3) - (L1 + L2 + L3)), how do I go about minimizing this difference by theoptimization technique? This problem might fall under the category of a simple linear optimization (?).
Note: C1, C2, and C3 are those multiplication factors that the optimization should provide (as an output) so as to keep the error as minimum as possible.
Goal:
Minimize the error F: ((C1*P1 + C2*P2 + C3*P3) - (L1 + L2 + L3)) <= 0 by figuring out C1, C2, and C3 as the output.
Any advice on which linear optimization tool to use would be an immense help and how to go about setting it up would be useful.
Thanks!

Réponse acceptée

Torsten
Torsten le 16 Mai 2022
Modifié(e) : Torsten le 16 Mai 2022
A = [C1,C2,C3];
b = L1+L2+L3;
C = A\b;
C1 = C(1)
C2 = C(2)
C3 = C(3)
  3 commentaires
Torsten
Torsten le 16 Mai 2022
You meant A = [P1,P2,P3] correct?
Correct.
Ravi Challa
Ravi Challa le 16 Mai 2022
Thanks!

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Nonlinear Optimization dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by