/var/opm/opm-core/opm/core/props/IncompPropertiesShadow.hpp Override certain properties with values from elsewhere. This allows mixing of property objects from several sources, such as rock and fluid properties from a file but unsaturated properties from a function. Care must be taken to setup the shadowing so no inconsistencies arise.
std::vector<double> poro;
IncompPropertiesFromDeck fromDeck(deck, grid);
simulate (IncompPropertiesShadow(fromDeck).usePorosity(poro));
/* Copyright (c) 2013 Uni Research AS.
This file is licensed under the GNU General Public License v3.0 or later. */
#ifndef OPM_INCOMPPROPERTIESSHADOW_HEADER_INCLUDED
#define OPM_INCOMPPROPERTIESSHADOW_HEADER_INCLUDED
#ifndef OPM_INCOMPPROPERTIESINTERFACE_HEADER_INCLUDED
#include <opm/core/props/IncompPropertiesInterface.hpp>
#endif /* OPM_INCOMPPROPERTIESINTERFACE_HEADER_INCLUDED */
namespace Opm
{
struct IncompPropertiesShadow : public IncompPropertiesInterface
{
const double* s,
const int* cells,
double* kr,
double* dkrds) const;
const double* s,
const int* cells,
double* pc,
double* dpcds) const;
const int* cells,
double* smin,
double* smax) const;
private:
const IncompPropertiesInterface& prototype_;
int shadowed_;
static const int POROSITY = 1 << 1;
static const int PERMEABILITY = 1 << 2;
static const int VISCOSITY = 1 << 3;
static const int DENSITY = 1 << 4;
static const int SURFACE_DENSITY = 1 << 5;
const double* poro_;
const double* perm_;
const double* visc_;
const double* dens_;
const double* surf_;
};
} /* namespace Opm */
// body of inline methods are defined here:
#endif /* OPM_INCOMPPROPERTIESSHADOW_HEADER_INCLUDED */
Definition: AnisotropicEikonal.hpp:44 virtual int numDimensions() const Definition: IncompPropertiesShadow_impl.hpp:29 virtual int numCells() const Definition: IncompPropertiesShadow_impl.hpp:34 IncompPropertiesShadow & useDensity(const double *dens) Definition: IncompPropertiesShadow_impl.hpp:128 IncompPropertiesShadow & useRockAndFluidProps(const IncompPropertiesInterface &other) Definition: IncompPropertiesShadow_impl.hpp:190 virtual void satRange(const int n, const int *cells, double *smin, double *smax) const Definition: IncompPropertiesShadow_impl.hpp:67 virtual void capPress(const int n, const double *s, const int *cells, double *pc, double *dpcds) const Definition: IncompPropertiesShadow_impl.hpp:58 virtual const double * density() const Definition: IncompPropertiesShadow_impl.hpp:94 virtual const double * surfaceDensity() const Definition: IncompPropertiesShadow_impl.hpp:99 virtual const double * permeability() const Definition: IncompPropertiesShadow_impl.hpp:84 IncompPropertiesShadow(const IncompPropertiesInterface &original) Definition: IncompPropertiesShadow_impl.hpp:14 IncompPropertiesShadow & useSurfaceDensity(const double *surf) Definition: IncompPropertiesShadow_impl.hpp:135 IncompPropertiesShadow & useFluidProps(const IncompPropertiesInterface &other) Definition: IncompPropertiesShadow_impl.hpp:185 IncompPropertiesShadow & usePorosity(const double *poro) Definition: IncompPropertiesShadow_impl.hpp:107 IncompPropertiesShadow & usePermeability(const double *perm) Definition: IncompPropertiesShadow_impl.hpp:114 virtual const double * porosity() const Definition: IncompPropertiesShadow_impl.hpp:79 virtual const double * viscosity() const Definition: IncompPropertiesShadow_impl.hpp:89 IncompPropertiesShadow & useViscosity(const double *visc) Definition: IncompPropertiesShadow_impl.hpp:121 virtual int numPhases() const Definition: IncompPropertiesShadow_impl.hpp:39 IncompPropertiesShadow & useRockProps(const IncompPropertiesInterface &other) Definition: IncompPropertiesShadow_impl.hpp:180 virtual void relperm(const int n, const double *s, const int *cells, double *kr, double *dkrds) const Definition: IncompPropertiesShadow_impl.hpp:49 |