Class ThreePhaseSeparator
java.lang.Object
neqsim.util.NamedBaseClass
neqsim.process.SimulationBaseClass
neqsim.process.equipment.ProcessEquipmentBaseClass
neqsim.process.equipment.separator.Separator
neqsim.process.equipment.separator.ThreePhaseSeparator
- All Implemented Interfaces:
Serializable, Runnable, ProcessEquipmentInterface, SeparatorInterface, StateVectorProvider, SimulationInterface, NamedInterface
ThreePhaseSeparator class.
- Version:
- $Id: $Id
- Author:
- Even Solbraa
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class Separator
Separator.Builder -
Field Summary
FieldsModifier and TypeFieldDescription(package private) double(package private) String(package private) double(package private) String(package private) double(package private) String(package private) double(package private) Stringprivate doubleGas outlet valve flow fraction (0.0 = fully closed, 1.0 = fully open).private doubleprivate doubleprivate double(package private) static org.apache.logging.log4j.LoggerLogger object for class.(package private) double(package private) String(package private) double(package private) Stringprivate doubleOil level height in meters (bottom of separator to top of oil phase).private doubleOil outlet valve flow fraction (0.0 = fully closed, 1.0 = fully open).private static final longSerialization version UID.(package private) String(package private) booleanprivate doubleWater level height in meters (bottom of separator to water-oil interface).private doubleWater outlet valve flow fraction (0.0 = fully closed, 1.0 = fully open).(package private) StreamInterfaceFields inherited from class Separator
gasOutStream, gasSystem, gasVolume, inletStreamMixer, isInitTransient, liquidLevel, liquidOutStream, liquidSystem, liquidVolume, numberOfInputStreams, separatorMechanicalDesign, separatorSection, thermoSystem, thermoSystem2, thermoSystemCloned, waterSystemFields inherited from class ProcessEquipmentBaseClass
conditionAnalysisMessage, energyStream, hasController, isSolved, properties, reportFields inherited from class SimulationBaseClass
calcIdentifier, calculateSteadyState, timeFields inherited from class NamedBaseClass
name -
Constructor Summary
ConstructorsConstructorDescriptionThreePhaseSeparator(String name) Constructor for ThreePhaseSeparator.ThreePhaseSeparator(String name, StreamInterface inletStream) Constructor for ThreePhaseSeparator. -
Method Summary
Modifier and TypeMethodDescriptionvoiddisplayResult.doublegetEntropyProduction(String unit) getEntropyProduction.doublegetExergyChange(String unit, double surroundingTemperature) Get exergy change production of the process equipment.doubleGet the gas outlet valve flow fraction.doublegetMassBalance(String unit) getMassBalance.doubleGet the oil level (height from bottom of separator to top of oil phase).doubleGet the oil outlet valve flow fraction.getOilOutStream.doubleGet the oil phase thickness (oil level minus water level).doubleGet the water level (height from bottom of separator to water-oil interface).doubleGet the water outlet valve flow fraction.Getter for the fieldwaterOutStream.voidInitializes three-phase separator for transient calculations.voidIn this method all thermodynamic and unit operations will be calculated in a steady state calculation.voidrunTransient(double dt, UUID id) runTransientvoidsetEntrainment(double val, String specType, String specifiedStream, String phaseFrom, String phaseTo) setEntrainment.voidsetGasOutletFlowFraction(double fraction) Set the gas outlet valve flow fraction (simulates valve position).voidsetInletStream(StreamInterface inletStream) setInletStream.voidsetOilLevel(double level) Set the oil level (height from bottom of separator to top of oil phase).voidsetOilOutletFlowFraction(double fraction) Set the oil outlet valve flow fraction (simulates valve position).voidsetTempPres(double temp, double pres) setTempPres.voidsetWaterLevel(double level) Set the water level (height from bottom of separator to water-oil interface).voidsetWaterOutletFlowFraction(double fraction) Set the water outlet valve flow fraction (simulates valve position).toJson()Serializes the Process Equipment along with its state to a JSON string.toJson(ReportConfig cfg) Serializes the Process Equipment with configurable level of detail.private voidUpdates the parent class liquidLevel based on water and oil levels.private voidUpdates water and oil levels from phase volumes in the thermodynamic system.Methods inherited from class Separator
addSeparatorSection, addStream, builder, calcLiquidVolume, enforceHeadspace, equals, evaluateFireExposure, evaluateFireExposure, getCapacityDuty, getCapacityMax, getDeRatedGasLoadFactor, getDeRatedGasLoadFactor, getDesignLiquidLevelFraction, getEfficiency, getExergyChange, getFeedStream, getGas, getGasCarryunderFraction, getGasLoadFactor, getGasLoadFactor, getGasOutStream, getGasSuperficialVelocity, getHeatDuty, getHeatDuty, getHeatInput, getHeatInput, getInnerSurfaceArea, getInternalDiameter, getLiquid, getLiquidCarryoverFraction, getLiquidLevel, getLiquidOutStream, getMechanicalDesign, getOrientation, getPressure, getPressureDrop, getResultTable, getSeparatorLength, getSeparatorSection, getSeparatorSection, getSeparatorSections, getStateVector, getThermoSystem, getUnwettedArea, getWettedArea, hashCode, initMechanicalDesign, isSetHeatInput, levelFromVolume, liquidArea, setDesignLiquidLevelFraction, setDuty, setDuty, setEfficiency, setGasCarryunderFraction, setHeatDuty, setHeatDuty, setHeatInput, setHeatInput, setInternalDiameter, setLiquidCarryoverFraction, setLiquidLevel, setOrientation, setPressureDrop, setSeparatorLength, validateSetupMethods inherited from class ProcessEquipmentBaseClass
copy, getConditionAnalysisMessage, getController, getEnergyStream, getMassBalance, getMinimumFlow, getPressure, getProperty, getReport_json, getSpecification, getTemperature, getTemperature, isActive, isActive, isSetEnergyStream, reportResults, run_step, runConditionAnalysis, setController, setEnergyStream, setEnergyStream, setFlowValveController, setMinimumFlow, setPressure, setRegulatorOutSignal, setSpecification, setTemperature, solvedMethods inherited from class SimulationBaseClass
getCalculateSteadyState, getCalculationIdentifier, getTime, increaseTime, isRunInSteps, setCalculateSteadyState, setCalculationIdentifier, setRunInSteps, setTimeMethods inherited from class NamedBaseClass
getName, getTagName, setName, setTagNameMethods inherited from class Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface NamedInterface
getName, getTagName, setName, setTagNameMethods inherited from interface ProcessEquipmentInterface
getFluid, getRestCapacity, needRecalculationMethods inherited from interface SimulationInterface
getCalculateSteadyState, getCalculationIdentifier, getTime, increaseTime, isRunInSteps, run, run_step, run_step, runTransient, setCalculateSteadyState, setCalculationIdentifier, setRunInSteps, setTime, solvedMethods inherited from interface StateVectorProvider
getStateDimension, getStateNames
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDSerialization version UID.- See Also:
-
logger
static org.apache.logging.log4j.Logger loggerLogger object for class. -
waterOutStream
StreamInterface waterOutStream -
specifiedStream
String specifiedStream -
gasInAqueous
double gasInAqueous -
gasInAqueousSpec
String gasInAqueousSpec -
gasInOil
double gasInOil -
gasInOilSpec
String gasInOilSpec -
oilInGas
double oilInGas -
oilInGasSpec
String oilInGasSpec -
oilInAqueous
double oilInAqueous -
oilInAqueousSpec
String oilInAqueousSpec -
aqueousInGas
double aqueousInGas -
aqueousInGasSpec
String aqueousInGasSpec -
aqueousInOil
double aqueousInOil -
aqueousInOilSpec
String aqueousInOilSpec -
useTempMultiPhaseCheck
boolean useTempMultiPhaseCheck -
lastEnthalpy
private double lastEnthalpy -
lastFlowRate
private double lastFlowRate -
lastPressure
private double lastPressure -
waterLevel
private double waterLevelWater level height in meters (bottom of separator to water-oil interface). -
oilLevel
private double oilLevelOil level height in meters (bottom of separator to top of oil phase). -
gasOutletFlowFraction
private double gasOutletFlowFractionGas outlet valve flow fraction (0.0 = fully closed, 1.0 = fully open). -
oilOutletFlowFraction
private double oilOutletFlowFractionOil outlet valve flow fraction (0.0 = fully closed, 1.0 = fully open). -
waterOutletFlowFraction
private double waterOutletFlowFractionWater outlet valve flow fraction (0.0 = fully closed, 1.0 = fully open).
-
-
Constructor Details
-
ThreePhaseSeparator
Constructor for ThreePhaseSeparator.- Parameters:
name- name of separator
-
ThreePhaseSeparator
Constructor for ThreePhaseSeparator.
- Parameters:
name- aStringobjectinletStream- aStreamInterfaceobject
-
-
Method Details
-
setEntrainment
-
setInletStream
setInletStream.
- Overrides:
setInletStreamin classSeparator- Parameters:
inletStream- aStreamInterfaceobject
-
getWaterOutStream
Getter for the field
waterOutStream.- Returns:
- a
StreamInterfaceobject
-
getOilOutStream
-
setWaterLevel
public void setWaterLevel(double level) Set the water level (height from bottom of separator to water-oil interface).- Parameters:
level- water level in meters
-
getWaterLevel
public double getWaterLevel()Get the water level (height from bottom of separator to water-oil interface).- Returns:
- water level in meters
-
setOilLevel
public void setOilLevel(double level) Set the oil level (height from bottom of separator to top of oil phase).- Parameters:
level- oil level in meters
-
getOilLevel
public double getOilLevel()Get the oil level (height from bottom of separator to top of oil phase).- Returns:
- oil level in meters
-
getOilThickness
public double getOilThickness()Get the oil phase thickness (oil level minus water level).- Returns:
- oil thickness in meters
-
setGasOutletFlowFraction
public void setGasOutletFlowFraction(double fraction) Set the gas outlet valve flow fraction (simulates valve position).- Parameters:
fraction- flow fraction (0.0 = fully closed, 1.0 = fully open)
-
getGasOutletFlowFraction
public double getGasOutletFlowFraction()Get the gas outlet valve flow fraction.- Returns:
- flow fraction (0.0 = fully closed, 1.0 = fully open)
-
setOilOutletFlowFraction
public void setOilOutletFlowFraction(double fraction) Set the oil outlet valve flow fraction (simulates valve position).- Parameters:
fraction- flow fraction (0.0 = fully closed, 1.0 = fully open)
-
getOilOutletFlowFraction
public double getOilOutletFlowFraction()Get the oil outlet valve flow fraction.- Returns:
- flow fraction (0.0 = fully closed, 1.0 = fully open)
-
setWaterOutletFlowFraction
public void setWaterOutletFlowFraction(double fraction) Set the water outlet valve flow fraction (simulates valve position).- Parameters:
fraction- flow fraction (0.0 = fully closed, 1.0 = fully open)
-
getWaterOutletFlowFraction
public double getWaterOutletFlowFraction()Get the water outlet valve flow fraction.- Returns:
- flow fraction (0.0 = fully closed, 1.0 = fully open)
-
updateLiquidLevelFromWaterAndOil
private void updateLiquidLevelFromWaterAndOil()Updates the parent class liquidLevel based on water and oil levels. -
updateWaterAndOilLevelsFromPhases
private void updateWaterAndOilLevelsFromPhases()Updates water and oil levels from phase volumes in the thermodynamic system. -
run
In this method all thermodynamic and unit operations will be calculated in a steady state calculation.
- Specified by:
runin interfaceSimulationInterface- Overrides:
runin classSeparator- Parameters:
id- UUID
-
initializeTransientCalculation
public void initializeTransientCalculation()Initializes three-phase separator for transient calculations.- Overrides:
initializeTransientCalculationin classSeparator
-
runTransient
runTransient
This method calculates thermodynamic and unit operations using difference equations if available and calculateSteadyState is true. Use setCalculateSteadyState to set the parameter. Sets calc identifier UUID.- Specified by:
runTransientin interfaceSimulationInterface- Overrides:
runTransientin classSeparator- Parameters:
dt- Delta time [s]id- Calculation identifier
-
setTempPres
public void setTempPres(double temp, double pres) setTempPres.
- Overrides:
setTempPresin classSeparator- Parameters:
temp- a doublepres- a double
-
displayResult
public void displayResult()displayResult.
- Specified by:
displayResultin interfaceProcessEquipmentInterface- Overrides:
displayResultin classSeparator
-
getEntropyProduction
getEntropyProduction.
- Specified by:
getEntropyProductionin interfaceProcessEquipmentInterface- Overrides:
getEntropyProductionin classSeparator- Parameters:
unit- aStringobject- Returns:
- a double
-
getMassBalance
getMassBalance.
- Specified by:
getMassBalancein interfaceProcessEquipmentInterface- Overrides:
getMassBalancein classSeparator- Parameters:
unit- aStringobject- Returns:
- a double
-
getExergyChange
Get exergy change production of the process equipment.- Specified by:
getExergyChangein interfaceProcessEquipmentInterface- Overrides:
getExergyChangein classSeparator- Parameters:
unit- Supported units are J and kJsurroundingTemperature- The surrounding temperature in Kelvin- Returns:
- change in exergy in specified unit
-
toJson
Serializes the Process Equipment along with its state to a JSON string.
- Specified by:
toJsonin interfaceProcessEquipmentInterface- Overrides:
toJsonin classSeparator- Returns:
- json string.
-
toJson
Serializes the Process Equipment with configurable level of detail.- Specified by:
toJsonin interfaceProcessEquipmentInterface- Overrides:
toJsonin classSeparator- Parameters:
cfg- report configuration- Returns:
- json string
-