
% Generate steady-state data for column A
% Saves data in file multicom_init.mat

%% Do this by simulating 20000 min with stabilized LV-model:

clear all
NT=48;
NF=20;
NC=5;
X0=[0.0182*ones(NT,1);0.5798*ones(NT,1);0.0943*ones(NT,1);0.1895*ones(NT,1);38; ones(NF-1,1)*3.55;ones(NT-NF-1,1)*3.68;227];
[t,x]=ode15s('multicomAP_lv',[0 20000],X0);

%Xinit = x(sel(size(x),1,1),:)';
lengthx=size(x); Xinit = x(lengthx(1),:)';

% Nominal inputs
%LT=42.7;                       % Reflux kmol/min
LT=27.1;                        % Reflux kmol/min new
%VB=32.3;                          % Boilup
VB=33.865;
% D=25.9;                              % Distillate
%D=21.1;                                 % Distillate new
D=17.8;
%B=14.1;                               % Bottoms
%B=8.3;                                 % Bottoms new
B=11.6;
F=29.4;                           % Feedrate
qF=0.645;                              % Feed liquid fraction
zF=[0.01817636 0.57980319 0.09425689 0.18950644 0.11825622];% Feed compositions for component A to component NC 
Uinit = [ LT VB D B F qF zF]';

clear x; clear t; clear LT; clear VB; clear D; clear B;
clear F; clear zF; clear qF;

save multicom_init  % saves in cola_init.m


