global ny nu yrls urls w A B ypast uopt  beta P K nu ny ymean umean ymstore umstore EthInEth PropInProp PropInBot ReboilRatio EthaneFlow PropaneFlow

%Initialize data
upast=zeros(50,1);
ypast=zeros(50,1);
delta_u=zeros(50,1);
yrls=[];
urls=[];
ymean=[0.9717;0.9654;8.9e-5];
umean=[0.4722;0.3611;0.934];
ymstore=[];
umstore=[];
EthInEth=[];
PropInProp=[];
PropInBot=[];
ReboilRatio=[];
EthaneFlow=[];
PropaneFlow=[];
ExitFlag=[];

%Startvalues for the model. Updates by RLS

A=[ 1.0000         0         0   -1.6900    0.2388    0.0595    0.6971  -0.2364   -0.0571
         0    1.0000         0    0.0251   -1.9607    0.0451   -0.0256   0.9633   -0.0429
         0         0    1.0000    0.1511    0.0849   -1.6938   -0.1500  -0.0797    0.6990];
      
B=[0         0         0    0.0179    0.0055   -0.0967    0.0032  -0.0023    0.1440   -0.0029   -0.0018   -0.0362    0.0011   -0.0004  -0.0148
   0         0         0    0.0008    0.0001    0.0037    0.0004  -0.0005   -0.0005   -0.0005    0.0001   -0.0054    0.0007    0.0002   0.0010
   0         0         0    0.0009    0.0009   -0.0235    0.0049  0.0002     0.0353    0.0003   -0.0007   -0.0132    0.0040    0.0000   0.0005];


   
   