Skip to content

Commit 6e6263c

Browse files
committed
refact: reorder code
1 parent 2689d9a commit 6e6263c

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

src/main/java/neqsim/chemicalReactions/chemicalReaction/ChemicalReaction.java

+18-18
Original file line numberDiff line numberDiff line change
@@ -131,24 +131,6 @@ public double getRateFactor(PhaseInterface phase) {
131131
return 2.576e9 * Math.exp(-6024.0 / phase.getTemperature()) / 1000.0;
132132
}
133133

134-
/**
135-
* <p>
136-
* getK.
137-
* </p>
138-
*
139-
* @param phase a {@link neqsim.thermo.phase.PhaseInterface} object
140-
* @return a double
141-
*/
142-
public double getK(PhaseInterface phase) {
143-
double temperature = phase.getTemperature();
144-
lnK = K[0] + K[1] / (temperature) + K[2] * Math.log(temperature) + K[3] * temperature;
145-
if (shiftSignK) {
146-
lnK = -lnK;
147-
}
148-
// System.out.println("K " + Math.exp(lnK));
149-
return Math.exp(lnK);
150-
}
151-
152134
/**
153135
* <p>
154136
* Getter for the field <code>stocCoefs</code>.
@@ -468,6 +450,24 @@ public double[] getK() {
468450
return this.K;
469451
}
470452

453+
/**
454+
* <p>
455+
* getK.
456+
* </p>
457+
*
458+
* @param phase a {@link neqsim.thermo.phase.PhaseInterface} object
459+
* @return a double
460+
*/
461+
public double getK(PhaseInterface phase) {
462+
double temperature = phase.getTemperature();
463+
lnK = K[0] + K[1] / (temperature) + K[2] * Math.log(temperature) + K[3] * temperature;
464+
if (shiftSignK) {
465+
lnK = -lnK;
466+
}
467+
// System.out.println("K " + Math.exp(lnK));
468+
return Math.exp(lnK);
469+
}
470+
471471
/**
472472
* Setter for property k.
473473
*

0 commit comments

Comments
 (0)