os = 10;
kd = 0.2;
ka = 0.8;
ks = 0.06;
L0 = 50;
Sb = 1;

y = @(t) os - ((kd*L0)/(kd + ks - ka))*(exp(-ka*t) - exp(-(kd + ks)*t)) - (Sb/ka)*(1-exp(-ka*t));

t = golden(-100, 100, y);

j = os - ((kd*L0)/(kd + ks - ka))*(exp(-ka*t) - exp(-(kd + ks)*t)) - (Sb/ka)*(1-exp(-ka*t));

disp(['The minimum oc is ', num2str(j), ' and it occurs at time ', num2str(t)]);