including the injectivity program to flow

This commit is contained in:
Kai Bao 2018-12-10 21:27:56 +01:00
parent 525caad508
commit 167306169b
3 changed files with 16 additions and 32 deletions

View File

@ -27,6 +27,7 @@
#include <flow/flow_ebos_polymer.hpp>
#include <flow/flow_ebos_energy.hpp>
#include <flow/flow_ebos_oilwater_polymer.hpp>
#include <flow/flow_ebos_oilwater_polymer_injectivity.hpp>
#include <opm/autodiff/SimulatorFullyImplicitBlackoilEbos.hpp>
#include <opm/autodiff/FlowMainEbos.hpp>
@ -223,6 +224,14 @@ int main(int argc, char** argv)
return EXIT_FAILURE;
}
// Need to track the polymer molecular weight
// for the injectivity study
if ( phases.active( Opm::Phase::POLYMW ) ) {
// only oil water two phase for now
assert( phases.size() == 4);
return Opm::flowEbosOilWaterPolymerInjectivityMain(argc, argv);
}
if ( phases.size() == 3 ) { // oil water polymer case
Opm::flowEbosOilWaterPolymerSetDeck(*deck, *eclipseState);
return Opm::flowEbosOilWaterPolymerMain(argc, argv);

View File

@ -36,9 +36,9 @@
namespace Ewoms {
namespace Properties {
NEW_TYPE_TAG(EclFlowOilWaterPolymerProblem, INHERITS_FROM(EclFlowProblem));
SET_BOOL_PROP(EclFlowOilWaterPolymerProblem, EnablePolymer, true);
SET_BOOL_PROP(EclFlowOilWaterPolymerProblem, EnablePolymerMW, true);
NEW_TYPE_TAG(EclFlowOilWaterPolymerInjectivityProblem, INHERITS_FROM(EclFlowProblem));
SET_BOOL_PROP(EclFlowOilWaterPolymerInjectivityProblem, EnablePolymer, true);
SET_BOOL_PROP(EclFlowOilWaterPolymerInjectivityProblem, EnablePolymerMW, true);
//! The indices required by the model
// For this case, there will be two primary variables introduced for the polymer
// polymer concentration and polymer molecular weight
@ -50,7 +50,7 @@ SET_BOOL_PROP(EclFlowOilWaterPolymerProblem, EnablePolymerMW, true);
0,
0,
2>); */
SET_PROP(EclFlowOilWaterPolymerProblem, Indices)
SET_PROP(EclFlowOilWaterPolymerInjectivityProblem, Indices)
{
private:
// it is unfortunately not possible to simply use 'TypeTag' here because this leads
@ -69,12 +69,12 @@ public:
}}
namespace Opm {
/* void flowEbosOilWaterPolymerInjectivitySetDeck(Deck& deck, EclipseState& eclState, Schedule& schedule, SummaryConfig& summaryConfig)
/* void flowEbosOilWaterPolymerInjectivitySetDeck(Deck& deck, EclipseState& eclState)
{
typedef TTAG(EclFlowOilWaterPolymerProblem) TypeTag;
typedef GET_PROP_TYPE(TypeTag, Vanguard) Vanguard;
Vanguard::setExternalDeck(&deck, &eclState, &schedule, &summaryConfig);
Vanguard::setExternalDeck(&deck, &eclState);
} */
// ----------------- Main program -----------------
@ -90,7 +90,7 @@ int flowEbosOilWaterPolymerInjectivityMain(int argc, char** argv)
Dune::MPIHelper::instance(argc, argv);
#endif
Opm::FlowMainEbos<TTAG(EclFlowOilWaterPolymerProblem)> mainfunc;
Opm::FlowMainEbos<TTAG(EclFlowOilWaterPolymerInjectivityProblem)> mainfunc;
return mainfunc.execute(argc, argv);
}

View File

@ -1,25 +0,0 @@
/*
This file is part of the Open Porous Media project (OPM).
OPM is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OPM is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with OPM. If not, see <http://www.gnu.org/licenses/>.
*/
#include "config.h"
#include <flow/flow_ebos_oilwater_polymer_injectivity.hpp>
// ----------------- Main program -----------------
int main(int argc, char** argv)
{
return Opm::flowEbosOilWaterPolymerInjectivityMain(argc, argv);
}