function [Xdot] = model2alt10_17(t,X)
C0_tetR =  10^-5   ;C0_araC = 10^-5  ;
n_pBad = 2.8; n_pTet = 1;

kors = 1e-3;
kofrs = 0.3e-9;% approximation from kofrs/kors = .32 uM, source: Gallivan et al. 

Kd_pTet = 3.83*10^-9; %(uM) source: openwetware supplemental materials 
Kd_pBad = .09*10^-3;%(uM) source: openwetware supplemental materials

C_tetR = (C0_tetR) * (X(8)^n_pTet/ (Kd_pTet^n_pTet + X(8)^n_pTet));
C_araC = (C0_araC) * (X(7)^n_pBad / (Kd_pBad^n_pBad + X(7)^n_pBad));
Cf_tetR = C0_tetR - C_tetR;
Cf_araC = C0_araC - C_araC;

K1_pBad = 0.009; K1_pTet = 350; K2_pBad = 37.5/C0_araC; K2_pTet = 160/C0_tetR; K3_pBad = 3.4/C0_araC; 

PBad = (K1_pBad + Kd_pBad*C_araC)/ (1+K1_pBad+K2_pBad*C_araC+K3_pBad*Cf_araC);
PTet = K1_pTet / (1+K1_pTet+2*K2_pTet*Cf_tetR+(K2_pTet^2)*(Cf_tetR^2));
Ptbs = 1 / (1 + X(3)/X(10));

tc_rsTAL = .01; tl_rsTAL = .02;%source: bionumbers
tc_GFP = .03;  tl_GFP = .06;%source: bionumbers
mRNAdeg = .0017; %assuming 10 minutes to degrade
protdeg_TAL = .000056;
protdeg_GFP = .0002;%assuming 140 minutes to degrade with LVA tag
mat = .00067; %GFP maturation rate (20-30 minutes)
Xdot(1) = tc_rsTAL*PBad - mRNAdeg*X(1);%riboswitch_TAL mRNA
Xdot(2) = kors*X(1)*X(9)-kofrs*X(2) ; %active riboswitch_TAL mRNA
Xdot(3) = tl_rsTAL*X(2) - protdeg_TAL*X(3); %TAL protein 
Xdot(4) = tc_GFP*PTet*Ptbs - mRNAdeg*X(4); %GFP mRNA
Xdot(5) = tl_GFP*X(4) - protdeg_TAL*X(5)-mat*X(5);%GFP intermediate
Xdot(6) = mat*X(5) - protdeg_GFP*X(6); %GFP protein
Xdot(7) = 0; %[ara]
Xdot(8) = 0; %[aTC]
Xdot(9) = 0; %[theo]
Xdot(10) = 0; %Kd tbs, source: Meckler et al

Xdot = Xdot';
end



