Class GibbsReactor.GibbsComponent

java.lang.Object
neqsim.process.equipment.reactor.GibbsReactor.GibbsComponent
Enclosing class:
GibbsReactor

public class GibbsReactor.GibbsComponent extends Object
Inner class representing a component in the Gibbs reaction database.

Each GibbsComponent stores thermodynamic properties needed for Gibbs energy calculations:

  • Elemental composition (O, N, C, H, S, Ar, Z)
  • Heat capacity polynomial coefficients (A, B, C, D)
  • Standard formation properties at 298.15 K (ΔHf°, ΔGf°, ΔSf°)
  • Optional polynomial coefficients for direct Gibbs/enthalpy calculations
Version:
$Id: $Id
Author:
Sviatoslav Eroshkin
  • Field Details

    • molecule

      private String molecule
    • elements

      private double[] elements
    • heatCapacityCoeffs

      private double[] heatCapacityCoeffs
    • deltaHf298

      private double deltaHf298
    • deltaGf298

      private double deltaGf298
    • deltaSf298

      private double deltaSf298
    • coeffAg

      private double coeffAg
    • coeffBg

      private double coeffBg
    • coeffCg

      private double coeffCg
    • coeffDg

      private double coeffDg
    • coeffEg

      private double coeffEg
    • coeffFg

      private double coeffFg
    • coeffAh

      private double coeffAh
    • coeffBh

      private double coeffBh
    • coeffCh

      private double coeffCh
    • coeffDh

      private double coeffDh
    • coeffEh

      private double coeffEh
    • coeffGh

      private double coeffGh
  • Constructor Details

    • GibbsComponent

      public GibbsComponent(String molecule, double[] elements, double[] heatCapacityCoeffs, double deltaHf298, double deltaGf298, double deltaSf298, double coeffAg, double coeffBg, double coeffCg, double coeffDg, double coeffEg, double coeffFg, double coeffAh, double coeffBh, double coeffCh, double coeffDh, double coeffEh, double coeffGh)
      Constructs a GibbsComponent.
      Parameters:
      molecule - the molecule name
      elements - array of element counts
      heatCapacityCoeffs - array of heat capacity coefficients
      deltaHf298 - standard enthalpy of formation at 298 K
      deltaGf298 - standard Gibbs energy of formation at 298 K
      deltaSf298 - standard entropy at 298 K
      coeffAg - coefficient Ag for Gibbs calculations
      coeffBg - coefficient Bg for Gibbs calculations
      coeffCg - coefficient Cg for Gibbs calculations
      coeffDg - coefficient Dg for Gibbs calculations
      coeffEg - coefficient Eg for Gibbs calculations
      coeffFg - coefficient Fg for Gibbs calculations
      coeffAh - coefficient Ah for Gibbs calculations
      coeffBh - coefficient Bh for Gibbs calculations
      coeffCh - coefficient Ch for Gibbs calculations
      coeffDh - coefficient Dh for Gibbs calculations
      coeffEh - coefficient Eh for Gibbs calculations
      coeffGh - coefficient Gh for Gibbs calculations
  • Method Details

    • getDeltaSf298

      public double getDeltaSf298()
      Get the entropy of formation at 298K (deltaSf298) in J/(mol·K).
      Returns:
      Entropy of formation at 298K
    • getMolecule

      public String getMolecule()
    • getElements

      public double[] getElements()
    • getHeatCapacityCoeffs

      public double[] getHeatCapacityCoeffs()
    • getDeltaHf298

      public double getDeltaHf298()
    • getDeltaGf298

      public double getDeltaGf298()
    • calculateGibbsEnergy

      public double calculateGibbsEnergy(double temperature, int compNumber)
      Calculates Gibbs energy for a component.
      Parameters:
      temperature - temperature in K
      compNumber - component index
      Returns:
      Gibbs energy
    • calculateCorrectedHeatCapacityCoeffs

      public double[] calculateCorrectedHeatCapacityCoeffs(int compNumber)
      Calculate corrected heat capacity coefficients dA, dB, dC, dD by subtracting elemental contributions. dA = A - nO*AO - nN*AN - nC*AC - nH*AH - nS*AS
      Parameters:
      compNumber - component index
      Returns:
      array of corrected coefficients [dA, dB, dC, dD]
    • calculateJ

      public double calculateJ(int compNumber)
      Calculate the corrected formation enthalpy term J. J = ΔH°f - ΔA*TR - ΔB/2*TR² - ΔC/3*TR³ - ΔD/4*TR⁴ where TR is the reference temperature and ΔA, ΔB, ΔC, ΔD are corrected heat capacity coefficients.
      Parameters:
      compNumber - component index
      Returns:
      corrected formation enthalpy term J
    • calculateI

      public double calculateI(int compNumber)
      Calculate the I term for thermodynamic calculations. I = (1/R) × [J/TR + ΔA×ln(TR) + ΔB/2×TR + ΔC/6×TR² + ΔD/12×TR³] where R is the gas constant, TR is the reference temperature, and J is the corrected formation enthalpy term.
      Parameters:
      compNumber - component index
      Returns:
      the I term
    • calculateEnthalpy

      public double calculateEnthalpy(double temperature, int compNumber)
      Calculates enthalpy for a component.
      Parameters:
      temperature - temperature in K
      compNumber - component index
      Returns:
      enthalpy
    • calculateEntropy

      public double calculateEntropy(double temperature, int compNumber)
      Calculates entropy for a component.
      Parameters:
      temperature - temperature in K
      compNumber - component index
      Returns:
      entropy in J/(mol·K)
    • calculateHeatCapacity

      public double calculateHeatCapacity(double temperature, int compNumber)
      Calculates heat capacity for a component.
      Parameters:
      temperature - temperature in K
      compNumber - component index
      Returns:
      heat capacity in J/(mol·K)