matlab有约束多元函数极值问题f=a*x^2+b*y^2+c*z^2,x+y+z=1,0

问题描述:

matlab有约束多元函数极值问题
f=a*x^2+b*y^2+c*z^2,x+y+z=1,0

令h=ax^2+by^2+cz^2+λ(x+y+z-1),则ðh/ðx=2ax+λ、ðh/ðy=2by+λ、ðh/ðz=2cz+λ,令ðh/ðx=ðh/ðy=ðh/ðz=0,得x=-λ/(2a)、y=-λ/(2b)、z=-λ/(2c)...