From c4d0196e1bcc85c2389f44dda4a30dafa131b96e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=85smund=20V=C3=A5ge=20Fannemel?= <34712686+asmfstatoil@users.noreply.github.com> Date: Tue, 27 Feb 2024 16:15:01 +0100 Subject: [PATCH] refact: logger error -> warn --- .gitignore | 3 +++ .../chemicalReaction/ChemicalReactionList.java | 2 +- .../surfaceTension/GTSurfaceTensionFullGT.java | 2 +- .../physicalPropertyMethods/PhysicalPropertyMethod.java | 2 +- .../java/neqsim/thermo/component/ComponentGEUnifacUMRPRU.java | 2 +- src/main/java/neqsim/thermo/phase/PhaseEos.java | 2 +- 6 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 9757544c8..b873bed13 100644 --- a/.gitignore +++ b/.gitignore @@ -87,3 +87,6 @@ test_*.ser html/ latex/ eclipse_dictionary.txt + +src/main/**/*.png +src/main/**/*.gif diff --git a/src/main/java/neqsim/chemicalReactions/chemicalReaction/ChemicalReactionList.java b/src/main/java/neqsim/chemicalReactions/chemicalReaction/ChemicalReactionList.java index 44de80d17..2fe125bd2 100644 --- a/src/main/java/neqsim/chemicalReactions/chemicalReaction/ChemicalReactionList.java +++ b/src/main/java/neqsim/chemicalReactions/chemicalReaction/ChemicalReactionList.java @@ -112,7 +112,7 @@ public void readReactions(SystemInterface system) { } } while (dataSet.next()); } catch (Exception ex) { - logger.error("could not add reacton: ", ex); + logger.error("could not add reaction: ", ex); } } diff --git a/src/main/java/neqsim/physicalProperties/interfaceProperties/surfaceTension/GTSurfaceTensionFullGT.java b/src/main/java/neqsim/physicalProperties/interfaceProperties/surfaceTension/GTSurfaceTensionFullGT.java index 3e46e3e5c..af07d9107 100644 --- a/src/main/java/neqsim/physicalProperties/interfaceProperties/surfaceTension/GTSurfaceTensionFullGT.java +++ b/src/main/java/neqsim/physicalProperties/interfaceProperties/surfaceTension/GTSurfaceTensionFullGT.java @@ -709,7 +709,7 @@ public static void initmu(SystemInterface sys, int ncomp, double t, double[] rho maxerr = Math.max(maxerr, Math.abs(mueq[i] / mueq2[i] - 1.0)); } if (maxerr > reltol) { - logger.error("Flash is not properly solved. Maximum relative error in chemical potential: " + logger.warn("Flash is not properly solved. Maximum relative error in chemical potential: " + maxerr + " > " + reltol); throw new RuntimeException("Flash not solved!"); } diff --git a/src/main/java/neqsim/physicalProperties/physicalPropertyMethods/PhysicalPropertyMethod.java b/src/main/java/neqsim/physicalProperties/physicalPropertyMethods/PhysicalPropertyMethod.java index d723aa392..6f72f4806 100644 --- a/src/main/java/neqsim/physicalProperties/physicalPropertyMethods/PhysicalPropertyMethod.java +++ b/src/main/java/neqsim/physicalProperties/physicalPropertyMethods/PhysicalPropertyMethod.java @@ -50,7 +50,7 @@ public void setPhase( /** {@inheritDoc} */ @Override public void tuneModel(double val, double temperature, double pressure) { - logger.error("model tuning not implemented!"); + throw new UnsupportedOperationException("Unimplemented method 'tuneModel'"); } // should contain phase objects ++ get diffusivity methods .. more ? } diff --git a/src/main/java/neqsim/thermo/component/ComponentGEUnifacUMRPRU.java b/src/main/java/neqsim/thermo/component/ComponentGEUnifacUMRPRU.java index ebe3a6002..fce52b144 100644 --- a/src/main/java/neqsim/thermo/component/ComponentGEUnifacUMRPRU.java +++ b/src/main/java/neqsim/thermo/component/ComponentGEUnifacUMRPRU.java @@ -400,7 +400,7 @@ public double getGamma(PhaseInterface phase, int numberOfComponents, double temp lngamma = lngammaResidual + lngammaCombinational; if (Double.isNaN(lngamma)) { - logger.error("gamma NaN......"); + logger.warn("gamma NaN......"); lngamma = 0.0; gamma = 1.0; dlngammadt = 0; diff --git a/src/main/java/neqsim/thermo/phase/PhaseEos.java b/src/main/java/neqsim/thermo/phase/PhaseEos.java index f468d0f47..69b3b51e3 100644 --- a/src/main/java/neqsim/thermo/phase/PhaseEos.java +++ b/src/main/java/neqsim/thermo/phase/PhaseEos.java @@ -108,7 +108,7 @@ public void init(double totalNumberOfMoles, int numberOfComponents, int type, Ph pt); } } catch (Exception ex) { - logger.error("Failed to solve for molarVolume within the iteration limit."); + logger.warn("Failed to solve for molarVolume within the iteration limit."); throw new RuntimeException(ex); // logger.error("too many iterations in volume calc!", ex); // logger.info("moles " + numberOfMolesInPhase);