@@ -122,7 +122,8 @@ void testSetAllocationComposition() throws IOException {
122
122
assertEquals (0.0046202437 , x_methane_A19 , 1e-9 );
123
123
124
124
// double[][] interactionParams =
125
- // ((PhaseEos) testSystem.getPhase(0)).getMixingRule().getBinaryInteractionParameters();
125
+ // ((PhaseEos)
126
+ // testSystem.getPhase(0)).getMixingRule().getBinaryInteractionParameters();
126
127
127
128
// System.out.println(Arrays.deepToString(interactionParams));
128
129
}
@@ -134,7 +135,8 @@ void testReadFluid1() throws IOException {
134
135
testSystem .setPressure (50.0 , "bara" );
135
136
136
137
// neqsim.thermo.util.readwrite.TablePrinter.printTable(
137
- // (((PhaseEos) testSystem.getPhase(0)).getMixingRule().getBinaryInteractionParameters()));
138
+ // (((PhaseEos)
139
+ // testSystem.getPhase(0)).getMixingRule().getBinaryInteractionParameters()));
138
140
139
141
// for (int i = 0; i < testSystem.getNumberOfComponents(); i++) {
140
142
// System.out.println(testSystem.getComponent(i).getName() + " TC "
@@ -173,8 +175,8 @@ void testFluidWater() throws IOException {
173
175
174
176
// testSystem.prettyPrint();
175
177
176
- neqsim .thermo .util .readwrite .TablePrinter .printTable (
177
- (((PhaseEos ) testSystem .getPhase (0 )).getMixingRule ().getBinaryInteractionParameters ()));
178
+ // neqsim.thermo.util.readwrite.TablePrinter.printTable(
179
+ // (((PhaseEos) testSystem.getPhase(0)).getMixingRule().getBinaryInteractionParameters()));
178
180
double [][] paramsPhase0 =
179
181
((PhaseEos ) testSystem .getPhase (0 )).getMixingRule ().getBinaryInteractionParameters ();
180
182
double [][] paramsPhase1 =
@@ -190,4 +192,28 @@ void testFluidWater() throws IOException {
190
192
}
191
193
}
192
194
}
195
+
196
+ @ Test
197
+ void testFluidWater2 () throws IOException {
198
+ testSystem = EclipseFluidReadWrite .read (fluid_water );
199
+ testSystem .setMultiPhaseCheck (true );
200
+
201
+ // testSystem.init(0);
202
+
203
+ double molcomp [] = new double [] {.005823483446243756 , 0.011911670685498591 , 0.7510528953701038 ,
204
+ 0.06432302170169239 , 0.027440959875481938 , 0.003176445516132957 , 0.0068822986182880755 ,
205
+ 0.0015882227580664785 , 0.002029395746418279 , 0.0018529265510775586 , 0.0021176303440886383 ,
206
+ 0.001235284367385039 , 0.001235284367385039 , 0.0008823459767035993 , 0.00044117298835179964 ,
207
+ 0.00017646919534071987 , 0.00405500399809711783049249174136 };
208
+
209
+ testSystem .setMolarComposition (molcomp );
210
+
211
+ ThermodynamicOperations testOps = new ThermodynamicOperations (testSystem );
212
+ testSystem .setPressure (60.0 , "bara" );
213
+ testSystem .setTemperature (65.0 , "C" );
214
+ testOps .TPflash ();
215
+
216
+ Assertions .assertEquals (3 , testSystem .getNumberOfPhases ());
217
+
218
+ }
193
219
}
0 commit comments