|
| UDQScalar (const double value, const std::size_t num=0) |
| Constructor.
|
|
| UDQScalar (const std::string &wgname, const std::size_t num=0) |
| Constructor.
|
|
void | operator+= (const UDQScalar &rhs) |
| Add other UDQ scalar to this.
|
|
void | operator+= (double rhs) |
| Add numeric value to this UDQ scalar.
|
|
void | operator*= (const UDQScalar &rhs) |
| Multiply UDQ scalar into this.
|
|
void | operator*= (double rhs) |
| Multiply numeric value into this.
|
|
void | operator/= (const UDQScalar &rhs) |
| Divide this UDQ scalar by other.
|
|
void | operator/= (double rhs) |
| Divide this UDQ scalar by numeric value.
|
|
void | operator-= (const UDQScalar &rhs) |
| Subtract other UDQ scalar from this.
|
|
void | operator-= (double rhs) |
| Add other UDQ scalar to this.
|
|
| operator bool () const |
| Predicate for whether or not this UDQ scalar has a defined value.
|
|
void | assign (const std::optional< double > &value) |
| Assign numeric value to this UDQ scalar.
|
|
void | assign (double value) |
| Assign numeric value to this UDQ scalar.
|
|
bool | defined () const |
| Predicate for whether or not this UDQ scalar has a defined value.
|
|
double | get () const |
| Retrive contained numeric value.
|
|
const std::optional< double > & | value () const |
| Retrive contained numeric value.
|
|
const std::string & | wgname () const |
| Retrive named well/group to which this scalar is associated.
|
|
std::size_t | number () const |
| Retrive numbered item, typically segment or connection, to which this scalar is associated.
|
|
bool | operator== (const UDQScalar &other) const |
| Equality predicate.
|
|
|
std::optional< double > | m_value {} |
| Scalar value.
|
|
std::string | m_wgname {} |
| Associated well/group name.
|
|
std::size_t | m_num = 0 |
| Numbered item.
|
|
◆ UDQScalar() [1/2]
Opm::UDQScalar::UDQScalar |
( |
const double |
value, |
|
|
const std::size_t |
num = 0 |
|
) |
| |
|
explicit |
Constructor.
Forms a UDQ scalar defined by its numeric value and, possibly, a particular numbered item.
- Parameters
-
[in] | value | Numeric value |
[in] | num | Item number. |
◆ UDQScalar() [2/2]
Opm::UDQScalar::UDQScalar |
( |
const std::string & |
wgname, |
|
|
const std::size_t |
num = 0 |
|
) |
| |
|
explicit |
Constructor.
Forms a UDQ scalar attached to a particular name and, possibly, a particular numbered item.
- Parameters
-
[in] | wgname | Named well or group to which this scalar is associated. |
[in] | num | Item number. |
◆ assign() [1/2]
void Opm::UDQScalar::assign |
( |
const std::optional< double > & |
value | ) |
|
Assign numeric value to this UDQ scalar.
- Parameters
-
[in] | value | Numeric value. Empty optional or non-finite value makes this UDQ scalar undefined. |
◆ assign() [2/2]
void Opm::UDQScalar::assign |
( |
double |
value | ) |
|
Assign numeric value to this UDQ scalar.
- Parameters
-
[in] | value | Numeric value. Non-finite value makes this UDQ scalar undefined. |
◆ get()
double Opm::UDQScalar::get |
( |
| ) |
const |
Retrive contained numeric value.
Throws an exception unless this UDQ scalar has a defined value.
◆ number()
std::size_t Opm::UDQScalar::number |
( |
| ) |
const |
|
inline |
Retrive numbered item, typically segment or connection, to which this scalar is associated.
Always zero for non-numbered UDQ scalars.
◆ operator bool()
Opm::UDQScalar::operator bool |
( |
| ) |
const |
Predicate for whether or not this UDQ scalar has a defined value.
- Returns
bool defined() const
Predicate for whether or not this UDQ scalar has a defined value.
Definition UDQSet.cpp:51
.
◆ operator*=() [1/2]
void Opm::UDQScalar::operator*= |
( |
const UDQScalar & |
rhs | ) |
|
Multiply UDQ scalar into this.
Result is defined if both this and other scalar are defined, and if the product is a finite value.
- Parameters
-
◆ operator*=() [2/2]
void Opm::UDQScalar::operator*= |
( |
double |
rhs | ) |
|
Multiply numeric value into this.
Result is defined if *this
is defined and the product is a finite value.
- Parameters
-
◆ operator+=() [1/2]
void Opm::UDQScalar::operator+= |
( |
const UDQScalar & |
rhs | ) |
|
Add other UDQ scalar to this.
Result is defined if both this and other scalar are defined, and the sum is a finite value.
- Parameters
-
◆ operator+=() [2/2]
void Opm::UDQScalar::operator+= |
( |
double |
rhs | ) |
|
Add numeric value to this UDQ scalar.
Result is defined if *this
is defined and the sum is a finite value.
- Parameters
-
◆ operator-=() [1/2]
void Opm::UDQScalar::operator-= |
( |
const UDQScalar & |
rhs | ) |
|
Subtract other UDQ scalar from this.
Result is defined if both this and other scalar are defined, and if the difference is a finite value.
- Parameters
-
◆ operator-=() [2/2]
void Opm::UDQScalar::operator-= |
( |
double |
rhs | ) |
|
Add other UDQ scalar to this.
Result is defined if *this
is defined and the difference is a finite value.
- Parameters
-
◆ operator/=() [1/2]
void Opm::UDQScalar::operator/= |
( |
const UDQScalar & |
rhs | ) |
|
Divide this UDQ scalar by other.
Result is defined if both this and other scalar are defined, and the quotient is a finite value.
- Parameters
-
◆ operator/=() [2/2]
void Opm::UDQScalar::operator/= |
( |
double |
rhs | ) |
|
Divide this UDQ scalar by numeric value.
Result is defined if *this
is defined and the quotient is a finite value.
- Parameters
-
◆ operator==()
bool Opm::UDQScalar::operator== |
( |
const UDQScalar & |
other | ) |
const |
Equality predicate.
- Parameters
-
[in] | UDQ | scalar to which this scalar will be compared for equality. |
◆ value()
const std::optional< double > & Opm::UDQScalar::value |
( |
| ) |
const |
|
inline |
Retrive contained numeric value.
Empty optional unless this scalar has a defined value.
◆ m_num
std::size_t Opm::UDQScalar::m_num = 0 |
Numbered item.
Typically segment or connection. Zero for non-numbered items.
The documentation for this class was generated from the following files:
- opm/input/eclipse/Schedule/UDQ/UDQSet.hpp
- opm/input/eclipse/Schedule/UDQ/UDQSet.cpp