if (initialAssignment.isSetVariable()) {
String variableID = initialAssignment.getVariable();
Compartment compartment = model.getCompartment(variableID);
Species species = null;
SpeciesReference speciesReference = null;
Parameter parameter = null;
if (compartment == null) {
species = model.getSpecies(variableID);
if (species == null) {
parameter = model.getParameter(variableID);
if (parameter == null) {
if (model.isSetListOfReactions()) {
int i = 0;
SpeciesReference sr = null;
while (i <= model.getNumReactions() - 1
&& sr == null) {
Reaction reaction = model.getReaction(i);