mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Merge pull request #1209 from dr-robertk/PR/remove-uninitialized-vars
[cleanup] initialized Eval variables with 0.
This commit is contained in:
@@ -205,11 +205,11 @@ enum WellVariablePositions {
|
|||||||
/// Diff to bhp for each well perforation.
|
/// Diff to bhp for each well perforation.
|
||||||
const std::vector<double>& wellPerforationPressureDiffs() const;
|
const std::vector<double>& wellPerforationPressureDiffs() const;
|
||||||
|
|
||||||
EvalWell extendEval(Eval in) const;
|
EvalWell extendEval(const Eval& in) const;
|
||||||
|
|
||||||
void setWellVariables(const WellState& xw);
|
void setWellVariables(const WellState& xw);
|
||||||
|
|
||||||
void print(EvalWell in) const;
|
void print(const EvalWell& in) const;
|
||||||
|
|
||||||
void computeAccumWells();
|
void computeAccumWells();
|
||||||
|
|
||||||
|
|||||||
@@ -187,7 +187,7 @@ namespace Opm {
|
|||||||
const double volume = 0.002831684659200; // 0.1 cu ft;
|
const double volume = 0.002831684659200; // 0.1 cu ft;
|
||||||
for (int w = 0; w < nw; ++w) {
|
for (int w = 0; w < nw; ++w) {
|
||||||
bool allow_cf = allow_cross_flow(w, ebosSimulator);
|
bool allow_cf = allow_cross_flow(w, ebosSimulator);
|
||||||
const EvalWell bhp = getBhp(w);
|
const EvalWell& bhp = getBhp(w);
|
||||||
for (int perf = wells().well_connpos[w] ; perf < wells().well_connpos[w+1]; ++perf) {
|
for (int perf = wells().well_connpos[w] ; perf < wells().well_connpos[w+1]; ++perf) {
|
||||||
|
|
||||||
const int cell_idx = wells().well_cells[perf];
|
const int cell_idx = wells().well_cells[perf];
|
||||||
@@ -283,7 +283,7 @@ namespace Opm {
|
|||||||
} else {
|
} else {
|
||||||
|
|
||||||
const auto& paramsCell = materialLawManager->connectionMaterialLawParams(satid, cell_idx);
|
const auto& paramsCell = materialLawManager->connectionMaterialLawParams(satid, cell_idx);
|
||||||
Eval relativePerms[3];
|
Eval relativePerms[3] = { 0.0, 0.0, 0.0 };
|
||||||
MaterialLaw::relativePermeabilities(relativePerms, paramsCell, intQuants.fluidState());
|
MaterialLaw::relativePermeabilities(relativePerms, paramsCell, intQuants.fluidState());
|
||||||
|
|
||||||
// reset the satnumvalue back to original
|
// reset the satnumvalue back to original
|
||||||
@@ -681,7 +681,7 @@ namespace Opm {
|
|||||||
template<typename TypeTag>
|
template<typename TypeTag>
|
||||||
typename StandardWellsDense<TypeTag>::EvalWell
|
typename StandardWellsDense<TypeTag>::EvalWell
|
||||||
StandardWellsDense<TypeTag>::
|
StandardWellsDense<TypeTag>::
|
||||||
extendEval(Eval in) const {
|
extendEval(const Eval& in) const {
|
||||||
EvalWell out = 0.0;
|
EvalWell out = 0.0;
|
||||||
out.setValue(in.value());
|
out.setValue(in.value());
|
||||||
for(int eqIdx = 0; eqIdx < numEq;++eqIdx) {
|
for(int eqIdx = 0; eqIdx < numEq;++eqIdx) {
|
||||||
@@ -723,7 +723,7 @@ namespace Opm {
|
|||||||
template<typename TypeTag>
|
template<typename TypeTag>
|
||||||
void
|
void
|
||||||
StandardWellsDense<TypeTag>::
|
StandardWellsDense<TypeTag>::
|
||||||
print(EvalWell in) const
|
print(const EvalWell& in) const
|
||||||
{
|
{
|
||||||
std::cout << in.value() << std::endl;
|
std::cout << in.value() << std::endl;
|
||||||
for (int i = 0; i < in.size; ++i) {
|
for (int i = 0; i < in.size; ++i) {
|
||||||
|
|||||||
Reference in New Issue
Block a user