Class AdiabaticPipe
- All Implemented Interfaces:
Serializable, Runnable, PipeLineInterface, ProcessEquipmentInterface, TwoPortInterface, SimulationInterface, NamedInterface
- Direct Known Subclasses:
IncompressiblePipeFlow
AdiabaticPipe class.
- Version:
- $Id: $Id
- Author:
- Even Solbraa
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) double(package private) Stringprivate double(package private) double(package private) double(package private) doubleprivate double(package private) String(package private) doubleprotected doubleprivate static final longSerialization version UID.(package private) boolean(package private) booleanprotected double(package private) doubleFields inherited from class Pipeline
equilibriumHeatTransfer, equilibriumMassTransfer, fileName, legHeights, legPositions, logger, numberOfLegs, numberOfNodesInLeg, outerHeatTransferCoeffs, outerTemperature, pipe, pipeDiameters, pipelineMechanicalDesign, system, times, wallHeatTransferCoeffsFields inherited from class TwoPortEquipment
inStream, outStreamFields inherited from class ProcessEquipmentBaseClass
conditionAnalysisMessage, energyStream, hasController, isSolved, properties, reportFields inherited from class SimulationBaseClass
calcIdentifier, calculateSteadyState, timeFields inherited from class NamedBaseClass
name -
Constructor Summary
ConstructorsConstructorDescriptionAdiabaticPipe(String name) Constructor for AdiabaticPipe.AdiabaticPipe(String name, StreamInterface inStream) Constructor for AdiabaticPipe. -
Method Summary
Modifier and TypeMethodDescriptiondoublecalcFlow()calcFlow.doublecalcPressureOut.doublecalcWallFrictionFactor(double reynoldsNumber) calcWallFrictionFactor.voiddisplayResult.doublegetDiameter.doubleGetter for the fieldinletElevation.doubleGetter for the fieldlength.doubleGetter for the fieldoutletElevation.getPipe()getPipe.doubleGetter for the fieldpipeWallRoughness.static voidmain.voidIn this method all thermodynamic and unit operations will be calculated in a steady state calculation.voidsetDiameter(double diameter) setDiameter.voidsetInitialFlowPattern(String flowPattern) setInitialFlowPattern.voidsetInletElevation(double inletElevation) Setter for the fieldinletElevation.voidsetLength(double length) Setter for the fieldlength.voidsetOutletElevation(double outletElevation) Setter for the fieldoutletElevation.voidsetOutPressure(double pressure) setOutPressure.voidsetOutTemperature(double temperature) setOutTemperature.voidsetPipeSpecification(double nominalDiameter, String pipeSec) Setter for the fieldpipeSpecification.voidsetPipeWallRoughness(double pipeWallRoughness) Setter for the fieldpipeWallRoughness.Methods inherited from class Pipeline
getCapacityDuty, getCapacityMax, getEntropyProduction, getMechanicalDesign, getOutletPressure, getSuperficialVelocity, getTimes, initMechanicalDesign, runTransient, setEquilibriumHeatTransfer, setEquilibriumMassTransfer, setHeightProfile, setLegPositions, setNumberOfLegs, setNumberOfNodesInLeg, setOuterTemperatures, setOutputFileName, setPipeDiameters, setPipeOuterHeatTransferCoefficients, setPipeWallHeatTransferCoefficients, setPipeWallRoughness, setTimeSeries, toJson, toJsonMethods inherited from class TwoPortEquipment
getInletPressure, getInletStream, getInletTemperature, getMassBalance, getOutletPressure, getOutletStream, getOutletTemperature, setInletPressure, setInletStream, setInletTemperature, setOutletPressure, setOutletStream, setOutletTemperature, validateSetupMethods inherited from class ProcessEquipmentBaseClass
copy, equals, getConditionAnalysisMessage, getController, getEnergyStream, getExergyChange, getMassBalance, getMinimumFlow, getPressure, getPressure, getProperty, getReport_json, getResultTable, getSpecification, getTemperature, getTemperature, getThermoSystem, hashCode, 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
getExergyChange, 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 TwoPortInterface
getInletPressure, getInletStream, getInletTemperature, getInStream, getOutletPressure, getOutletStream, getOutletTemperature, getOutStream, setInletPressure, setInletStream, setInletTemperature, setOutletPressure, setOutletStream, setOutletTemperature
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDSerialization version UID.- See Also:
-
inletPressure
double inletPressure -
setTemperature
boolean setTemperature -
setPressureOut
boolean setPressureOut -
temperatureOut
protected double temperatureOut -
pressureOut
protected double pressureOut -
length
double length -
insideDiameter
double insideDiameter -
velocity
double velocity -
pipeWallRoughness
double pipeWallRoughness -
inletElevation
private double inletElevation -
outletElevation
private double outletElevation -
dH
double dH -
flowPattern
String flowPattern -
pipeSpecification
String pipeSpecification
-
-
Constructor Details
-
AdiabaticPipe
-
AdiabaticPipe
Constructor for AdiabaticPipe.- Parameters:
name- name of pipeinStream- input stream
-
-
Method Details
-
setPipeSpecification
-
setOutTemperature
public void setOutTemperature(double temperature) setOutTemperature.
- Parameters:
temperature- a double
-
setOutPressure
public void setOutPressure(double pressure) setOutPressure.
- Parameters:
pressure- a double
-
calcWallFrictionFactor
public double calcWallFrictionFactor(double reynoldsNumber) calcWallFrictionFactor.
- Parameters:
reynoldsNumber- a double- Returns:
- a double
-
calcPressureOut
public double calcPressureOut()calcPressureOut.
- Returns:
- a double
-
calcFlow
public double calcFlow()calcFlow.
Calculates the flow rate required to achieve the specified outlet pressure using bisection iteration. This method iteratively adjusts the flow rate until the calculated outlet pressure matches the target outlet pressure (pressureOut).
- Returns:
- the calculated flow rate in the current system units
-
run
In this method all thermodynamic and unit operations will be calculated in a steady state calculation.
- Specified by:
runin interfaceSimulationInterface- Overrides:
runin classPipeline- Parameters:
id- UUID
-
displayResult
public void displayResult()displayResult.
- Specified by:
displayResultin interfaceProcessEquipmentInterface- Overrides:
displayResultin classPipeline
-
getPipe
getPipe.
- Specified by:
getPipein interfacePipeLineInterface- Overrides:
getPipein classPipeline- Returns:
- a
FlowSystemInterfaceobject
-
setInitialFlowPattern
setInitialFlowPattern.
- Specified by:
setInitialFlowPatternin interfacePipeLineInterface- Overrides:
setInitialFlowPatternin classPipeline- Parameters:
flowPattern- aStringobject
-
getLength
public double getLength()Getter for the field
length.- Returns:
- the length
-
setLength
public void setLength(double length) Setter for the field
length.- Parameters:
length- the length to set
-
getDiameter
public double getDiameter()getDiameter.
- Returns:
- the diameter
-
setDiameter
public void setDiameter(double diameter) setDiameter.
- Parameters:
diameter- the diameter to set
-
getPipeWallRoughness
public double getPipeWallRoughness()Getter for the field
pipeWallRoughness.- Returns:
- the pipeWallRoughness
-
setPipeWallRoughness
public void setPipeWallRoughness(double pipeWallRoughness) Setter for the field
pipeWallRoughness.- Parameters:
pipeWallRoughness- the pipeWallRoughness to set
-
getInletElevation
public double getInletElevation()Getter for the field
inletElevation.- Returns:
- the inletElevation
-
setInletElevation
public void setInletElevation(double inletElevation) Setter for the field
inletElevation.- Parameters:
inletElevation- the inletElevation to set
-
getOutletElevation
public double getOutletElevation()Getter for the field
outletElevation.- Returns:
- the outletElevation
-
setOutletElevation
public void setOutletElevation(double outletElevation) Setter for the field
outletElevation.- Parameters:
outletElevation- the outletElevation to set
-
main
-