www.gusucode.com > mbcdesign 工具箱 matlab 源码程序 > mbcdesign/@conlinear/pslGetParameters.m
function ud = pslGetParameters(con) %PSLGETPARAMETERS Get parameters required for Simulink version of constraint. % % UD = PSLGETPARAMETERS(CON) % % See also CONLINEAR, % CONBASE/SLSETPARAMETERS, % CONBASE/PSLGETPARAMETERS. % Copyright 2005 The MathWorks, Inc. % Scale factor cif = getActiveFactors( con ); D = diag( 0.5 * (cif.Max - cif.Min) ); sc = 1/sqrt( sum( (con.A * D).^2, 2 ) ); % Set up parameters ud = struct( ... 'A', con.A, ... 'b', con.b, ... 'Scale', sc ); %------------------------------------------------------------------------------| % EOF %------------------------------------------------------------------------------|