Class Reagent


public class Reagent extends ChemicalEntity
Chemical entity that represents a reagent of a reaction.
  • Constructor Details

    • Reagent

      public Reagent(String name, int coefficient, Phase phase)
      Initializes a Reagent.
      Parameters:
      name - Name of the reagent, that corresponds to the name of a chemical species in the chemical system.
      coefficient - Stoichiometric coefficient associated to this reagent in a reaction.
      phase - Phase of the reagent.
  • Method Details

    • getCoefficient

      public int getCoefficient()
      Gets the stoichiometric coefficient associated to this reagent.

      By convention, negative coefficients are associated to products, and positive coefficients are associated to reactants.

      Returns:
      stoichiometric coefficient
    • setCoefficient

      public void setCoefficient(int coefficient)
      Sets the stoichiometric coefficient associated to this reagent.

      By convention, negative coefficients are associated to products, and positive coefficients are associated to reactants.

      Parameters:
      coefficient - stoichiometric coefficient