


d   = 0.01;
Ytot= [1500, 1000];
kd= 1;
kp = 200;
k =1;

% Plot the output Yp vs input function 

vs = linspace (0, 5) 
ks = 5.*vs


Ypt1 = (ks/kd)*(kp+kd)/k;
Ypt2 = (ks/kd)*(kp+kd)/k;

for i=1:length(Ypt1) 
   if (Ypt1(i) >= Ytot(1)) 
       Ypt1(i) = Ytot(1);
   end
   if (Ypt2(i) >= Ytot(2)) 
       Ypt2(i) = Ytot(2);
   end
end
    
    
figure(1) 
plot(vs, Ypt1, '-r','LineWidth', 1.5)
hold on 
plot(vs, Ypt2, '-ob','LineWidth', 1)
ylim([0 1800])
xlabel('f(s), function of the input, s');
ylabel('Y_p, Output, phosphorylated protein ');
legend ('Y_T=1500', 'Y_T=1000')

