Does "fsolve" still avaliable for sloving the nonlinear equation?

1 vue (au cours des 30 derniers jours)
Mark
Mark le 25 Mai 2021
I would like to slove the nonlinear equation above and I use matlab to code below but the command window showed: Undefined function 'fsolve' for input arguments of type 'function_handle'.
How should I use the fsolve function or is there any other way to solve these nonlinear equation?
Thank you very much!
clc; clear;
f=@(x) [2.*x(1)-x(2)-exp(-x(1));-x(1)+2.*x(2)-exp(-x(2))];
fsolve(f,[-5,-5])

Réponse acceptée

Sulaymon Eshkabilov
Sulaymon Eshkabilov le 25 Mai 2021
Hi,
In order to employ fsolve() function, you should have optimization toolbox installed in your computer.
fsolve is part of optimization toolbox and thus, you have gotten such an error message.
  2 commentaires
Mark
Mark le 25 Mai 2021
After I install the optimization toolbox, it works! Thanks a lot!!
Sulaymon Eshkabilov
Sulaymon Eshkabilov le 26 Mai 2021
Most welcome! It is a pleasure to help.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Introduction to Installation and Licensing dans Help Center et File Exchange

Tags

Produits


Version

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by