move StepReport into ConvergenceReport.hpp

there is no reason for this to be typetag dependent
This commit is contained in:
Arne Morten Kvarving 2023-03-01 13:40:54 +01:00
parent 44b23af154
commit ebd53ee72d
3 changed files with 12 additions and 8 deletions

View File

@ -44,6 +44,7 @@
#include <opm/simulators/flow/BlackoilModelParametersEbos.hpp> #include <opm/simulators/flow/BlackoilModelParametersEbos.hpp>
#include <opm/simulators/linalg/ISTLSolverEbos.hpp> #include <opm/simulators/linalg/ISTLSolverEbos.hpp>
#include <opm/simulators/timestepping/AdaptiveTimeSteppingEbos.hpp> #include <opm/simulators/timestepping/AdaptiveTimeSteppingEbos.hpp>
#include <opm/simulators/timestepping/ConvergenceReport.hpp>
#include <opm/simulators/timestepping/SimulatorReport.hpp> #include <opm/simulators/timestepping/SimulatorReport.hpp>
#include <opm/simulators/timestepping/SimulatorTimer.hpp> #include <opm/simulators/timestepping/SimulatorTimer.hpp>
@ -1061,13 +1062,6 @@ namespace Opm {
const SimulatorReportSingle& failureReport() const const SimulatorReportSingle& failureReport() const
{ return failureReport_; } { return failureReport_; }
struct StepReport
{
int report_step;
int current_step;
std::vector<ConvergenceReport> report;
};
const std::vector<StepReport>& stepReports() const const std::vector<StepReport>& stepReports() const
{ {
return convergence_reports_; return convergence_reports_;
@ -1155,6 +1149,7 @@ namespace Opm {
double drMaxRel() const { return param_.dr_max_rel_; } double drMaxRel() const { return param_.dr_max_rel_; }
double maxResidualAllowed() const { return param_.max_residual_allowed_; } double maxResidualAllowed() const { return param_.max_residual_allowed_; }
double linear_solve_setup_time_; double linear_solve_setup_time_;
public: public:
std::vector<bool> wasSwitched_; std::vector<bool> wasSwitched_;
}; };

View File

@ -31,6 +31,7 @@
#include <opm/simulators/flow/NonlinearSolverEbos.hpp> #include <opm/simulators/flow/NonlinearSolverEbos.hpp>
#include <opm/simulators/aquifers/BlackoilAquiferModel.hpp> #include <opm/simulators/aquifers/BlackoilAquiferModel.hpp>
#include <opm/simulators/timestepping/AdaptiveTimeSteppingEbos.hpp> #include <opm/simulators/timestepping/AdaptiveTimeSteppingEbos.hpp>
#include <opm/simulators/timestepping/ConvergenceReport.hpp>
#include <opm/simulators/utils/moduleVersion.hpp> #include <opm/simulators/utils/moduleVersion.hpp>
#include <opm/simulators/wells/WellState.hpp> #include <opm/simulators/wells/WellState.hpp>
@ -547,7 +548,7 @@ protected:
&this->convergenceOutputObject_.value()); &this->convergenceOutputObject_.value());
} }
void writeConvergenceOutput(std::vector<typename Model::StepReport>&& reports) void writeConvergenceOutput(std::vector<StepReport>&& reports)
{ {
if (! this->convergenceOutputThread_.has_value()) { if (! this->convergenceOutputThread_.has_value()) {
return; return;

View File

@ -221,6 +221,14 @@ namespace Opm
bool wellGroupTargetsViolated_; bool wellGroupTargetsViolated_;
}; };
struct StepReport
{
int report_step;
int current_step;
std::vector<ConvergenceReport> report;
};
} // namespace Opm } // namespace Opm
#endif // OPM_CONVERGENCEREPORT_HEADER_INCLUDED #endif // OPM_CONVERGENCEREPORT_HEADER_INCLUDED