⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ftp269.m

📁 基于matlab的约束非线性规划算法库
💻 M
字号:
function [f, J] = ftp269(x, ctrl)
%Call: [f J]=ftp269(x,ctrl)
%Evaluate the residuals corresponding
%to the objective in a nonlinear lsq problem.
%If ctrl>0 the Jacobian J is computed analytically.
%Objective: 0.5*norm2(f)
%The problem is defined as
%  min 0.5*norm2(f(x))
%      s.t. c(x)=0
%where
%c(1)=x(1)+3*x(2);
%c(2)=x(3)+x(4)-2*x(5);
%c(3)=x(2)-x(5);
%
f(1)=x(1)-x(2);
f(2)=x(2)+x(3)-2;
f(3)=x(4)-1;
f(4)=x(5)-1;
f=f(:);
%The Jacobian is set to the empty matix to indicate that it should
%be computed using forward differences
J=[];

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -