Class DistillationColumnMatrixSolver

java.lang.Object
neqsim.process.equipment.distillation.DistillationColumnMatrixSolver

public class DistillationColumnMatrixSolver extends Object
A matrix-based solver for DistillationColumn using the Inside-Out algorithm approach. This solver uses a tridiagonal matrix algorithm (TDMA) to solve component material balances.
  • Field Details

    • logger

      static org.apache.logging.log4j.Logger logger
    • column

      private DistillationColumn column
    • nTrays

      private int nTrays
    • nComps

      private int nComps
    • componentNames

      private String[] componentNames
    • liquidPhaseIndices

      private int[] liquidPhaseIndices
    • gasPhaseIndices

      private int[] gasPhaseIndices
    • maxIterations

      private int maxIterations
    • tolerance

      private double tolerance
    • dampingFactor

      private double dampingFactor
    • prevError

      private double prevError
    • A

      private double[] A
    • B

      private double[] B
    • C

      private double[] C
    • D

      private double[] D
    • c_prime

      private double[] c_prime
    • d_prime

      private double[] d_prime
    • x_tdma

      private double[] x_tdma
    • feedFlows

      private double[][] feedFlows
    • feedVapor

      private double[] feedVapor
    • feedLiquid

      private double[] feedLiquid
  • Constructor Details

    • DistillationColumnMatrixSolver

      public DistillationColumnMatrixSolver(DistillationColumn column)
  • Method Details

    • solve

      public void solve(UUID id)
    • updatePhaseIndices

      private void updatePhaseIndices()
    • solveComponentBalances

      private double[][] solveComponentBalances()
      Solves the tridiagonal matrix for each component to find liquid molar flow rates. Returns x[tray][component] (liquid mole fractions) or l[tray][component] (molar flows). Let's return molar flows l[tray][component].
      Returns:
      liquid molar flow rates as l[tray][component]
    • solveTDMA

      private void solveTDMA(int n)
    • updateCompositionsAndFlows

      private void updateCompositionsAndFlows(double[][] l_flows)
    • getFeedFlowVapor

      private double getFeedFlowVapor(int trayIndex)
    • getFeedFlowLiquid

      private double getFeedFlowLiquid(int trayIndex)
    • getFeedFlow

      private double getFeedFlow(int trayIndex, int componentIndex)
    • updateTemperaturesAndEnergy

      private double updateTemperaturesAndEnergy()