Control number of states in matlab linear analysis tool

603 views Asked by At

I am linearizing a simulink model with 3 inputs and 6 outputs using MATLAB linear analysis tool. It includes an integrator which transfers all my 6 states which are: Roll, Rolldot, Pitch, Pitchdot, Yaw, and Yawdot.

The problem is that the linearized system includes only 3 states which is contrary to what I want to model. This is seemingly done by the BlockReduction option in the linearize command. I'm wondering if there is a way that I can tell the linear analysis tool not to minimally realize my system. I haven't tried using command syntax, but I figure that it can be done that way.

1

There are 1 answers

2
am304 On

I can't remember if there is an option in the linearisation tool (GUI) to turn off the Block Reduction, but there is definitely a way to do this using the command line version, see linearizeOptions:

sys = 'watertank';
load_system(sys);
opspec = operspec(sys);
op = findop(sys,opspec);
sys_io(1)=linio('watertank/PID Controller',1,'input');
sys_io(2)=linio('watertank/Water-Tank System',1,'openoutput');
options = linearizeOptions('BlockReduction','off'); % add other options as required
linsys = linearize(sys,op,sys_io,options); 
bdclose(sys);