📄 solvemp.m
字号:
function [mpsolution,diagnostic] = solvemp(F,h,ops,x)
%SOLVEMP Computes solution to multi-parametric optimization problem
%
% min_z(x) h(x,z)
% subject to
% F(x,z) > 0
%
%
% [MPSOLUTION, DIAGNOSTIC] = SOLVEMP(F,h,options,x)
%
% MPSOLUTION : Multi-parametric solution (see MPT toolbox)
%
% DIAGNOSTIC : struct with diagnostic information
%
% Input
% F : SET object describing the constraints.
% h : SDPVAR object describing the objective function h(x,z).
% options : solver options. See SDPSETTINGS. Can be [].
% x : Parametric variables
%
% See also SET, SDPSETTINGS, YALMIPERROR
% Author Johan L鰂berg
% $Id: solvemp.m,v 1.5 2004/07/06 14:09:02 johanl Exp $
if nargin~= 4
error('solvemp must always have 4 input arguments');
else
if ~isempty(ops)
if isequal(ops.solver,'')
ops.solver = 'mpt';
end
else
ops = sdpsettings('solver','mpt');
end
sol = solvesdp(F,h,ops,x);
mpsolution = sol.mpsol;
diagnostic = sol;
end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -