ECL well manager: hack around recently introduced opm-parser ideosyncrasy

catching an exception for this seems like a pretty bad hack to me, but
there seems to be no other way to detect that a deck did not specify a
completion radius. (well, one could look at the raw COMPDAT keyword,
but that would defeat all benefits of using opm-parser's schedule
objects.)

this makes ebos work with SPE9 for the current master version of
opm-parser again.
This commit is contained in:
Andreas Lauser 2015-01-03 16:06:53 +01:00
parent e1743929d4
commit 602909c16d

View File

@ -651,7 +651,15 @@ protected:
const Opm::Completion* completion = compInfo.first;
std::shared_ptr<Well> eclWell = compInfo.second;
// the catch is a hack for a ideosyncrasy of opm-parser with regard to
// defaults handling: if the deck did not specify a radius for the
// completion, there seems to be no other way to detect this except for
// catching the exception
try {
eclWell->setRadius(elemCtx, dofIdx, 0.5*completion->getDiameter());
}
catch (const std::logic_error& e)
{}
// overwrite the automatically computed effective
// permeability by the one specified in the deck. Note: this