Code and Equations for Kinetic Model of Psbs-Dependent Nonphotochemical Quenching
There are two versions of the GUI file with different visual formatting: GUIthylakoidSim_OSX.m, formatted for OS X on the Mac, and GUIthylakoidSim_Windows.m, formatted to look good on Windows. Their functionality should be the same. To run the GUI, run one of these two files, which are contained in the zipped code.
This page and all the linked code was generated using the publish command in MATLAB. The M-code can be retrieved from the html pages using the command grabcode.
This site contains the code for the model of rapidly-reversible nonphotochemical quenching described in the manuscript "A Kinetic Mode of PbsS-Dependent Nonphotochemical Quenching" by Julia Zaks, Kapil Amarnath, David Kramer, Krishna Niyogi, and Graham Fleming.
The simulations portions of Figures 4-6 in the paper can be generated using the scripts
In order to run the scripts, it is necesary to generate the variable samplepam using the script PamSim.
The differential equations for each module (F_1-F_8, described in the Supplementary information) are contained in the following functions
In order to evaluate values such as the pH gradient, chemical potential gradient, and transmembrane electric field, which are quantities that are not differential equations themselves, these functions call
1. Setting up Input
To run a simulation, it is necessary to specify the intensity of light that is input to the model and and the duration of light. These need to be specificed in the variables LightIntensity and durat. The light intensity sequence for a PAM trace can be set up with setupPAMIntensities.
2. Running model
chloroplastSim takes a series of light intensities and durations, and sequentially calls
runChloroplastSim, which simulates the variables for a single light intensity. The initial conditions for each section are the final values for the previous section. This function calls the differential equation solver (usually ode15s) and evaluates the differential equations for each module by calling them with the function evolveVars
the function chloroplastSim stitches together the simulations from the different light intensities and returns a struct containing the simulated values, the parameters for the simulation, and auxiliary information.
3. Plotting Resuts
plotvar plots an individual variable for which there is an explicit differential equation
plotStaticVals plots several specific variables.
plotallvars plots all the simulated variables.
plotFlux plots the flux of a given variable by plotting the rate of change from all the different modules that affect that variable.
To calculate NPQ-related parameters, the function getChlorophyllkRates calculates the rates of various quenching pathways for chlorophyll.
4. Example functions
PamSim simulates PAM fluorescence experiment. It is used to generate the data in the paper.
The sequence of light intensities used to simulate PAM fluorescence measurements are set up in the script initChloroplastSim.
Any published result that uses this code should cite the paper.