Esempio n. 1
0
 bool Well::canOpen(size_t currentStep) const {
     bool canOpen = true;
     if (!getAllowCrossFlow()) {
         if ( isInjector(currentStep) ) {
             if (getInjectionProperties(currentStep).surfaceInjectionRate == 0) {;
                 canOpen = false;
             }
         } else {
             if ( (getProductionProperties(currentStep).WaterRate + getProductionProperties(currentStep).OilRate +
                   getProductionProperties(currentStep).GasRate) == 0) {
                 canOpen = false;
             }
         }
     }
     return canOpen;
 }
Esempio n. 2
0
    bool Well::canOpen(size_t currentStep) const {
        if( getAllowCrossFlow() ) return true;

        if( isInjector( currentStep ) )
            return getInjectionProperties( currentStep ).surfaceInjectionRate != 0;

        const auto& prod = getProductionProperties( currentStep );
        return (prod.WaterRate + prod.OilRate + prod.GasRate) != 0;
    }