opm-common
Loading...
Searching...
No Matches
Opm::WellFractureSeeds Class Reference

Fracture seed points attached to a single well. More...

#include <WellFractureSeeds.hpp>

Classes

struct  SeedIndex
 Disambiguating type for requesting fracture plane normal vectors based on insertion indices. More...
struct  SeedCell
 Disambiguating type for requesting fracture plane normal vectors based on Cartesian cell indices. More...
class  SeedSize
 Vertical extent, horizontal extent, and width of initial fracture at a seed point. More...

Public Types

using NormalVector = std::array<double, 3>
 Type alias for the normal vector at a single seed point.

Public Member Functions

 WellFractureSeeds ()=default
 Default constructor.
 WellFractureSeeds (const std::string &wellName)
 Constructor.
const std::string & name () const
 Named well to which this seed collection is associated.
bool updateSeed (const std::size_t seedCellGlobal, const NormalVector &seedNormal, const SeedSize &seedSize)
 Insert or update a fracture seed in current collection.
void finalizeSeeds ()
 Establish accelerator structure for LOG(n) normal vector lookup based on Cartesian cell indices.
bool empty () const
 Predicate for empty fracture seed collection.
auto numSeeds () const
 Number of fracture seeds in the current collection.
const NormalVectorgetNormal (const SeedCell &c) const
 Look up fracturing plane normal vector based on Cartesian cell index.
const SeedSizegetSize (const SeedCell &c) const
 Look up fracturing size vector based on Cartesian cell index.
const NormalVectorgetNormal (const SeedIndex &i) const
 Retrieve fracturing plane normal vector based on insertion order/record index.
const SeedSizegetSize (const SeedIndex &i) const
 Retrieve initial fracture size vector based on insertion order/record index.
const std::vector< std::size_t > & seedCells () const
 Retrieve this collection's fracture seed cells.
bool operator== (const WellFractureSeeds &that) const
 Equality predicate.
template<class Serializer>
void serializeOp (Serializer &serializer)
 Convert between byte array and object representation.

Static Public Member Functions

static WellFractureSeeds serializationTestObject ()
 Create a serialisation test object.

Detailed Description

Fracture seed points attached to a single well.

Constructor & Destructor Documentation

◆ WellFractureSeeds() [1/2]

Opm::WellFractureSeeds::WellFractureSeeds ( )
default

Default constructor.

Forms an object which is mostly usable as the destination of a deserialisation operation.

◆ WellFractureSeeds() [2/2]

Opm::WellFractureSeeds::WellFractureSeeds ( const std::string & wellName)
inlineexplicit

Constructor.

Parameters
[in]wellNameNamed well to which this seed collection is associated.

Member Function Documentation

◆ empty()

bool Opm::WellFractureSeeds::empty ( ) const
inline

Predicate for empty fracture seed collection.

Returns
Whether or not the current collection is empty.

◆ finalizeSeeds()

void Opm::WellFractureSeeds::finalizeSeeds ( )

Establish accelerator structure for LOG(n) normal vector lookup based on Cartesian cell indices.

This is an optimisation that requires more memory in the object, and you should call this function only when all updateSeed() calls have been made. You do not need to call this function in order to use the object, but it will reduce the cost of those kinds of lookup. If you do not call this function, then normal vector lookup based on Cartesian cell indices will use a linear search.

◆ getNormal() [1/2]

const Opm::WellFractureSeeds::NormalVector * Opm::WellFractureSeeds::getNormal ( const SeedCell & c) const

Look up fracturing plane normal vector based on Cartesian cell index.

Parameters
[in]cCartesian cell index.
Returns
Fracturing plane normal vector in cell c. Not guaranteed to be a unit normal vector. Nullptr if no seed exists in cell c.

◆ getNormal() [2/2]

const NormalVector & Opm::WellFractureSeeds::getNormal ( const SeedIndex & i) const
inline

Retrieve fracturing plane normal vector based on insertion order/record index.

Should normally be used in conjunction with member function seedCells() only.

Parameters
[in]iInsertion order. Should be in the range [0 .. numSeeds()).
Returns
Fracturing plane normal vector in seed cell inserted as the i-th unique cell index. Not guaranteed to be a unit normal vector.

◆ getSize() [1/2]

const Opm::WellFractureSeeds::SeedSize * Opm::WellFractureSeeds::getSize ( const SeedCell & c) const

Look up fracturing size vector based on Cartesian cell index.

Parameters
[in]cCartesian cell index.
Returns
Fracturing plane size vector in cell c. Nullptr if no seed exists in cell c.

◆ getSize() [2/2]

const SeedSize & Opm::WellFractureSeeds::getSize ( const SeedIndex & i) const
inline

Retrieve initial fracture size vector based on insertion order/record index.

Parameters
[in]cCartesian cell index.

Should normally be used in conjunction with member function seedCells() only.

Parameters
[in]iInsertion order. Should be in the range [0 .. numSeeds()).
Returns
Initial fracture size (vertical and horizontal extents, along with initial width) at the i-th unique cell index.

◆ name()

const std::string & Opm::WellFractureSeeds::name ( ) const
inline

Named well to which this seed collection is associated.

Exists mostly to meet interface requirements of class ScheduleState::map_member<>.

◆ operator==()

bool Opm::WellFractureSeeds::operator== ( const WellFractureSeeds & that) const

Equality predicate.

Parameters
[in]thatObject against which
will be tested for equality.
Returns
Whether or not
is the same as that.

◆ seedCells()

const std::vector< std::size_t > & Opm::WellFractureSeeds::seedCells ( ) const
inline

Retrieve this collection's fracture seed cells.

Returns
Sequence of Cartesian cell indices. The normal vector of the fracturing plane in cell
is
.

◆ serializeOp()

template<class Serializer>
void Opm::WellFractureSeeds::serializeOp ( Serializer & serializer)
inline

Convert between byte array and object representation.

Template Parameters
SerializerByte array conversion protocol.
Parameters
[in,out]serializerByte array conversion object.

◆ updateSeed()

bool Opm::WellFractureSeeds::updateSeed ( const std::size_t seedCellGlobal,
const NormalVector & seedNormal,
const SeedSize & seedSize )

Insert or update a fracture seed in current collection.

Parameters
[in]seedCellGlobalLinearised Cartesian cell index. Should typically correspond to a reservoir connection for the named well.
[in]seedNormalFracturing plane's normal vector. Need not be a unit normal as far as class WellFractureSeeds goes, but subsequent uses may prefer unit normals.
[in]seedSizeFracturing plane's initial size.
Returns
Whether or not a seed was inserted/updated. Typically 'true'.

The documentation for this class was generated from the following files:
  • opm/input/eclipse/Schedule/Well/WellFractureSeeds.hpp
  • opm/input/eclipse/Schedule/Well/WellFractureSeeds.cpp