Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Jac=@(x)[2*x(1),2*x(1),1;2*x(2),2*x(2),1;2*x(3),-1,1];
- Fn=@(x)[x(1)^2+x(2)^2+x(3)^2-9;x(1)^2+x(2)^2-x(3)-1;x(1)+x(2)+x(3)-3];
- x=[-1;20;101];
- while 1
- dx=Jac(x)\Fn(x);
- if sum(abs(dx))<10e-5
- break
- end
- x=x+dx;
- end
- jacans=x;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement