The Genesis of Helper T cells and the Self-Nonself Time Model of Immune Regulation

Calculating the parameters and boundary conditions for the antigen-independent pathway for the origin of effector T-helpers

This program calculates the resulting immune system cell types from any choice of rate constants, in a time step model.

Link to Math details.

Program Instructions:

What is it?

This time step model program of T helper genesis program is an improvement from the limitations in the steady state Th genesis Minimal Model program found at While the Minimal Model produced final steady state solutions to the immune system, the immune system is far from an instantly steady state system. This program will simulate the immune system in a step by step process. The rules of the system are calculated for each time step to give a new system state. The accumulation of this data can then show how the system behaves over time, including when a steady state is reached as the consecutive steps converge to a steady state value. This process gives the user enough data to be able to see how each cell type (self and nonself) responds in the absence and then presence of foreign antigen. Note that self-antigen is always present.

Cell States:

As Anticipatory Self
Is Initial Self
Es Effector Self
Anse Anticipatory Nonself Engaged by antigenic Load
Inse Initial Nonself Engaged by antigenic Load
Ense Effector Nonself Engaged by antigenic Load
Insu Initial Nonself Unengaged
Ensu Effector Nonself Unengaged


Cells are initially produced by the thymus to seed the system in the specified number of steps. In addition, the thymus also produces new replacement cells for those that have gone to death. The conversion of cells, from one state to another, depends on k2, k3, k4, k5, k6 and k7 rates, as well as interaction with APCs (antigen presenting cells) and antigen.

Note that k7 is an autocatalytic reaction which also interacts with APCs. This is true for both the self and nonself pathways. The working range of k7 can vary considerably, by a factor of 10-100 by an introduction or removal of an effector cell division.

For more math details see the link above at the top of this page.

Self and Nonself Antigen:

Self-antigen is always present in this model. New anti-self and anti-nonself Th cells are constantly generated by the thymus. The proportion of these new cells which are anti-self or anti-nonself cells is determined by SI and (1-SI) respectively. SI is one of the input variables of the program.

The user may also specify the number of steps to perform before the addition of nonself antigen at the specified Load (L). On the program page, this is asked as the number of steps to perform BEFORE addition of the Load. It is important to note that there is another parameter ‘the number of steps in which the system in seeded’ or created, which should be less than the number of BEFORE steps. The system needs to grow gradually, and reach its final Protecton size (T) before nonself antigen is presented. If seeding occurs in a very short period of time, there is a high probability that too many new cells will be anti-self, and a sustained autoimmunity will occur. Therefore the system needs to grow gradually to the specified total system size.

Nonself antigen is added after the number of BEFORE steps. The program then continues to apply the system rules for another AFTER steps. Keep in mind that the nonself antigen is not automatically removed once it has been introduced. This can cause the nonself engaged cells (Inse, Anse, and Ense) to wash out all other cell types in the system. However, this also can also lead to autoimmunity -- as the large number of nonself engaged cells also turn over and die, the thymus replaces them with new anti-self and anti-nonself cells. If the influx of anti-self cells occur at a high rate where they also have a high probability to interact with APCs presenting self, an autoimmune responce occurs.

Option (A) of the program allows the user to specify the step number to remove the non-self antigen. The default value of 1e10, in essence places the removal process far into the future, out of our experimental time frame. A reasonable real life situation may be more in the area of removal at step 1030, or 30 steps (@5hr/step = 150hrs = 6.3 days) after addition of nonself antigen.

Option (B) allows the program to simulate linked recognition of Ense and As, and similarly Es and Anse, affecting the k7 pathway. The major effect of this option is that a nonself antigen affects the self autocatalytic pathway, which can lead to specific autoimmunity under certain conditions. When this option is used, all self, and all nonself are involved in linked recognition. Therefore using a small number of peptides for SI and Load (L) are recommended. A Load = SI = (1/R) = (1e-5, using our default R) results in 1 self and 1 nonself peptide.

Option (C) is a method by which the user can investigate how the system responds to an elevated level of anti-self cells. The program user can inject any number of Effector anti-Self cells at any point in the model and see how the system reacts. Generally, there will be a threshold, were below it, the cells will simply turn over and dissipate. However, above a certain threshold of around 10 effectors/peptide, a sustained autoimmune reaction may occur.

Steps vs. Time:

Currently the program calculates data in terms of steps. It is up to the individual user to define how much real time equals 1 time step. If the average time for a cell type to change to a different cell type or to go to cell death is 4hrs, then 1 step will equal 4hrs. Thus one day would equal 24hr * (1step/4hr) = 6 steps. Likewise, if cell conversion is slower say 6hrs, then there will be 4 steps per day. In addition if you are including cell divisions in the model, you must consider the time it takes for a cell division relative to the amount of time that is represented by 1 step. For example, if we say a cell division takes 12 hrs, then using 4hr/step it will take 3 steps to divide, whereas using 6hr/step will take 2 steps for a cellular division.

Effector cells may go through X number of divisions, each of which is delayed by Y number steps. For example, a cell in the Anticipatory state converting to an effector state cell will occur in 1 step and then perform a cell division Y steps later (1 new cell added), and possibly another cell division after another Y steps (2 new cells added). Note that in order to maintain the Total number of cells in the system constant, cells are removed from the Insu group.


Default input values are provided to illustrate what appears to be acceptable output.

Graphing is available and is probably the easiest way to quickly view results. You can plot the number of cells in each state, k1*G = death = rebirth = turnover amount, PIE calculations, and the number of Es cells / self peptide, Ense cells / nonself peptide, and Ensu cells / nonself unengaged peptides.

Optionally, you may request Raw Data to be returned in a table, where you may look at the actual numbers, or copy and past it into your own spreadsheet. The size of the resulting page is proportional to the number of steps you ask the system to perform. This raw data in a table can get very large that some older web browsers cannot display it correctly. However, you may view the source of the page and grab the data from it, or optionally upgrade your browser.

Notes: One common mistake is to set graphing to use the log scale and then to set the "From" value to 0, it defaults to 1e-300, but try 1e-5 instead. Also if you are wondering where a graph line went, it may be hiding beneath a different line, in which case try graphing one line at a time. Another possibility is that it is outside the current graph scale in which case lower the minimum and increase the maximum. As a last resort you can always look at the raw data.

List of Abbreviations within graphs:

Seed # of steps to grow/seed the simulator from 0 to the total simulation size (T)
Before # of steps to simulate before addition of nonself antigen
After # of steps to simulate after addition of nonself antigen
XRxn Nonself antigen shares epitopes with self.  0 = no, 1 = yes
EDivs # of divisions of a newly induced Ense
SEDivs # of steps for an Ense division
Total Total cells in simulation (T) or Protecton
RemL Step in which Nonself antigen is removed.
StepEs Step when Es is injected into the simulation.
AmtEs Amount of Es cells injected.
P Peptide, usually shown as /P meaning per peptide.



  Return to CIG Home Page