opm-simulators
Loading...
Searching...
No Matches
BlackoilWellModelNetwork.hpp
1/*
2 Copyright 2016 SINTEF ICT, Applied Mathematics.
3 Copyright 2016 - 2017 Statoil ASA.
4 Copyright 2017 Dr. Blatt - HPC-Simulation-Software & Services
5 Copyright 2016 - 2018 IRIS AS
6
7 This file is part of the Open Porous Media project (OPM).
8
9 OPM is free software: you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation, either version 3 of the License, or
12 (at your option) any later version.
13
14 OPM is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License for more details.
18
19 You should have received a copy of the GNU General Public License
20 along with OPM. If not, see <http://www.gnu.org/licenses/>.
21*/
22
23#ifndef OPM_BLACKOILWELLMODEL_NETWORK_HEADER_INCLUDED
24#define OPM_BLACKOILWELLMODEL_NETWORK_HEADER_INCLUDED
25
28
29#include <opm/simulators/wells/BlackoilWellModelNetworkGeneric.hpp>
30
31#include <map>
32#include <string>
33#include <tuple>
34
35namespace Opm {
36 class DeferredLogger;
37 template<class TypeTag> class BlackoilWellModel;
38}
39
40namespace Opm {
41
43template<typename TypeTag>
44class BlackoilWellModelNetwork :
45 public BlackoilWellModelNetworkGeneric<GetPropType<TypeTag, Properties::Scalar>,
46 typename GetPropType<TypeTag, Properties::FluidSystem>::IndexTraitsType>
47{
48 using BaseType =
49 BlackoilWellModelNetworkGeneric<GetPropType<TypeTag, Properties::Scalar>,
51
54 using IndexTraits = typename FluidSystem::IndexTraitsType;
56
57public:
58 BlackoilWellModelNetwork(BlackoilWellModel<TypeTag>& well_model);
59
60 std::tuple<bool, Scalar>
61 update(const bool mandatory_network_balance,
62 DeferredLogger& deferred_logger,
63 const bool relax_network_tolerance = false);
64
65 // Pre-step network solve at static reservoir conditions (group and well states might be updated)
66 void doPreStepRebalance(DeferredLogger& deferred_logger);
67
68protected:
72 bool computeWellGroupThp(const double dt, DeferredLogger& local_deferredLogger);
73
74 BlackoilWellModel<TypeTag>& well_model_;
75 std::map<std::string, Scalar> well_group_thp_calc_;
76};
77
78} // namespace Opm
79
80#include "BlackoilWellModelNetwork_impl.hpp"
81
82#endif // OPM_BLACKOILWELLMODEL_NETWORK_HEADER_INCLUDED
Defines a type tags and some fundamental properties all models.
bool computeWellGroupThp(const double dt, DeferredLogger &local_deferredLogger)
This function is to be used for well groups in an extended network that act as a subsea manifold The ...
Definition BlackoilWellModelNetwork_impl.hpp:159
Class for handling the blackoil well model.
Definition BlackoilWellModel.hpp:98
Definition DeferredLogger.hpp:57
Defines the common properties required by the porous medium multi-phase models.
This file contains a set of helper functions used by VFPProd / VFPInj.
Definition blackoilbioeffectsmodules.hh:45
typename Properties::Detail::GetPropImpl< TypeTag, Property >::type::type GetPropType
get the type alias defined in the property (equivalent to old macro GET_PROP_TYPE(....
Definition propertysystem.hh:233