Need help with a system non-linear equation with three variables

1 vue (au cours des 30 derniers jours)
Tanay Tayade
Tanay Tayade le 3 Mar 2024
I have a set of data:
x (array) containing as many data points as we want (known to user)
y (array) containing as many data points as x (also known)
and corresponding set of X (array) and Y (array) (both known).
Now using these arrays, we can frame the following expressions:
(we can get as many set of expressions for Rx and Ry as many data points we've considered for x, y, X, Y)
Note that the other variables (d, phi2, theta2) are also known.
Using this expressions, i want to find the value of theta, phi and psi for which:
theta can take values from [0,360], psi from [0,360], and phi from [0,90] (in degrees)
There can be multiple solutions.

Réponses (1)

John D'Errico
John D'Errico le 3 Mar 2024
Simple. Use lsqnonlin.
There will almsot certainly be no exact solution. All you can do is find a parameter set that minimizes the sum of squares of the difference, i.e., lsqnonlin.
Yes, there will ALWAYS be multiple colutions, since this is a trig problem, and therefore infinitely many equivalent solutions.


En savoir plus sur Systems of Nonlinear Equations 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