diff --git a/src/main/java/neqsim/thermo/component/Component.java b/src/main/java/neqsim/thermo/component/Component.java index 7829144bd..a26e9864b 100644 --- a/src/main/java/neqsim/thermo/component/Component.java +++ b/src/main/java/neqsim/thermo/component/Component.java @@ -63,7 +63,7 @@ public abstract class Component implements ComponentInterface { protected double bCPA = 0.0; protected double mCPA = 0.0; protected double srkacentricFactor = 0.0; - // TODO: what are the available options here? + // TODO: what are the available options here? Can also see solute protected String referenceStateType = "solvent"; protected String associationScheme = "0"; protected String antoineLiqVapPresType = null; diff --git a/src/main/java/neqsim/thermo/component/ComponentBWRS.java b/src/main/java/neqsim/thermo/component/ComponentBWRS.java index 35179cc58..575afafc8 100644 --- a/src/main/java/neqsim/thermo/component/ComponentBWRS.java +++ b/src/main/java/neqsim/thermo/component/ComponentBWRS.java @@ -74,12 +74,12 @@ public ComponentBWRS(String name, double moles, double molesInPhase, int compInd * Constructor for ComponentBWRS. *
* - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentBWRS(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentCSPsrk.java b/src/main/java/neqsim/thermo/component/ComponentCSPsrk.java index bb537a45e..d3ef2d951 100644 --- a/src/main/java/neqsim/thermo/component/ComponentCSPsrk.java +++ b/src/main/java/neqsim/thermo/component/ComponentCSPsrk.java @@ -37,12 +37,12 @@ public ComponentCSPsrk(String name, double moles, double molesInPhase, int compI * Constructor for ComponentCSPsrk. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentCSPsrk(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentDesmukhMather.java b/src/main/java/neqsim/thermo/component/ComponentDesmukhMather.java index 5ed07b6dc..5ab49ccf1 100644 --- a/src/main/java/neqsim/thermo/component/ComponentDesmukhMather.java +++ b/src/main/java/neqsim/thermo/component/ComponentDesmukhMather.java @@ -58,7 +58,7 @@ public ComponentDesmukhMather(String name, double moles, double molesInPhase, in public double getGamma(PhaseInterface phase, int numberOfComponents, double temperature, double pressure, PhaseType pt, double[][] HValpha, double[][] HVgij, double[][] intparam, String[][] mixRule) { - // not implemented + // todo: not actually implemented return getGamma(phase, numberOfComponents, temperature, pressure, pt); } diff --git a/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPA.java b/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPA.java index cde183007..27516f205 100644 --- a/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPA.java +++ b/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPA.java @@ -67,12 +67,12 @@ public ComponentElectrolyteCPA(String name, double moles, double molesInPhase, i * Constructor for ComponentElectrolyteCPA. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentElectrolyteCPA(int number, double TC, double PC, double M, double a, double moles) { diff --git a/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAOld.java b/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAOld.java index 8405866e5..0b6edce44 100644 --- a/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAOld.java +++ b/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAOld.java @@ -65,12 +65,12 @@ public ComponentElectrolyteCPAOld(String name, double moles, double molesInPhase * Constructor for ComponentElectrolyteCPAOld. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentElectrolyteCPAOld(int number, double TC, double PC, double M, double a, double moles) { diff --git a/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAstatoil.java b/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAstatoil.java index 6d37cc2de..dce4d5b8f 100644 --- a/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAstatoil.java +++ b/src/main/java/neqsim/thermo/component/ComponentElectrolyteCPAstatoil.java @@ -33,12 +33,12 @@ public ComponentElectrolyteCPAstatoil(String name, double moles, double molesInP * Constructor for ComponentElectrolyteCPAstatoil. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentElectrolyteCPAstatoil(int number, double TC, double PC, double M, double a, double moles) { diff --git a/src/main/java/neqsim/thermo/component/ComponentEos.java b/src/main/java/neqsim/thermo/component/ComponentEos.java index c1beb1083..0c1ed82ff 100644 --- a/src/main/java/neqsim/thermo/component/ComponentEos.java +++ b/src/main/java/neqsim/thermo/component/ComponentEos.java @@ -104,12 +104,12 @@ public ComponentEos(String name, double moles, double molesInPhase, int compInde * Constructor for ComponentEos. * * - * @param number a int + * @param number a int. Not used. * @param TC Critical temperature * @param PC Critical pressure * @param M Molar mass * @param a Acentric factor - * @param moles Number of moles + * @param moles Total number of moles of component. */ public ComponentEos(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentGERG2004.java b/src/main/java/neqsim/thermo/component/ComponentGERG2004.java index 18ae7d720..d35ea424c 100644 --- a/src/main/java/neqsim/thermo/component/ComponentGERG2004.java +++ b/src/main/java/neqsim/thermo/component/ComponentGERG2004.java @@ -32,12 +32,12 @@ public ComponentGERG2004(String name, double moles, double molesInPhase, int com * Constructor for ComponentGERG2004. * * - * @param number a int + * @param number a int. Not used. * @param TC Critical temperature * @param PC Critical pressure * @param M Molar mass * @param a Acentric factor - * @param moles Number of moles + * @param moles Total number of moles of component. */ public ComponentGERG2004(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEos.java b/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEos.java index 6d89916fd..6269cd2dc 100644 --- a/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEos.java +++ b/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEos.java @@ -101,12 +101,12 @@ public ComponentModifiedFurstElectrolyteEos(String name, double moles, double mo * Constructor for ComponentModifiedFurstElectrolyteEos. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentModifiedFurstElectrolyteEos(int number, double TC, double PC, double M, double a, double moles) { diff --git a/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEosMod2004.java b/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEosMod2004.java index edaf843f6..ee1f1cef4 100644 --- a/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEosMod2004.java +++ b/src/main/java/neqsim/thermo/component/ComponentModifiedFurstElectrolyteEosMod2004.java @@ -101,12 +101,12 @@ public ComponentModifiedFurstElectrolyteEosMod2004(String name, double moles, do * Constructor for ComponentModifiedFurstElectrolyteEosMod2004. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentModifiedFurstElectrolyteEosMod2004(int number, double TC, double PC, double M, double a, double moles) { diff --git a/src/main/java/neqsim/thermo/component/ComponentPCSAFT.java b/src/main/java/neqsim/thermo/component/ComponentPCSAFT.java index 17fb6c4dc..37f1b1b61 100644 --- a/src/main/java/neqsim/thermo/component/ComponentPCSAFT.java +++ b/src/main/java/neqsim/thermo/component/ComponentPCSAFT.java @@ -52,12 +52,12 @@ public ComponentPCSAFT(String name, double moles, double molesInPhase, int compI * Constructor for ComponentPCSAFT. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentPCSAFT(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentPCSAFTa.java b/src/main/java/neqsim/thermo/component/ComponentPCSAFTa.java index 370db747b..ee3b4b601 100644 --- a/src/main/java/neqsim/thermo/component/ComponentPCSAFTa.java +++ b/src/main/java/neqsim/thermo/component/ComponentPCSAFTa.java @@ -53,12 +53,12 @@ public ComponentPCSAFTa(String name, double moles, double molesInPhase, int comp * Constructor for ComponentPCSAFTa. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentPCSAFTa(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentPR.java b/src/main/java/neqsim/thermo/component/ComponentPR.java index ed21c9893..7bd93677f 100644 --- a/src/main/java/neqsim/thermo/component/ComponentPR.java +++ b/src/main/java/neqsim/thermo/component/ComponentPR.java @@ -44,12 +44,12 @@ public ComponentPR(String name, double moles, double molesInPhase, int compIndex * Constructor for ComponentPR. * * - * @param number a int + * @param number a int. Not used. * @param TC Critical temperature * @param PC Critical pressure * @param M Molar mass * @param a Acentric factor - * @param moles Number of moles + * @param moles Total number of moles of component. */ public ComponentPR(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentPRvolcor.java b/src/main/java/neqsim/thermo/component/ComponentPRvolcor.java index b4abaf488..deba24ab9 100644 --- a/src/main/java/neqsim/thermo/component/ComponentPRvolcor.java +++ b/src/main/java/neqsim/thermo/component/ComponentPRvolcor.java @@ -30,12 +30,12 @@ public class ComponentPRvolcor extends ComponentPR { * Constructor for ComponentPRvolcor. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentPRvolcor(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentPrCPA.java b/src/main/java/neqsim/thermo/component/ComponentPrCPA.java index a261a4e6e..f2cb631c5 100644 --- a/src/main/java/neqsim/thermo/component/ComponentPrCPA.java +++ b/src/main/java/neqsim/thermo/component/ComponentPrCPA.java @@ -45,12 +45,12 @@ public ComponentPrCPA(String name, double moles, double molesInPhase, int compIn * Constructor for ComponentPrCPA. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentPrCPA(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentRK.java b/src/main/java/neqsim/thermo/component/ComponentRK.java index 0edbb1268..4713c9f45 100644 --- a/src/main/java/neqsim/thermo/component/ComponentRK.java +++ b/src/main/java/neqsim/thermo/component/ComponentRK.java @@ -39,12 +39,12 @@ public ComponentRK(String name, double moles, double molesInPhase, int compIndex * Constructor for ComponentRK. * * - * @param number a int + * @param number a int. Not used. * @param TC Critical temperature * @param PC Critical pressure * @param M Molar mass * @param a Acentric factor - * @param moles Number of moles + * @param moles Total number of moles of component. */ public ComponentRK(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentSrk.java b/src/main/java/neqsim/thermo/component/ComponentSrk.java index 9dbfe9509..5db09136f 100644 --- a/src/main/java/neqsim/thermo/component/ComponentSrk.java +++ b/src/main/java/neqsim/thermo/component/ComponentSrk.java @@ -48,12 +48,12 @@ public ComponentSrk(String name, double moles, double molesInPhase, int compInde * Constructor for ComponentSrk. * * - * @param number a int + * @param number a int. Not used. * @param TC Critical temperature * @param PC Critical pressure * @param M Molar mass * @param a Acentric factor - * @param moles Number of moles + * @param moles Total number of moles of component. */ public ComponentSrk(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentSrkCPA.java b/src/main/java/neqsim/thermo/component/ComponentSrkCPA.java index 37649b61d..ee9d87aa7 100644 --- a/src/main/java/neqsim/thermo/component/ComponentSrkCPA.java +++ b/src/main/java/neqsim/thermo/component/ComponentSrkCPA.java @@ -67,12 +67,12 @@ public ComponentSrkCPA(String name, double moles, double molesInPhase, int compI * Constructor for ComponentSrkCPA. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentSrkCPA(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentSrkCPAs.java b/src/main/java/neqsim/thermo/component/ComponentSrkCPAs.java index 7c4f380d0..ab410861e 100644 --- a/src/main/java/neqsim/thermo/component/ComponentSrkCPAs.java +++ b/src/main/java/neqsim/thermo/component/ComponentSrkCPAs.java @@ -32,12 +32,12 @@ public ComponentSrkCPAs(String name, double moles, double molesInPhase, int comp * Constructor for ComponentSrkCPAs. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentSrkCPAs(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentSrkPeneloux.java b/src/main/java/neqsim/thermo/component/ComponentSrkPeneloux.java index 314fc8a51..c6eb4b588 100644 --- a/src/main/java/neqsim/thermo/component/ComponentSrkPeneloux.java +++ b/src/main/java/neqsim/thermo/component/ComponentSrkPeneloux.java @@ -49,12 +49,12 @@ public ComponentSrkPeneloux(String name, double moles, double molesInPhase, int * Constructor for ComponentSrkPeneloux. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentSrkPeneloux(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentTST.java b/src/main/java/neqsim/thermo/component/ComponentTST.java index c2ae66323..8a7658481 100644 --- a/src/main/java/neqsim/thermo/component/ComponentTST.java +++ b/src/main/java/neqsim/thermo/component/ComponentTST.java @@ -41,12 +41,12 @@ public ComponentTST(String name, double moles, double molesInPhase, int compInde * Constructor for ComponentTST. * * - * @param number a int + * @param number a int. Not used. * @param TC Critical temperature * @param PC Critical pressure * @param M Molar mass * @param a Acentric factor - * @param moles Number of moles + * @param moles Total number of moles of component. */ public ComponentTST(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/ComponentUMRCPA.java b/src/main/java/neqsim/thermo/component/ComponentUMRCPA.java index 84c59ec62..8495fa852 100644 --- a/src/main/java/neqsim/thermo/component/ComponentUMRCPA.java +++ b/src/main/java/neqsim/thermo/component/ComponentUMRCPA.java @@ -67,12 +67,12 @@ public ComponentUMRCPA(String name, double moles, double molesInPhase, int compI * Constructor for ComponentSrkCPA. * * - * @param number a int - * @param TC a double - * @param PC a double - * @param M a double - * @param a a double - * @param moles a double + * @param number a int. Not used. + * @param TC Critical temperature + * @param PC Critical pressure + * @param M Molar mass + * @param a Acentric factor + * @param moles Total number of moles of component. */ public ComponentUMRCPA(int number, double TC, double PC, double M, double a, double moles) { super(number, TC, PC, M, a, moles); diff --git a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermBaseClass.java b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermBaseClass.java index ba226897b..83e546df6 100644 --- a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermBaseClass.java +++ b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermBaseClass.java @@ -18,7 +18,7 @@ * @author esol * @version $Id: $Id */ -public class AttractiveTermBaseClass implements AttractiveTermInterface { +public abstract class AttractiveTermBaseClass implements AttractiveTermInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(AttractiveTermBaseClass.class); @@ -27,13 +27,6 @@ public class AttractiveTermBaseClass implements AttractiveTermInterface { protected double[] parameters = new double[3]; protected double[] parametersSolid = new double[3]; - /** - *- * Constructor for AttractiveTermBaseClass. - *
- */ - public AttractiveTermBaseClass() {} - /** ** Constructor for AttractiveTermBaseClass. @@ -75,10 +68,6 @@ public AttractiveTermBaseClass clone() { return attractiveTerm; } - /** {@inheritDoc} */ - @Override - public void init() {} - /** {@inheritDoc} */ @Override public double diffdiffalphaT(double temperature) { diff --git a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermMollerup.java b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermMollerup.java index b9d0dc16c..f1e8a7774 100644 --- a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermMollerup.java +++ b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermMollerup.java @@ -37,6 +37,10 @@ public AttractiveTermMollerup(ComponentEosInterface component, double[] params) System.arraycopy(params, 0, this.parameters, 0, params.length); } + /** {@inheritDoc} */ + @Override + public void init() {} + /** {@inheritDoc} */ @Override public AttractiveTermMollerup clone() { diff --git a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermRk.java b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermRk.java index 953a4aa8f..be1cd3f76 100644 --- a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermRk.java +++ b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermRk.java @@ -24,6 +24,10 @@ public AttractiveTermRk(ComponentEosInterface component) { super(component); } + /** {@inheritDoc} */ + @Override + public void init() {} + /** {@inheritDoc} */ @Override public AttractiveTermRk clone() { diff --git a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermSrk.java b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermSrk.java index 04b398fc3..03bc0d920 100644 --- a/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermSrk.java +++ b/src/main/java/neqsim/thermo/component/attractiveeosterm/AttractiveTermSrk.java @@ -13,13 +13,6 @@ public class AttractiveTermSrk extends AttractiveTermBaseClass { private static final long serialVersionUID = 1000; - /** - *
- * Constructor for AttractiveTermSrk. - *
- */ - public AttractiveTermSrk() {} - /** ** Constructor for AttractiveTermSrk. diff --git a/src/main/java/neqsim/thermo/system/SystemInterface.java b/src/main/java/neqsim/thermo/system/SystemInterface.java index c6e5092f0..d6a3e87c3 100644 --- a/src/main/java/neqsim/thermo/system/SystemInterface.java +++ b/src/main/java/neqsim/thermo/system/SystemInterface.java @@ -1687,24 +1687,24 @@ public default void init() { * method to calculate thermodynamic properties of the fluid. The temperature, pressure, number of * phases and composition of the phases will be used as basis for calculation. * - * @param number - The number can be 0, 1, 2 or 3. 0: Set feed composition for all phases. 1: + * @param initType - The number can be 0, 1, 2 or 3. 0: Set feed composition for all phases. 1: * Calculation of density, fugacities and Z-factor 2: 1 + calculation of enthalpy, entropy, * Cp, Cv, and most other thermodynamic properties 3: 1+2 + Calculation of composition * derivatives of fugacity coefficients. */ - public void init(int number); + public void init(int initType); /** * method to calculate thermodynamic properties of the selected phase. The temperature, pressure, * number of phases and composition of the phase will be used as basis for calculation. * - * @param number - The number can be 0, 1, 2 or 3. 0: Set feed composition. 1: Calculation of + * @param initType - The number can be 0, 1, 2 or 3. 0: Set feed composition. 1: Calculation of * density, fugacities and Z-factor 2: 1 + calculation of enthalpy, entropy, Cp, Cv, and * most other thermodynamic properties 3: 1+2 + Calculation of composition derivatives of * fugacity coefficients. * @param phaseNum a int */ - public void init(int number, int phaseNum); + public void init(int initType, int phaseNum); /** *
diff --git a/src/main/java/neqsim/thermo/system/SystemThermo.java b/src/main/java/neqsim/thermo/system/SystemThermo.java index e41f09a72..3f2249f1a 100644 --- a/src/main/java/neqsim/thermo/system/SystemThermo.java +++ b/src/main/java/neqsim/thermo/system/SystemThermo.java @@ -2603,12 +2603,10 @@ public final int getNumberOfPhases() { public int[] getOilFractionIDs() { int numb = getNumberOfOilFractionComponents(); int[] IDs = new int[numb]; - // int number = 0; for (int i = 0; i < numb; i++) { if (getPhase(0).getComponent(i).isIsTBPfraction() || getPhase(0).getComponent(i).isIsPlusFraction()) { IDs[i] = getPhase(0).getComponent(i).getIndex(); - // number++; } } return IDs; @@ -3141,15 +3139,15 @@ public boolean hasTBPFraction() { /** {@inheritDoc} */ @Override - public void init(int type) { + public void init(int initType) { if (!this.isInitialized) { initBeta(); init_x_y(); } if (this.numericDerivatives) { - initNumeric(type); + initNumeric(initType); } else { - initAnalytic(type); + initAnalytic(initType); } this.isInitialized = true; @@ -3452,12 +3450,12 @@ public void initNumeric(int type) { * initNumeric. *
* - * @param type a int + * @param initType a int * @param phasen a int */ - public void initNumeric(int type, int phasen) { - if (type < 2) { - initAnalytic(type); + public void initNumeric(int initType, int phasen) { + if (initType < 2) { + initAnalytic(initType); } else { double[][] gasfug = new double[2][getPhases()[0].getNumberOfComponents()]; double[][] liqfug = new double[2][getPhases()[0].getNumberOfComponents()]; @@ -3511,7 +3509,7 @@ public void initNumeric(int type, int phasen) { setPressure(getPressure() + dp); init(1); - if (type == 3) { + if (initType == 3) { for (int phaseNum = 0; phaseNum < 2; phaseNum++) { for (int k = 0; k < getPhases()[0].getNumberOfComponents(); k++) { double dn = getPhase(phaseNum).getComponent(k).getNumberOfMolesInPhase() / 1.0e6; diff --git a/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenBarFlash.java b/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenBarFlash.java index 575c2ca99..16747ee63 100644 --- a/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenBarFlash.java +++ b/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenBarFlash.java @@ -276,7 +276,7 @@ public void setNewX() { /** *- * init. + * init. Calls system.init(3); *
*/ public void init() { diff --git a/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenThermFlash.java b/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenThermFlash.java index c2f92e698..a19940bc1 100644 --- a/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenThermFlash.java +++ b/src/main/java/neqsim/thermodynamicoperations/phaseenvelopeops/multicomponentenvelopeops/CricondenThermFlash.java @@ -273,7 +273,7 @@ public void setNewX() { /** *- * init. + * init. Calls system.init(3); *
*/ public void init() {