evolveVars

Contents

evolves all the variables in the fields of input struct x. Gets called from runChloroplastSim

function dx=evolveVars (currentValues, x, params,simparams, ...
    LightIntensity, quenchmodel )

Identify modules

models are in fields of input struct x

varsInSimulation=fields(x);
for k=1:length(varsInSimulation)
    %use function specified to propagate module j that is specified in
    %initialization file

Get inputs for function simparams.function.(varsInSimulation{k}) using function getInputs

    inputs.(varsInSimulation{k})=getInputs(currentValues,...
        varsInSimulation{k}, simparams, LightIntensity, quenchmodel);
    % Evaluate differential equation for module k using function contained
    % in the handle |simparams.function.(varsInSimulation{k})|
    dx.(varsInSimulation{k})=...
        simparams.function.(varsInSimulation{k})(x.(varsInSimulation{k}),...
        inputs.(varsInSimulation{k}), params);
end
end

currently, the possible modules are

%