Skip to content

chore: clean up workflows #585

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 25, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,8 @@ public double getZsaturation() {
}

/**
* <p>Getter for the field <code>saturationTemperature</code>.</p>
*
* @return the saturationTemperature
*/
public double getSaturationTemperature() {
Expand Down
11 changes: 11 additions & 0 deletions src/main/java/neqsim/api/ioc/CalculationResult.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,26 @@
import java.util.Arrays;

/**
* <p>CalculationResult class.</p>
*
* @author jo.lyshoel
* @version $Id: $Id
*/
public class CalculationResult {
public Double[][] fluidProperties;
public String[] calculationError;

/**
* <p>Constructor for CalculationResult.</p>
*/
public CalculationResult() {}

/**
* <p>Constructor for CalculationResult.</p>
*
* @param fluidProperties an array of {@link java.lang.Double} objects
* @param calculationError an array of {@link java.lang.String} objects
*/
public CalculationResult(Double[][] fluidProperties, String[] calculationError) {
this.fluidProperties = fluidProperties;
this.calculationError = calculationError;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@
public class ChemicalReactionFactory {
static Logger logger = LogManager.getLogger(ChemicalReactionFactory.class);

/**
* <p>Constructor for ChemicalReactionFactory.</p>
*/
public ChemicalReactionFactory() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ default public void display() {

/**
* Specify wall friction factor for phase 0. Set to null to reset.
*
*
* @param frictionFactor Friction factor to use for phase 0 or null to reset.
*/
default public void setWallFrictionFactor(double frictionFactor) {
Expand All @@ -736,7 +736,7 @@ default public void setWallFrictionFactor(double frictionFactor) {

/**
* Specify wall friction factor for a given phase. Set to null to reset.
*
*
* @param phase Index to phase to set wall friction factor for.
* @param frictionFactor Friction factor to use for a given phase or null to reset.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
*/
public class InterphaseTransportCoefficientBaseClass
implements InterphaseTransportCoefficientInterface {
/**
* <p>Constructor for InterphaseTransportCoefficientBaseClass.</p>
*/
public InterphaseTransportCoefficientBaseClass() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* @version $Id: $Id
*/
public class InterphaseOnePhase extends InterphaseTransportCoefficientBaseClass {
/**
* <p>Constructor for InterphaseOnePhase.</p>
*/
public InterphaseOnePhase() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* @version $Id: $Id
*/
public class InterphasePipeFlow extends InterphaseOnePhase {
/**
* <p>Constructor for InterphasePipeFlow.</p>
*/
public InterphasePipeFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* @version $Id: $Id
*/
public class InterphaseTwoPhase extends InterphaseTransportCoefficientBaseClass {
/**
* <p>Constructor for InterphaseTwoPhase.</p>
*/
public InterphaseTwoPhase() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
public class InterphaseAnnularFlow extends InterphaseStratifiedFlow {
private static final long serialVersionUID = 1000;

/**
* <p>Constructor for InterphaseAnnularFlow.</p>
*/
public InterphaseAnnularFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public class InterphaseDropletFlow extends InterphaseTwoPhasePipeFlow
implements neqsim.thermo.ThermodynamicConstantsInterface {
private static final long serialVersionUID = 1000;

/**
* <p>Constructor for InterphaseDropletFlow.</p>
*/
public InterphaseDropletFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public class InterphaseStratifiedFlow extends InterphaseTwoPhasePipeFlow
implements neqsim.thermo.ThermodynamicConstantsInterface {
private static final long serialVersionUID = 1000;

/**
* <p>Constructor for InterphaseStratifiedFlow.</p>
*/
public InterphaseStratifiedFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* @version $Id: $Id
*/
public class InterphaseTwoPhasePipeFlow extends InterphaseTwoPhase {
/**
* <p>Constructor for InterphaseTwoPhasePipeFlow.</p>
*/
public InterphaseTwoPhasePipeFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ public class InterphasePackedBed extends InterphaseReactorFlow
implements neqsim.thermo.ThermodynamicConstantsInterface {
private static final long serialVersionUID = 1000;

/**
* <p>Constructor for InterphasePackedBed.</p>
*/
public InterphasePackedBed() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* @version $Id: $Id
*/
public class InterphaseReactorFlow extends InterphaseTwoPhase {
/**
* <p>Constructor for InterphaseReactorFlow.</p>
*/
public InterphaseReactorFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
public class InterphaseStirredCellFlow extends InterphaseStratifiedFlow {
private static final long serialVersionUID = 1000;

/**
* <p>Constructor for InterphaseStirredCellFlow.</p>
*/
public InterphaseStirredCellFlow() {}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -350,13 +350,11 @@ public double getKinematicViscosity() {
}

/**
* {@inheritDoc}
*
* <p>
* getDiffusionCoefficient.
* </p>
*
* @param i a int
* @param j a int
* @return a double
*/
public double getDiffusionCoefficient(int i, int j) {
return diffusivityCalc.getMaxwellStefanBinaryDiffusionCoefficient(i, j);
Expand Down
20 changes: 18 additions & 2 deletions src/main/java/neqsim/processSimulation/SimulationBaseClass.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

/**
* Base class for process simulation objects.
*
* @author ASMF
* @version $Id: $Id
*/
public abstract class SimulationBaseClass extends NamedBaseClass implements SimulationInterface {
private static final long serialVersionUID = 1L;
Expand All @@ -16,11 +19,20 @@ public abstract class SimulationBaseClass extends NamedBaseClass implements Simu
protected boolean calculateSteadyState = true;
protected double time = 0;

/**
* <p>Constructor for SimulationBaseClass.</p>
*
* @param name a {@link java.lang.String} object
*/
public SimulationBaseClass(String name) {
super(name);
}

/** {@inheritDoc} */
/**
* {@inheritDoc}
*
* @return a {@link java.util.UUID} object
*/
public UUID getCalculationIdentifier() {
return calcIdentifier;
}
Expand All @@ -46,7 +58,11 @@ public void setCalculateSteadyState(boolean steady) {
this.calculateSteadyState = steady;
}

/** {@inheritDoc} */
/**
* {@inheritDoc}
*
* @return a double
*/
public double getTime() {
return this.time;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@

/**
* Interface for simulation objects.
*
* @author ASMF
* @version $Id: $Id
*/
public interface SimulationInterface extends NamedInterface, Runnable {
/**
Expand Down Expand Up @@ -57,6 +60,8 @@ public interface SimulationInterface extends NamedInterface, Runnable {
public void increaseTime(double dt);

/**
* {@inheritDoc}
*
* <p>
* run
* </p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ public class ControllerDeviceBaseClass extends NamedBaseClass implements Control
private double TintValue = 0.0;
private double Tderiv = 300.0;

/**
* <p>Constructor for ControllerDeviceBaseClass.</p>
*/
public ControllerDeviceBaseClass() {
super("controller");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ public CostEstimateBaseClass(ProcessSystem process) {
}

/**
*
* <p>Constructor for CostEstimateBaseClass.</p>
*
* @param process input process
* @param costFactor cost factor
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public ValveCostEstimate(ValveMechanicalDesign mechanicalEquipment) {
super(mechanicalEquipment);
}

/** {@inheritDoc} */
/** {@inheritDoc} */
@Override
public double getTotaltCost() {
ValveMechanicalDesign valveMecDesign = (ValveMechanicalDesign) mechanicalEquipment;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ public void setIsOnlineSignal(boolean isOnlineSignal, String plantName, String t
private String conditionAnalysisMessage = "";
private double conditionAnalysisMaxDeviation = 0.0;

/**
* <p>Constructor for MeasurementDeviceBaseClass.</p>
*/
public MeasurementDeviceBaseClass() {
super("default");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ public class MultiPhaseMeter extends MeasurementDeviceBaseClass {
double pressure = 10.0, temperature = 298.15;
String unitT, unitP;

/**
* <p>Constructor for MultiPhaseMeter.</p>
*/
public MultiPhaseMeter() {
name = "Multi Phase Meter";
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ public class TemperatureTransmitter extends MeasurementDeviceBaseClass {
private static final long serialVersionUID = 1000;
protected StreamInterface stream = null;

/**
* <p>Constructor for TemperatureTransmitter.</p>
*/
public TemperatureTransmitter() {
name = "Temperature Transmitter";
unit = "K";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,31 +7,61 @@
import neqsim.thermo.system.SystemInterface;
import neqsim.thermo.system.SystemSrkEos;

/**
* <p>WellAllocator class.</p>
*
* @author ASMF
* @version $Id: $Id
*/
public class WellAllocator extends MeasurementDeviceBaseClass {

private static final long serialVersionUID = 1L;
protected StreamInterface wellStream = null;
protected StreamInterface exportGasStream = null;
protected StreamInterface exportOilStream = null;

/**
* <p>Constructor for WellAllocator.</p>
*/
public WellAllocator() {
name = "Well Allocator";
}

/**
* <p>Constructor for WellAllocator.</p>
*
* @param stream a {@link neqsim.processSimulation.processEquipment.stream.StreamInterface} object
*/
public WellAllocator(StreamInterface stream) {
name = "Well Allocator";
this.wellStream = stream;
}

/**
* <p>Constructor for WellAllocator.</p>
*
* @param streamname a {@link java.lang.String} object
* @param stream a {@link neqsim.processSimulation.processEquipment.stream.StreamInterface} object
*/
public WellAllocator(String streamname, StreamInterface stream) {
this(stream);
name = streamname;
}

/**
* <p>Setter for the field <code>exportGasStream</code>.</p>
*
* @param stream a {@link neqsim.processSimulation.processEquipment.stream.StreamInterface} object
*/
public void setExportGasStream(StreamInterface stream) {
this.exportGasStream = stream;
}

/**
* <p>Setter for the field <code>exportOilStream</code>.</p>
*
* @param stream a {@link neqsim.processSimulation.processEquipment.stream.StreamInterface} object
*/
public void setExportOilStream(StreamInterface stream) {
this.exportOilStream = stream;
}
Expand Down Expand Up @@ -70,6 +100,11 @@ public double getMeasuredValue(String measurement) {
return 0.0;
}

/**
* <p>main.</p>
*
* @param args an array of {@link java.lang.String} objects
*/
public static void main(String[] args) {
SystemInterface testFluid = new SystemSrkEos(338.15, 50.0);
testFluid.addComponent("nitrogen", 1.205);
Expand Down
Loading