handle the situatioin when giving a NaN prod target to injectors

When all production wells are under individual controls, the group can
have zero production guide rates, which can result NaN value targets for
injectors.
This commit is contained in:
Kai Bao 2017-03-23 13:47:36 +01:00
parent d41c4a371f
commit 530afe55dd

View File

@ -1075,7 +1075,7 @@ namespace Opm
const bool only_group) const bool only_group)
{ {
if ( !isInjector() ) { if ( !isInjector() ) {
// assert(target == 0.0); assert(target == 0.0 || std::isnan(target));
return; return;
} }
@ -1280,7 +1280,7 @@ namespace Opm
const bool only_group) const bool only_group)
{ {
if ( !isProducer() ) { if ( !isProducer() ) {
assert(target == 0.0); assert(target == 0.0 || std::isnan(target));
return; return;
} }