adding a function outputWellState for StandardWellsDense

to output the well state for debugging purpose.
This commit is contained in:
Kai Bao
2017-06-29 14:31:17 +02:00
parent 3ceea76616
commit eca28a8ade
2 changed files with 29 additions and 0 deletions

View File

@@ -425,6 +425,8 @@ enum WellVariablePositions {
void computeAverageFormationFactor(Simulator& ebosSimulator,
std::vector<double>& B_avg) const;
void outputWellState(const WellState& well_state) const;
};

View File

@@ -2511,4 +2511,31 @@ namespace Opm {
template<typename TypeTag>
void
StandardWellsDense<TypeTag>::
outputWellState(const WellState& well_state) const
{
std::cout << " output the bhp " << std::endl;
for (const double bhp : well_state.bhp()) {
std::cout << bhp << " ";
}
std::cout << std::endl;
std::cout << " output the well rates " << std::endl;
for (const double rate : well_state.wellRates()) {
std::cout << rate << " ";
}
std::cout << std::endl;
std::cout << " output the wellSolutions " << std::endl;
for (const double solution : well_state.wellSolutions()) {
std::cout << solution << " ";
}
std::cout << std::endl;
}
} // namespace Opm