How to solve 4 nonlinear equations (in 4 unknowns) ITERATIVELY

8 visualizzazioni (ultimi 30 giorni)
Please help me in solving 4 nonlinear equations ITERATIVELY...
a1, b1, c1 d1, a2, b2, c2, d2, a3, b3, c3, d3, a4, b4, c4, d4, k1, k2, k3 all are known
*I know how to solve them using solve command to get just a single solution*

Risposta accettata

Andrei Bobrov
Andrei Bobrov il 19 Nov 2011
a = rand(4);
a(1,end) = 1;
f1 = @(x)sum(bsxfun(@minus,a(:,1:end-1),reshape(x(1:end-1),1,[])).^2,2) - a(:,end)*(x(end)^2);
x = fsolve(f1,randi(12,4,1));
  3 Commenti
manish sharma
manish sharma il 29 Nov 2011
BTW I got the desired results by using Newton Raphson method for solving a sysytem of non linear equations.

Accedi per commentare.

Più risposte (1)

Nuno il 7 Mag 2015
Modificato: Nuno il 7 Mag 2015
this can be applied to this I have x1,y1,z1,x2,y2,z2,x3,y3,z3,x4,y4,z4
I need to get x0,y0,z0 and r.
I applied that code and the results are very weird

Community Treasure Hunt

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

Start Hunting!

Translated by