Skip to content

Commit

Permalink
altered transition rates in Gen Immunity script
Browse files Browse the repository at this point in the history
  • Loading branch information
Jack Chaillet committed Apr 28, 2022
1 parent 18fb624 commit 1924f32
Showing 1 changed file with 30 additions and 30 deletions.
60 changes: 30 additions & 30 deletions GeneralizedImmunityExp1.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ paramFile<-args[1]
No<-as.integer(args[2])
resultsFolder <-args[3]
jobid<-as.integer(args[4])
paramFile<-"ParamListGen.csv"
No<-3
resultsFolder<-"./"
#paramFile<-"ParamListGen.csv"
#No<-3
#resultsFolder<-"./"
outFile<-paste(resultsFolder,"/",strsplit(paramFile,split="[.]")[[1]][1],"_results.csv",sep="")

SEAI_p<-function(t,y,p){
Expand Down Expand Up @@ -65,22 +65,22 @@ SEAI_p<-function(t,y,p){
#transmissibility is reduced to the number of infected hosts,
#receiving hosts needs to have open "resource room" for accepting new strains
B_PW = b*(
eN*h_NU[1] +
eN*h_ND[1] +
eS*h_SU[1] +
eS*h_SD[1] +
eA*h_AU[1] +
eA*h_AD[1]
h_NU[1] +
h_ND[1] +
h_SU[1] +
h_SD[1] +
h_AU[1] +
h_AD[1]
)


B_PR = b*(
eN*h_NU[2]+
eN*h_ND[2]+
eS*h_SU[2]+
eS*h_SD[2]+
eA*h_AU[2]+
eA*h_AD[2]
h_NU[2]+
h_ND[2]+
h_SU[2]+
h_SD[2]+
h_AU[2]+
h_AD[2]
)


Expand Down Expand Up @@ -121,24 +121,24 @@ SEAI_p<-function(t,y,p){
infA = 1
#print(infN)
#naive class getting infected, and treated
NU2ND = (Bu*(1-rNU/capacity)*infN*d1)
NU2ND = rNU*(1/8)*d1

#naive U class getting enough # of infections to move to SU
#NU2SU = (Bu*(1-rNU/capacity)*rho1*1/((infN/(muWU_gen_N))+((1-infN))))
NU2SU = (rNU*muRU_gen_N)*rho1

#naive U class die from infections
NUInfDie = (Bu*(1-rNU/capacity)*infN*muWU_gen_N*muNU)
NUInfDie = rNU*muWU_gen_N*muNU

#naive D class getting enough # of infections to move to SD
#ND2SD = (Bd*(1-rND/capacity)*rho1*1/((infN/(muRU_gen_N))+((1-infN))))
ND2SD = (rND*muRD_gen_N)*rho1

#naive D class die from infections
NDInfDie = (Bd*(1-rND/capacity)*infN*muRD_gen_N*muND)
NDInfDie = rND*muRD_gen_N*muND

#SU class getting infected, show symptoms, and treated
SU2SD = (Bu*(1-rSU/capacity)*infS*d2)
SU2SD = (rSU*(1/8)*d2)

#SU class getting enough # of infections to move to AU
#SU2AU = (Bu*(1-rSU/capacity)*rho2*1/((infS/(muWU_gen_S))+((1-infS))))
Expand All @@ -149,7 +149,7 @@ SEAI_p<-function(t,y,p){
SD2AD = (rSD*muWD_gen_S)*rho2

#AU class getting infected, show symptoms, and treated
AU2AD = (Bu*(1-rAU/capacity)*infA*omega*d3)
AU2AD = (rAU*(1/8)*d3)



Expand Down Expand Up @@ -442,24 +442,24 @@ SEAI_resOnly<-function(t,y,p){
infA = 1
#print(infN)
#naive class getting infected, and treated
NU2ND = (Bu*(1-rNU/capacity)*infN*d1)
NU2ND = rNU*(1/8)*d1

#naive U class getting enough # of infections to move to SU
#NU2SU = (Bu*(1-rNU/capacity)*rho1*1/((infN/(muWU_gen_N))+((1-infN))))
NU2SU = (rNU*muRU_gen_N)*rho1

#naive U class die from infections
NUInfDie = (Bu*(1-rNU/capacity)*infN*muWU_gen_N*muNU)
NUInfDie = rNU*muWU_gen_N*muNU

#naive D class getting enough # of infections to move to SD
#ND2SD = (Bd*(1-rND/capacity)*rho1*1/((infN/(muRU_gen_N))+((1-infN))))
ND2SD = (rND*muRD_gen_N)*rho1

#naive D class die from infections
NDInfDie = (Bd*(1-rND/capacity)*infN*muRD_gen_N*muND)
NDInfDie = rND*muRD_gen_N*muND

#SU class getting infected, show symptoms, and treated
SU2SD = (Bu*(1-rSU/capacity)*infS*d2)
SU2SD = (rSU*(1/8)*d2)

#SU class getting enough # of infections to move to AU
#SU2AU = (Bu*(1-rSU/capacity)*rho2*1/((infS/(muWU_gen_S))+((1-infS))))
Expand All @@ -470,7 +470,7 @@ SEAI_resOnly<-function(t,y,p){
SD2AD = (rSD*muWD_gen_S)*rho2

#AU class getting infected, show symptoms, and treated
AU2AD = (Bu*(1-rAU/capacity)*infA*omega*d3)
AU2AD = (rAU*(1/8)*d3)

# Parasite pop ODE------
## sensitive-------
Expand Down Expand Up @@ -726,24 +726,24 @@ SEAI_wildOnly<-function(t,y,p){
infA = 1
#print(infN)
#naive class getting infected, and treated
NU2ND = (Bu*(1-rNU/capacity)*infN*d1)
NU2ND = rNU*(1/8)*d1

#naive U class getting enough # of infections to move to SU
#NU2SU = (Bu*(1-rNU/capacity)*rho1*1/((infN/(muWU_gen_N))+((1-infN))))
NU2SU = (rNU*muRU_gen_N)*rho1

#naive U class die from infections
NUInfDie = (Bu*(1-rNU/capacity)*infN*muWU_gen_N*muNU)
NUInfDie = rNU*muWU_gen_N*muNU

#naive D class getting enough # of infections to move to SD
#ND2SD = (Bd*(1-rND/capacity)*rho1*1/((infN/(muRU_gen_N))+((1-infN))))
ND2SD = (rND*muRD_gen_N)*rho1

#naive D class die from infections
NDInfDie = (Bd*(1-rND/capacity)*infN*muRD_gen_N*muND)
NDInfDie = rND*muRD_gen_N*muND

#SU class getting infected, show symptoms, and treated
SU2SD = (Bu*(1-rSU/capacity)*infS*d2)
SU2SD = (rSU*(1/8)*d2)

#SU class getting enough # of infections to move to AU
#SU2AU = (Bu*(1-rSU/capacity)*rho2*1/((infS/(muWU_gen_S))+((1-infS))))
Expand All @@ -754,7 +754,7 @@ SEAI_wildOnly<-function(t,y,p){
SD2AD = (rSD*muWD_gen_S)*rho2

#AU class getting infected, show symptoms, and treated
AU2AD = (Bu*(1-rAU/capacity)*infA*omega*d3)
AU2AD = (rAU*(1/8)*d3)

# Parasite pop ODE------
## sensitive-------
Expand Down

0 comments on commit 1924f32

Please sign in to comment.