mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
adding a pointer to rate_converter in BlackoilModelEbos
in StandardWellsDense.
This commit is contained in:
parent
af26b70fc9
commit
f53bf6f957
@ -200,7 +200,7 @@ namespace Opm {
|
|||||||
const double gravity = detail::getGravity(geo_.gravity(), UgGridHelpers::dimensions(grid_));
|
const double gravity = detail::getGravity(geo_.gravity(), UgGridHelpers::dimensions(grid_));
|
||||||
const std::vector<double> pv(geo_.poreVolume().data(), geo_.poreVolume().data() + geo_.poreVolume().size());
|
const std::vector<double> pv(geo_.poreVolume().data(), geo_.poreVolume().data() + geo_.poreVolume().size());
|
||||||
const std::vector<double> depth(geo_.z().data(), geo_.z().data() + geo_.z().size());
|
const std::vector<double> depth(geo_.z().data(), geo_.z().data() + geo_.z().size());
|
||||||
well_model_.init(fluid_.phaseUsage(), active_, &vfp_properties_, gravity, depth, pv);
|
well_model_.init(fluid_.phaseUsage(), active_, &vfp_properties_, gravity, depth, pv, &rate_converter_);
|
||||||
wellModel().setWellsActive( localWellsActive() );
|
wellModel().setWellsActive( localWellsActive() );
|
||||||
global_nc_ = Opm::AutoDiffGrid::numCells(grid_);
|
global_nc_ = Opm::AutoDiffGrid::numCells(grid_);
|
||||||
// compute global sum of number of cells
|
// compute global sum of number of cells
|
||||||
|
@ -46,6 +46,7 @@
|
|||||||
#include <opm/autodiff/BlackoilDetails.hpp>
|
#include <opm/autodiff/BlackoilDetails.hpp>
|
||||||
#include <opm/autodiff/BlackoilModelParameters.hpp>
|
#include <opm/autodiff/BlackoilModelParameters.hpp>
|
||||||
#include <opm/autodiff/WellStateFullyImplicitBlackoilDense.hpp>
|
#include <opm/autodiff/WellStateFullyImplicitBlackoilDense.hpp>
|
||||||
|
#include <opm/autodiff/RateConverter.hpp>
|
||||||
#include<dune/common/fmatrix.hh>
|
#include<dune/common/fmatrix.hh>
|
||||||
#include<dune/istl/bcrsmatrix.hh>
|
#include<dune/istl/bcrsmatrix.hh>
|
||||||
#include<dune/istl/matrixmatrix.hh>
|
#include<dune/istl/matrixmatrix.hh>
|
||||||
@ -79,6 +80,9 @@ enum WellVariablePositions {
|
|||||||
typedef Dune::BlockVector<VectorBlockType> BVector;
|
typedef Dune::BlockVector<VectorBlockType> BVector;
|
||||||
typedef DenseAd::Evaluation<double, /*size=*/blocksize*2> EvalWell;
|
typedef DenseAd::Evaluation<double, /*size=*/blocksize*2> EvalWell;
|
||||||
|
|
||||||
|
// For the conversion between the surface volume rate and resrevoir voidage rate
|
||||||
|
using RateConverterType = RateConverter::
|
||||||
|
SurfaceToReservoirVoidage<BlackoilPropsAdFromDeck::FluidSystem, std::vector<int> >;
|
||||||
|
|
||||||
// --------- Public methods ---------
|
// --------- Public methods ---------
|
||||||
StandardWellsDense(const Wells* wells_arg,
|
StandardWellsDense(const Wells* wells_arg,
|
||||||
@ -109,7 +113,8 @@ enum WellVariablePositions {
|
|||||||
const VFPProperties* vfp_properties_arg,
|
const VFPProperties* vfp_properties_arg,
|
||||||
const double gravity_arg,
|
const double gravity_arg,
|
||||||
const std::vector<double>& depth_arg,
|
const std::vector<double>& depth_arg,
|
||||||
const std::vector<double>& pv_arg)
|
const std::vector<double>& pv_arg,
|
||||||
|
const RateConverterType* rate_converter)
|
||||||
{
|
{
|
||||||
|
|
||||||
if ( ! localWellsActive() ) {
|
if ( ! localWellsActive() ) {
|
||||||
@ -122,6 +127,7 @@ enum WellVariablePositions {
|
|||||||
gravity_ = gravity_arg;
|
gravity_ = gravity_arg;
|
||||||
cell_depths_ = extractPerfData(depth_arg);
|
cell_depths_ = extractPerfData(depth_arg);
|
||||||
pv_ = pv_arg;
|
pv_ = pv_arg;
|
||||||
|
rate_converter_ = rate_converter;
|
||||||
|
|
||||||
calculateEfficiencyFactors();
|
calculateEfficiencyFactors();
|
||||||
|
|
||||||
@ -1671,6 +1677,7 @@ enum WellVariablePositions {
|
|||||||
std::vector<bool> active_;
|
std::vector<bool> active_;
|
||||||
const VFPProperties* vfp_properties_;
|
const VFPProperties* vfp_properties_;
|
||||||
double gravity_;
|
double gravity_;
|
||||||
|
const RateConverterType* rate_converter_;
|
||||||
|
|
||||||
// The efficiency factor for each connection. It is specified based on wells and groups,
|
// The efficiency factor for each connection. It is specified based on wells and groups,
|
||||||
// We calculate the factor for each connection for the computation of contributions to the mass balance equations.
|
// We calculate the factor for each connection for the computation of contributions to the mass balance equations.
|
||||||
|
Loading…
Reference in New Issue
Block a user