From 0eaec683cc0463162f823973d82c1c4e9e4af551 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=85smund=20V=C3=A5ge=20Fannemel?= <34712686+asmfstatoil@users.noreply.github.com> Date: Sun, 27 Oct 2024 16:50:31 +0100 Subject: [PATCH] refact: mark classes abstract and simplify imports (#1151) --- .../PhysicalPropertyType.java | 2 +- .../CommonPhysicalPropertyMethod.java | 12 ++++----- .../conductivity/Conductivity.java | 10 +++---- .../PFCTConductivityMethodMod86.java | 2 +- .../diffusivity/Diffusivity.java | 4 +-- .../viscosity/Viscosity.java | 7 +++-- .../GasPhysicalPropertyMethod.java | 17 ++++-------- .../conductivity/ChungConductivityMethod.java | 2 +- .../conductivity/Conductivity.java | 10 +++---- .../density/Density.java | 12 ++++----- .../diffusivity/Diffusivity.java | 7 +++-- .../diffusivity/WilkeLeeDiffusivity.java | 14 +++++++--- .../viscosity/Viscosity.java | 9 +++---- .../LiquidPhysicalPropertyMethod.java | 22 +++++---------- .../conductivity/Conductivity.java | 9 +++---- .../density/Costald.java | 10 +++---- .../density/Density.java | 10 +++---- .../diffusivity/Diffusivity.java | 7 +++-- .../viscosity/Viscosity.java | 7 +++-- .../ConductivityInterface.java | 5 ++-- .../methodinterface/DensityInterface.java | 5 ++-- .../methodinterface/DiffusivityInterface.java | 5 ++-- .../methodinterface/ViscosityInterface.java | 5 ++-- .../SolidPhysicalPropertyMethod.java | 19 +++++-------- .../conductivity/Conductivity.java | 9 +++---- .../density/Density.java | 14 +++++----- .../diffusivity/Diffusivity.java | 7 +++-- .../viscosity/Viscosity.java | 7 +++-- .../PhysicalProperties.java | 27 ++++++++++--------- .../GasPhysicalProperties.java | 5 ++-- .../CO2waterPhysicalProperties.java | 4 +-- .../LiquidPhysicalProperties.java | 4 +-- .../FlowInducedVibrationAnalyser.java | 4 +-- .../ComponentGEUniquacmodifiedHV.java | 2 +- .../thermo/component/ComponentPrCPA.java | 2 +- 35 files changed, 139 insertions(+), 158 deletions(-) diff --git a/src/main/java/neqsim/physicalproperties/PhysicalPropertyType.java b/src/main/java/neqsim/physicalproperties/PhysicalPropertyType.java index 5bc732df50..9116ad4384 100644 --- a/src/main/java/neqsim/physicalproperties/PhysicalPropertyType.java +++ b/src/main/java/neqsim/physicalproperties/PhysicalPropertyType.java @@ -7,12 +7,12 @@ * * @author ASMF */ - public enum PhysicalPropertyType { MASS_DENSITY, DYNAMIC_VISCOSITY, THERMAL_CONDUCTIVITY; // We know we'll never mutate this, so we can keep // a local copy for fast lookup in byName + /** Constant copyOfValues */ private static final PhysicalPropertyType[] copyOfValues = values(); /** diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/CommonPhysicalPropertyMethod.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/CommonPhysicalPropertyMethod.java index 69af7433fb..1911186e39 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/CommonPhysicalPropertyMethod.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/CommonPhysicalPropertyMethod.java @@ -1,5 +1,8 @@ package neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface; + /** *

* CommonPhysicalPropertyMethod class. @@ -8,8 +11,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class CommonPhysicalPropertyMethod - extends neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod { +public abstract class CommonPhysicalPropertyMethod extends PhysicalPropertyMethod { private static final long serialVersionUID = 1000; protected neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase; @@ -23,15 +25,13 @@ public class CommonPhysicalPropertyMethod * {@link neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface} * object */ - public CommonPhysicalPropertyMethod( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase) { + public CommonPhysicalPropertyMethod(PhysicalPropertiesInterface phase) { this.phase = phase; } /** {@inheritDoc} */ @Override - public void setPhase( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase) { + public void setPhase(PhysicalPropertiesInterface phase) { this.phase = phase; } } diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/Conductivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/Conductivity.java index 64679d1e88..cc36318685 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/Conductivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/Conductivity.java @@ -2,16 +2,16 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.CommonPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface; /** - * Class for physical property Conductivity. + * Abstract class for Conductivity. * * @author Even Solbraa */ -abstract class Conductivity extends - neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.CommonPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface { +public abstract class Conductivity extends CommonPhysicalPropertyMethod + implements ConductivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Conductivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/PFCTConductivityMethodMod86.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/PFCTConductivityMethodMod86.java index 5ed04e14ae..bd303fb30f 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/PFCTConductivityMethodMod86.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/conductivity/PFCTConductivityMethodMod86.java @@ -6,7 +6,7 @@ /** *

- * PFCTConductivityMethodMod86 class. + * PFCTConductivityMethodMod86 class extending conductivity for commonphase. *

* * @author esol diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/diffusivity/Diffusivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/diffusivity/Diffusivity.java index f8a608e5b6..436b3713a3 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/diffusivity/Diffusivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/diffusivity/Diffusivity.java @@ -3,6 +3,7 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.CommonPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface; /** *

@@ -12,8 +13,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class Diffusivity extends CommonPhysicalPropertyMethod implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface { +public class Diffusivity extends CommonPhysicalPropertyMethod implements DiffusivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Diffusivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/viscosity/Viscosity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/viscosity/Viscosity.java index b7ea0f9f71..ebc04177b2 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/viscosity/Viscosity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/commonphasephysicalproperties/viscosity/Viscosity.java @@ -2,16 +2,15 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.CommonPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface; /** * Abstract class for Viscosity property. * * @author Even Solbraa */ -abstract class Viscosity extends - neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.CommonPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface { +public abstract class Viscosity extends CommonPhysicalPropertyMethod implements ViscosityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Viscosity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/GasPhysicalPropertyMethod.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/GasPhysicalPropertyMethod.java index 5316ee9640..0cdf90c528 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/GasPhysicalPropertyMethod.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/GasPhysicalPropertyMethod.java @@ -1,5 +1,8 @@ package neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface; + /** *

* GasPhysicalPropertyMethod class. @@ -8,8 +11,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class GasPhysicalPropertyMethod - extends neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod { +public abstract class GasPhysicalPropertyMethod extends PhysicalPropertyMethod { private static final long serialVersionUID = 1000; protected neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface gasPhase; @@ -17,14 +19,6 @@ public class GasPhysicalPropertyMethod public double[][] binaryEnergyParameter; public double[][] binaryMolecularMass; - /** - *

- * Constructor for GasPhysicalPropertyMethod. - *

- */ - public GasPhysicalPropertyMethod() { - } - /** *

* Constructor for GasPhysicalPropertyMethod. @@ -34,8 +28,7 @@ public GasPhysicalPropertyMethod() { * {@link neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface} * object */ - public GasPhysicalPropertyMethod( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface gasPhase) { + public GasPhysicalPropertyMethod(PhysicalPropertiesInterface gasPhase) { this.gasPhase = gasPhase; binaryMolecularDiameter = new double[gasPhase.getPhase().getNumberOfComponents()][gasPhase .getPhase().getNumberOfComponents()]; diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/ChungConductivityMethod.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/ChungConductivityMethod.java index 3d857a16d3..982f8071e4 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/ChungConductivityMethod.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/ChungConductivityMethod.java @@ -2,7 +2,7 @@ /** *

- * ChungConductivityMethod class. + * ChungConductivityMethod class extending conductivity for gases. *

* * @author Even Solbraa diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/Conductivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/Conductivity.java index fdb085571c..89f9b1c991 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/Conductivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/conductivity/Conductivity.java @@ -8,16 +8,16 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface; /** - * Abstract class Conductivity. + * Abstract class Conductivity for gases. * * @author Even Solbraa */ -abstract class Conductivity extends - neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface { +public abstract class Conductivity extends GasPhysicalPropertyMethod + implements ConductivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Conductivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/density/Density.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/density/Density.java index e87bad69a3..d662044cc4 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/density/Density.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/density/Density.java @@ -9,17 +9,17 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface; /** *

- * Density class. + * Density class for gases. *

* * @author Even Solbraa * @version $Id: $Id */ -public class Density extends GasPhysicalPropertyMethod - implements neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface { +public class Density extends GasPhysicalPropertyMethod implements DensityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Density.class); @@ -28,13 +28,13 @@ public class Density extends GasPhysicalPropertyMethod * Constructor for Density. *

* - * @param gasPhase a + * @param phase a * {@link neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface} * object */ public Density( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface gasPhase) { - this.gasPhase = gasPhase; + neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase) { + super(phase); } /** {@inheritDoc} */ diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/Diffusivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/Diffusivity.java index a135d33cbb..cdc8d22908 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/Diffusivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/Diffusivity.java @@ -2,6 +2,8 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface; /** *

@@ -11,10 +13,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class Diffusivity extends - neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface { +public class Diffusivity extends GasPhysicalPropertyMethod implements DiffusivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Diffusivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/WilkeLeeDiffusivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/WilkeLeeDiffusivity.java index 60241b0d8e..8a9443fa16 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/WilkeLeeDiffusivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/diffusivity/WilkeLeeDiffusivity.java @@ -11,7 +11,9 @@ public class WilkeLeeDiffusivity extends Diffusivity { private static final long serialVersionUID = 1000; - double[][] binaryDiffusionCoefficients, binaryLennardJonesOmega; + double[][] binaryDiffusionCoefficients; + + double[][] binaryLennardJonesOmega; /** *

@@ -38,8 +40,14 @@ public double calcBinaryDiffusionCoefficient(int i, int j, int method) { // if(method==? then) // remember this is the Fick's diffusion coefficients // to get the Maxwell-Stefan coefficient - multiply by gamma - double A2 = 1.06036, B2 = 0.15610, C2 = 0.19300, D2 = 0.47635, E2 = 1.03587, F2 = 1.52996, - G2 = 1.76474, H2 = 3.89411; + double A2 = 1.06036; + double B2 = 0.15610; + double C2 = 0.19300; + double D2 = 0.47635; + double E2 = 1.03587; + double F2 = 1.52996; + double G2 = 1.76474; + double H2 = 3.89411; double tempVar2 = gasPhase.getPhase().getTemperature() / binaryEnergyParameter[i][j]; binaryLennardJonesOmega[i][j] = A2 / Math.pow(tempVar2, B2) + C2 / Math.exp(D2 * tempVar2) + E2 / Math.exp(F2 * tempVar2) + G2 / Math.exp(H2 * tempVar2); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/viscosity/Viscosity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/viscosity/Viscosity.java index 2cd72f0a91..f643035591 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/viscosity/Viscosity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/gasphysicalproperties/viscosity/Viscosity.java @@ -2,16 +2,15 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface; /** - * * Abstract class for Viscosity property. + * Abstract class for Viscosity property. * * @author Even Solbraa */ -abstract class Viscosity extends - neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.GasPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface { +public abstract class Viscosity extends GasPhysicalPropertyMethod implements ViscosityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Viscosity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/LiquidPhysicalPropertyMethod.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/LiquidPhysicalPropertyMethod.java index a88f6ef62e..9e4f7410d2 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/LiquidPhysicalPropertyMethod.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/LiquidPhysicalPropertyMethod.java @@ -1,5 +1,8 @@ package neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface; + /** *

* LiquidPhysicalPropertyMethod class. @@ -8,20 +11,11 @@ * @author Even Solbraa * @version $Id: $Id */ -public class LiquidPhysicalPropertyMethod - extends neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod { +public abstract class LiquidPhysicalPropertyMethod extends PhysicalPropertyMethod { private static final long serialVersionUID = 1000; protected neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface liquidPhase; - /** - *

- * Constructor for LiquidPhysicalPropertyMethod. - *

- */ - public LiquidPhysicalPropertyMethod() { - } - /** *

* Constructor for LiquidPhysicalPropertyMethod. @@ -31,15 +25,13 @@ public LiquidPhysicalPropertyMethod() { * {@link neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface} * object */ - public LiquidPhysicalPropertyMethod( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface liquidPhase) { - this.liquidPhase = liquidPhase; + public LiquidPhysicalPropertyMethod(PhysicalPropertiesInterface liquidPhase) { + setPhase(liquidPhase); } /** {@inheritDoc} */ @Override - public void setPhase( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase) { + public void setPhase(PhysicalPropertiesInterface phase) { this.liquidPhase = phase; } } diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/conductivity/Conductivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/conductivity/Conductivity.java index 5bbc006f3e..167a4e7dc4 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/conductivity/Conductivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/conductivity/Conductivity.java @@ -8,19 +8,18 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface; /** *

- * Conductivity class. + * Conductivity class for liquids. *

* * @author Even Solbraa * @version $Id: $Id */ -public class Conductivity extends - neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface { +public class Conductivity extends LiquidPhysicalPropertyMethod implements ConductivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Conductivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Costald.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Costald.java index 697a191e38..d3c45ae4d3 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Costald.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Costald.java @@ -8,18 +8,18 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface; /** *

- * Costald Density Calculation class. + * Costald Density Calculation class for liquids. *

* * @author Even Solbraa * @version $Id: $Id */ -public class Costald extends - neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod - implements neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface { +public class Costald extends LiquidPhysicalPropertyMethod implements DensityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Density.class); @@ -34,7 +34,7 @@ public class Costald extends */ public Costald( neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface liquidPhase) { - this.liquidPhase = liquidPhase; + super(liquidPhase); } /** {@inheritDoc} */ diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Density.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Density.java index e55dc70cd2..60fc134f0b 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Density.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/density/Density.java @@ -8,18 +8,18 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface; /** *

- * Density class. + * Density class foir liquids. *

* * @author Even Solbraa * @version $Id: $Id */ -public class Density extends - neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod - implements neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface { +public class Density extends LiquidPhysicalPropertyMethod implements DensityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Density.class); @@ -34,7 +34,7 @@ public class Density extends */ public Density( neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface liquidPhase) { - this.liquidPhase = liquidPhase; + super(liquidPhase); } /** {@inheritDoc} */ diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/diffusivity/Diffusivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/diffusivity/Diffusivity.java index 562aca93ba..11cd343cbb 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/diffusivity/Diffusivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/diffusivity/Diffusivity.java @@ -2,16 +2,15 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface; /** * Diffusivity class. * * @author Even Solbraa */ -abstract class Diffusivity extends - neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface { +abstract class Diffusivity extends LiquidPhysicalPropertyMethod implements DiffusivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Diffusivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/viscosity/Viscosity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/viscosity/Viscosity.java index 1262922079..1eb58881dd 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/viscosity/Viscosity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/liquidphysicalproperties/viscosity/Viscosity.java @@ -2,6 +2,8 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface; /** *

@@ -11,10 +13,7 @@ * @author Even Solbraa * @version Method was checked on 2.8.2001 - seems to be correct - Even Solbraa */ -public class Viscosity extends - neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.LiquidPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface { +public class Viscosity extends LiquidPhysicalPropertyMethod implements ViscosityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Viscosity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ConductivityInterface.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ConductivityInterface.java index d12f47a9b5..4355a512cc 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ConductivityInterface.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ConductivityInterface.java @@ -1,5 +1,6 @@ package neqsim.physicalproperties.physicalpropertymethods.methodinterface; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface; import neqsim.thermo.ThermodynamicConstantsInterface; /** @@ -10,8 +11,8 @@ * @author Even Solbraa * @version $Id: $Id */ -public interface ConductivityInterface extends ThermodynamicConstantsInterface, - neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface { +public interface ConductivityInterface + extends ThermodynamicConstantsInterface, PhysicalPropertyMethodInterface { /** *

* calcConductivity. diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DensityInterface.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DensityInterface.java index dd4371524f..3654877225 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DensityInterface.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DensityInterface.java @@ -1,5 +1,6 @@ package neqsim.physicalproperties.physicalpropertymethods.methodinterface; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface; import neqsim.thermo.ThermodynamicConstantsInterface; /** @@ -10,8 +11,8 @@ * @author Even Solbraa * @version $Id: $Id */ -public interface DensityInterface extends ThermodynamicConstantsInterface, - neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface { +public interface DensityInterface + extends ThermodynamicConstantsInterface, PhysicalPropertyMethodInterface { /** *

* Returns the density of the phase. Unit: kg/m^3 diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DiffusivityInterface.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DiffusivityInterface.java index 93bfb870c9..bb7ae9f1e4 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DiffusivityInterface.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/DiffusivityInterface.java @@ -1,5 +1,6 @@ package neqsim.physicalproperties.physicalpropertymethods.methodinterface; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface; import neqsim.thermo.ThermodynamicConstantsInterface; /** @@ -10,8 +11,8 @@ * @author Even Solbraa * @version $Id: $Id */ -public interface DiffusivityInterface extends ThermodynamicConstantsInterface, - neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface { +public interface DiffusivityInterface + extends ThermodynamicConstantsInterface, PhysicalPropertyMethodInterface { /** *

* calcBinaryDiffusionCoefficient. diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ViscosityInterface.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ViscosityInterface.java index 9a55211e5d..9d34b48439 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ViscosityInterface.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/methodinterface/ViscosityInterface.java @@ -1,5 +1,7 @@ package neqsim.physicalproperties.physicalpropertymethods.methodinterface; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface; + /** *

* ViscosityInterface interface. @@ -8,8 +10,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public interface ViscosityInterface - extends neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethodInterface { +public interface ViscosityInterface extends PhysicalPropertyMethodInterface { /** *

* calcViscosity. diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/SolidPhysicalPropertyMethod.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/SolidPhysicalPropertyMethod.java index 715439dd78..2328a1a8fe 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/SolidPhysicalPropertyMethod.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/SolidPhysicalPropertyMethod.java @@ -1,5 +1,7 @@ package neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties; +import neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod; + /** *

* SolidPhysicalPropertyMethod class. @@ -8,20 +10,11 @@ * @author Even Solbraa * @version $Id: $Id */ -public class SolidPhysicalPropertyMethod - extends neqsim.physicalproperties.physicalpropertymethods.PhysicalPropertyMethod { +public abstract class SolidPhysicalPropertyMethod extends PhysicalPropertyMethod { private static final long serialVersionUID = 1000; protected neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface solidPhase; - /** - *

- * Constructor for SolidPhysicalPropertyMethod. - *

- */ - public SolidPhysicalPropertyMethod() { - } - /** *

* Constructor for SolidPhysicalPropertyMethod. @@ -33,13 +26,13 @@ public SolidPhysicalPropertyMethod() { */ public SolidPhysicalPropertyMethod( neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface solidPhase) { - this.solidPhase = solidPhase; + setPhase(solidPhase); } /** {@inheritDoc} */ @Override public void setPhase( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface solidPhase) { - this.solidPhase = solidPhase; + neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase) { + this.solidPhase = phase; } } diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/conductivity/Conductivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/conductivity/Conductivity.java index c6ffade174..94ee8bff9a 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/conductivity/Conductivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/conductivity/Conductivity.java @@ -8,20 +8,19 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface; +import neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod; import neqsim.thermo.phase.PhaseType; /** *

- * Conductivity class. + * Conductivity class for solids. *

* * @author Even Solbraa * @version $Id: $Id */ -public class Conductivity extends - neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface { +public class Conductivity extends SolidPhysicalPropertyMethod implements ConductivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Conductivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/density/Density.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/density/Density.java index ce179d5918..1913850677 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/density/Density.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/density/Density.java @@ -8,18 +8,18 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface; +import neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod; /** *

- * Density class. + * Density class for solids. *

* * @author Even Solbraa * @version $Id: $Id */ -public class Density extends - neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod - implements neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface { +public class Density extends SolidPhysicalPropertyMethod implements DensityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Density.class); @@ -28,13 +28,13 @@ public class Density extends * Constructor for Density. *

* - * @param liquidPhase a + * @param phase a * {@link neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface} * object */ public Density( - neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface liquidPhase) { - this.solidPhase = liquidPhase; + neqsim.physicalproperties.physicalpropertysystem.PhysicalPropertiesInterface phase) { + super(phase); } /** {@inheritDoc} */ diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/diffusivity/Diffusivity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/diffusivity/Diffusivity.java index 5652090482..3ff37622f4 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/diffusivity/Diffusivity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/diffusivity/Diffusivity.java @@ -2,6 +2,8 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface; +import neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod; /** *

@@ -11,10 +13,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class Diffusivity extends - neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface { +public class Diffusivity extends SolidPhysicalPropertyMethod implements DiffusivityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Diffusivity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/viscosity/Viscosity.java b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/viscosity/Viscosity.java index fa76ffcdfc..120a4991e9 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/viscosity/Viscosity.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertymethods/solidphysicalproperties/viscosity/Viscosity.java @@ -3,6 +3,8 @@ import static java.lang.Double.NaN; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface; +import neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod; /** *

@@ -12,10 +14,7 @@ * @author Even Solbraa * @version Method was checked on 2.8.2001 - seems to be correct - Even Solbraa */ -public class Viscosity extends - neqsim.physicalproperties.physicalpropertymethods.solidphysicalproperties.SolidPhysicalPropertyMethod - implements - neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface { +public class Viscosity extends SolidPhysicalPropertyMethod implements ViscosityInterface { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(Viscosity.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/PhysicalProperties.java b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/PhysicalProperties.java index fa16d7ed00..d9d57ac236 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/PhysicalProperties.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/PhysicalProperties.java @@ -9,6 +9,7 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import neqsim.physicalproperties.PhysicalPropertyType; +import neqsim.physicalproperties.mixingrule.PhysicalPropertyMixingRuleInterface; import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.conductivity.PFCTConductivityMethodMod86; import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.diffusivity.CorrespondingStatesDiffusivity; import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.viscosity.FrictionTheoryViscosityMethod; @@ -17,9 +18,13 @@ import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.viscosity.PFCTViscosityMethodMod86; import neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.conductivity.ChungConductivityMethod; import neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.diffusivity.WilkeLeeDiffusivity; +import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.density.Costald; import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.diffusivity.AmineDiffusivity; import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.diffusivity.SiddiqiLucasMethod; import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface; +import neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface; import neqsim.thermo.ThermodynamicConstantsInterface; import neqsim.thermo.phase.PhaseInterface; @@ -39,12 +44,11 @@ public abstract class PhysicalProperties protected PhaseInterface phase; protected int binaryDiffusionCoefficientMethod; protected int multicomponentDiffusionMethod; - private neqsim.physicalproperties.mixingrule.PhysicalPropertyMixingRuleInterface mixingRule = - null; - public neqsim.physicalproperties.physicalpropertymethods.methodinterface.ConductivityInterface conductivityCalc; - public neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface viscosityCalc; - public neqsim.physicalproperties.physicalpropertymethods.methodinterface.DiffusivityInterface diffusivityCalc; - public neqsim.physicalproperties.physicalpropertymethods.methodinterface.DensityInterface densityCalc; + private PhysicalPropertyMixingRuleInterface mixingRule = null; + public ConductivityInterface conductivityCalc; + public ViscosityInterface viscosityCalc; + public DiffusivityInterface diffusivityCalc; + public DensityInterface densityCalc; public double kinematicViscosity = 0; public double density = 0; public double viscosity = 0; @@ -106,14 +110,13 @@ public PhaseInterface getPhase() { /** {@inheritDoc} */ @Override - public neqsim.physicalproperties.mixingrule.PhysicalPropertyMixingRuleInterface getMixingRule() { + public PhysicalPropertyMixingRuleInterface getMixingRule() { return mixingRule; } /** {@inheritDoc} */ @Override - public void setMixingRule( - neqsim.physicalproperties.mixingrule.PhysicalPropertyMixingRuleInterface mixingRule) { + public void setMixingRule(PhysicalPropertyMixingRuleInterface mixingRule) { this.mixingRule = mixingRule; } @@ -125,7 +128,7 @@ public void setMixingRuleNull() { /** {@inheritDoc} */ @Override - public neqsim.physicalproperties.physicalpropertymethods.methodinterface.ViscosityInterface getViscosityModel() { + public ViscosityInterface getViscosityModel() { return viscosityCalc; } @@ -137,9 +140,7 @@ public void setDensityModel(String model) { new neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.density.Density( this); } else if ("Costald".equals(model)) { - densityCalc = - new neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.density.Costald( - this); + densityCalc = new Costald(this); } } diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/gasphysicalproperties/GasPhysicalProperties.java b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/gasphysicalproperties/GasPhysicalProperties.java index 3c11c11ed5..a9f8d7871a 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/gasphysicalproperties/GasPhysicalProperties.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/gasphysicalproperties/GasPhysicalProperties.java @@ -10,6 +10,7 @@ import org.apache.logging.log4j.Logger; import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.conductivity.PFCTConductivityMethodMod86; import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.viscosity.PFCTViscosityMethodHeavyOil; +import neqsim.physicalproperties.physicalpropertysystem.PhysicalProperties; import neqsim.thermo.phase.PhaseInterface; /** @@ -20,8 +21,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class GasPhysicalProperties - extends neqsim.physicalproperties.physicalpropertysystem.PhysicalProperties { +public class GasPhysicalProperties extends PhysicalProperties { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(GasPhysicalProperties.class); @@ -52,7 +52,6 @@ public GasPhysicalProperties(PhaseInterface phase, int binaryDiffusionCoefficien densityCalc = new neqsim.physicalproperties.physicalpropertymethods.gasphysicalproperties.density.Density( this); - // this.init(phase); } /** {@inheritDoc} */ diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/CO2waterPhysicalProperties.java b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/CO2waterPhysicalProperties.java index d2c30b0087..60a8e13935 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/CO2waterPhysicalProperties.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/CO2waterPhysicalProperties.java @@ -6,6 +6,7 @@ import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.density.Density; import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.diffusivity.CO2water; import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.viscosity.Viscosity; +import neqsim.physicalproperties.physicalpropertysystem.PhysicalProperties; import neqsim.thermo.phase.PhaseInterface; /** @@ -16,8 +17,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class CO2waterPhysicalProperties - extends neqsim.physicalproperties.physicalpropertysystem.PhysicalProperties { +public class CO2waterPhysicalProperties extends PhysicalProperties { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(CO2waterPhysicalProperties.class); diff --git a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/LiquidPhysicalProperties.java b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/LiquidPhysicalProperties.java index 9dc8a20413..90d401f612 100644 --- a/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/LiquidPhysicalProperties.java +++ b/src/main/java/neqsim/physicalproperties/physicalpropertysystem/liquidphysicalproperties/LiquidPhysicalProperties.java @@ -12,6 +12,7 @@ import neqsim.physicalproperties.physicalpropertymethods.commonphasephysicalproperties.viscosity.PFCTViscosityMethodHeavyOil; import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.density.Density; import neqsim.physicalproperties.physicalpropertymethods.liquidphysicalproperties.diffusivity.SiddiqiLucasMethod; +import neqsim.physicalproperties.physicalpropertysystem.PhysicalProperties; import neqsim.thermo.phase.PhaseInterface; /** @@ -22,8 +23,7 @@ * @author Even Solbraa * @version $Id: $Id */ -public class LiquidPhysicalProperties - extends neqsim.physicalproperties.physicalpropertysystem.PhysicalProperties { +public class LiquidPhysicalProperties extends PhysicalProperties { private static final long serialVersionUID = 1000; static Logger logger = LogManager.getLogger(LiquidPhysicalProperties.class); diff --git a/src/main/java/neqsim/processsimulation/measurementdevice/FlowInducedVibrationAnalyser.java b/src/main/java/neqsim/processsimulation/measurementdevice/FlowInducedVibrationAnalyser.java index 69dbfc855d..d403c3e724 100644 --- a/src/main/java/neqsim/processsimulation/measurementdevice/FlowInducedVibrationAnalyser.java +++ b/src/main/java/neqsim/processsimulation/measurementdevice/FlowInducedVibrationAnalyser.java @@ -162,7 +162,7 @@ public void setFRMSConstant(double frms) { /** *

- * Setter for the support arrangement supportArrangement. + * Setter for the supportArrangement. *

* * @param arrangement a {@link java.lang.String} object @@ -173,7 +173,7 @@ public void setSupportArrangement(String arrangement) { /** *

- * Setter for the support distance . + * Setter for the supportDistance. *

* * @param distance a {@link java.lang.Double} object diff --git a/src/main/java/neqsim/thermo/component/ComponentGEUniquacmodifiedHV.java b/src/main/java/neqsim/thermo/component/ComponentGEUniquacmodifiedHV.java index 86d78508fa..609e32ab32 100644 --- a/src/main/java/neqsim/thermo/component/ComponentGEUniquacmodifiedHV.java +++ b/src/main/java/neqsim/thermo/component/ComponentGEUniquacmodifiedHV.java @@ -14,7 +14,7 @@ * * @author Even Solbraa */ -abstract class ComponentGEUniquacmodifiedHV extends ComponentGEUniquac { +public abstract class ComponentGEUniquacmodifiedHV extends ComponentGEUniquac { private static final long serialVersionUID = 1000; /** diff --git a/src/main/java/neqsim/thermo/component/ComponentPrCPA.java b/src/main/java/neqsim/thermo/component/ComponentPrCPA.java index 2f42683da4..a261a4e6e6 100644 --- a/src/main/java/neqsim/thermo/component/ComponentPrCPA.java +++ b/src/main/java/neqsim/thermo/component/ComponentPrCPA.java @@ -8,7 +8,7 @@ * * @author Even Solbraa */ -abstract class ComponentPrCPA extends ComponentPR implements ComponentCPAInterface { +public abstract class ComponentPrCPA extends ComponentPR implements ComponentCPAInterface { private static final long serialVersionUID = 1000; int cpaon = 1;