diff --git a/opm/autodiff/StandardWell_impl.hpp b/opm/autodiff/StandardWell_impl.hpp index a99451e4a..c3f50c022 100644 --- a/opm/autodiff/StandardWell_impl.hpp +++ b/opm/autodiff/StandardWell_impl.hpp @@ -331,7 +331,7 @@ namespace Opm return primary_variables_evaluation_[GFrac]; } - if (has_solvent && compIdx == contiSolventEqIdx) { + if (has_solvent && compIdx == (unsigned)contiSolventEqIdx) { return primary_variables_evaluation_[SFrac]; } diff --git a/opm/core/simulator/SimulatorReport.hpp b/opm/core/simulator/SimulatorReport.hpp index 696f9bca1..e86f4e7ef 100644 --- a/opm/core/simulator/SimulatorReport.hpp +++ b/opm/core/simulator/SimulatorReport.hpp @@ -45,7 +45,7 @@ namespace Opm bool converged; /// Default constructor initializing all times to 0.0. - SimulatorReport(bool verbose=true); + explicit SimulatorReport(bool verbose=true); /// Copy constructor SimulatorReport(const SimulatorReport&) = default; /// Increment this report's times by those in sr. diff --git a/opm/core/transport/reorder/reordersequence.cpp b/opm/core/transport/reorder/reordersequence.cpp index 2efc478a8..08446c3c1 100644 --- a/opm/core/transport/reorder/reordersequence.cpp +++ b/opm/core/transport/reorder/reordersequence.cpp @@ -18,7 +18,7 @@ struct SortByAbsFlux { - SortByAbsFlux(const double* flux) + explicit SortByAbsFlux(const double* flux) : flux_(flux) {} bool operator() (int f1, int f2) diff --git a/opm/core/utility/miscUtilitiesBlackoil.cpp b/opm/core/utility/miscUtilitiesBlackoil.cpp index 14e1cbf69..82960dca3 100644 --- a/opm/core/utility/miscUtilitiesBlackoil.cpp +++ b/opm/core/utility/miscUtilitiesBlackoil.cpp @@ -318,7 +318,6 @@ namespace Opm //double res_vol; - double tot_sat; const double epsilon = std::sqrt(std::numeric_limits::epsilon()); for (int c = 0; c < nc; ++c) { @@ -332,7 +331,7 @@ namespace Opm dgesv_(&n, &nrhs, &A[0], &lda, &piv[0], &s[0], &ldb, &info); - tot_sat = 0; + double tot_sat = 0; for (int p = 0; p < np; ++p){ if (s[p] < epsilon) // saturation may be less then zero due to round of errors s[p] = 0; diff --git a/opm/polymer/PolymerProperties.cpp b/opm/polymer/PolymerProperties.cpp index 6a29e6089..3c72a2e3a 100644 --- a/opm/polymer/PolymerProperties.cpp +++ b/opm/polymer/PolymerProperties.cpp @@ -197,7 +197,7 @@ namespace Opm mu_w_eff = 1./mu_w_eff; } - void PolymerProperties::effectiveViscWithDer(const double c, const double mu_w, double& mu_w_eff, double dmu_w_eff_dc) const { + void PolymerProperties::effectiveViscWithDer(const double c, const double mu_w, double& mu_w_eff, double& dmu_w_eff_dc) const { effectiveInvViscWithDer(c, mu_w, mu_w_eff, dmu_w_eff_dc); mu_w_eff = 1./mu_w_eff; dmu_w_eff_dc = -dmu_w_eff_dc*mu_w_eff*mu_w_eff; diff --git a/opm/polymer/PolymerProperties.hpp b/opm/polymer/PolymerProperties.hpp index 4553581ae..7961ab1c0 100644 --- a/opm/polymer/PolymerProperties.hpp +++ b/opm/polymer/PolymerProperties.hpp @@ -283,7 +283,7 @@ namespace Opm void effectiveViscWithDer(const double c, const double visc , double& mu_w_eff - , double dmu_w_eff_dc) const; + , double& dmu_w_eff_dc) const; void effectiveInvVisc(const double c, const double mu_w, double& inv_mu_w_eff) const; diff --git a/opm/polymer/TransportSolverTwophaseCompressiblePolymer.cpp b/opm/polymer/TransportSolverTwophaseCompressiblePolymer.cpp index fad703c63..b876e9219 100644 --- a/opm/polymer/TransportSolverTwophaseCompressiblePolymer.cpp +++ b/opm/polymer/TransportSolverTwophaseCompressiblePolymer.cpp @@ -306,7 +306,7 @@ namespace Opm mutable double s; // Mutable in order to change it with every operator() call to be the last computed s value. TransportSolverTwophaseCompressiblePolymer::ResidualEquation& res_eq_; explicit ResidualC(TransportSolverTwophaseCompressiblePolymer::ResidualEquation& res_eq) - : res_eq_(res_eq) + : s(0.0), res_eq_(res_eq) {} void computeBothResiduals(const double s_arg, const double c_arg, double& res_s, double& res_c, double& mc, double& ff) const diff --git a/tutorials/sim_tutorial1.cpp b/tutorials/sim_tutorial1.cpp index 193826403..eabd41e26 100644 --- a/tutorials/sim_tutorial1.cpp +++ b/tutorials/sim_tutorial1.cpp @@ -87,7 +87,9 @@ try /// We open an output file stream for the output /// \snippet tutorial1.cpp output stream /// \internal [output stream] +#ifdef DISABLE_OUTPUT std::ofstream vtkfile("tutorial1.vtu"); +#endif /// \internal [output stream] /// \endinternal /// \page tutorial1