2021-03-03 06:59:26 -06:00
|
|
|
/*
|
|
|
|
Copyright 2020 Equinor ASA.
|
|
|
|
|
|
|
|
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/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef OPM_GASLIFT_SINGLE_WELL_HEADER_INCLUDED
|
|
|
|
#define OPM_GASLIFT_SINGLE_WELL_HEADER_INCLUDED
|
|
|
|
|
2021-05-25 05:00:24 -05:00
|
|
|
#include <opm/models/utils/propertysystem.hh>
|
|
|
|
#include <opm/models/utils/parametersystem.hh>
|
|
|
|
#include <opm/models/discretization/common/fvbaseproperties.hh>
|
|
|
|
|
2021-03-03 06:59:26 -06:00
|
|
|
// NOTE: StandardWell.hpp includes ourself (GasLiftSingleWell.hpp), so we need
|
|
|
|
// to forward declare StandardWell for it to be defined in this file.
|
|
|
|
namespace Opm {
|
|
|
|
template<typename TypeTag> class StandardWell;
|
|
|
|
}
|
|
|
|
#include <opm/simulators/wells/StandardWell.hpp>
|
2021-05-20 07:20:27 -05:00
|
|
|
#include <opm/simulators/wells/GasLiftSingleWellGeneric.hpp>
|
|
|
|
|
2021-03-03 06:59:26 -06:00
|
|
|
#include <optional>
|
|
|
|
#include <vector>
|
|
|
|
#include <utility>
|
|
|
|
#include <fmt/format.h>
|
|
|
|
|
|
|
|
namespace Opm
|
|
|
|
{
|
|
|
|
template<class TypeTag>
|
2021-05-20 07:20:27 -05:00
|
|
|
class GasLiftSingleWell : public GasLiftSingleWellGeneric
|
2021-03-03 06:59:26 -06:00
|
|
|
{
|
|
|
|
using Simulator = GetPropType<TypeTag, Properties::Simulator>;
|
2021-05-20 05:15:58 -05:00
|
|
|
using StdWell = StandardWell<TypeTag>;
|
2021-05-20 07:20:27 -05:00
|
|
|
|
2021-03-03 06:59:26 -06:00
|
|
|
public:
|
|
|
|
GasLiftSingleWell(
|
|
|
|
const StdWell &std_well,
|
|
|
|
const Simulator &ebos_simulator,
|
|
|
|
const SummaryState &summary_state,
|
|
|
|
DeferredLogger &deferred_logger,
|
|
|
|
WellState &well_state
|
|
|
|
);
|
2021-05-24 16:56:14 -05:00
|
|
|
const WellInterfaceGeneric &getStdWell() const override { return std_well_; }
|
2021-03-03 06:59:26 -06:00
|
|
|
|
|
|
|
private:
|
2021-05-20 07:20:27 -05:00
|
|
|
std::optional<double> computeBhpAtThpLimit_(double alq) const override;
|
2021-03-03 06:59:26 -06:00
|
|
|
void computeWellRates_(
|
2021-05-20 07:20:27 -05:00
|
|
|
double bhp, std::vector<double> &potentials, bool debug_output=true) const override;
|
|
|
|
|
|
|
|
void setAlqMaxRate_(const GasLiftOpt::Well& well);
|
|
|
|
|
2021-03-03 06:59:26 -06:00
|
|
|
const Simulator &ebos_simulator_;
|
|
|
|
const StdWell &std_well_;
|
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace Opm
|
|
|
|
|
2021-05-20 07:20:27 -05:00
|
|
|
#include "GasLiftSingleWell_impl.hpp"
|
2021-03-03 06:59:26 -06:00
|
|
|
|
|
|
|
#endif // OPM_GASLIFT_SINGLE_WELL_HEADER_INCLUDED
|