function [Gred Tl Tr] = model_baltrunc(order)
% function [Ared Bred Cred Dred Tl Tr] = model_baltrunc(order)

% Get the LV-configurated column at Muske&Badgwells operating point,
% linearize and make a reduced model.

[t,x] = ode15s('cola_lv',[0 20000],0.5*ones(1,82)');
lengthx = size(x); Xinit = x(lengthx(1),:)';

% Linearisation using 'cola_linearize'
Ls = 1.87; Vs = 2.37; Ds = 0.5; Bs = 0.5; Fs = 1.0; zFs = 0.5;
[A,B,C,D] = cola_linearize('cola_lv_lin',Xinit',[Ls Vs Fs zFs]);

% Model reduction using the function baltrunc (tailor-made)
Gfull = ss(A,B,C,D);
[Gred Tl Tr] = baltrunc(Gfull,order);
[Ared Bred Cred Dred] = deal(Gred.a,Gred.b,Gred.c,Gred.d);
