Effacer les filtres
Effacer les filtres

How do i write the code of lagrange multiplier in lagrange function?

8 vues (au cours des 30 derniers jours)
yang-En Hsiao
yang-En Hsiao le 24 Jan 2019
Modifié(e) : Taiwo Fasae le 12 Oct 2021
How do i write the code of lagrange multiplier in lagrange function ? Because the lagrange multiplier is a varible ,like x,y,z.not a random value,so for example,the function i want to optimize is as below
lagrange.PNG
then how do i write the matlab code of lagrage multiplier ? because there are lots of a_k and b_k,and they all should be calculated,so i can't just use "rand" to produce them.
Does anyone know how to write the code of this? or is there any reference i can refer?

Réponse acceptée

Stephan
Stephan le 24 Jan 2019
Hi,
here is an example, which you can use to learn how you can tackle this problem in Matlab:
Best regards
Stephan
  1 commentaire
Taiwo Fasae
Taiwo Fasae le 12 Oct 2021
Modifié(e) : Taiwo Fasae le 12 Oct 2021
I beg to differ. That link didn't lead to a solution for dealing with nonlinear constraints in langrange multipliers. Please show me one when you find it.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Problem-Based Optimization Setup 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