SubField is a Field obtained as a section of another Field, without its own allocation. SubField is derived from a SubList rather than a List. More...
Public Types | |
typedef pTraits< Type >::cmptType | cmptType |
Component type. More... | |
Public Member Functions | |
SubField () noexcept=default | |
Default construct, zero-sized and nullptr. More... | |
SubField (const SubField< Type > &sfield) | |
Copy construct (shallow copy) More... | |
SubField (const SubList< Type > &list) | |
Copy construct from SubList. More... | |
SubField (const UList< Type > &list) | |
Construct from UList, the entire size. More... | |
SubField (const UList< Type > &list, const label subSize) | |
Construct from UList with a given sub-list size, start at 0. More... | |
SubField (const UList< Type > &list, const label subSize, const label startIndex) | |
Construct from UList with a given size and start index. More... | |
SubField (const UList< Type > &list, const labelRange &range) | |
Construct from UList and a (start,size) range. More... | |
SubField (const labelRange &range, const UList< Type > &list) | |
tmp< Field< cmptType > > | component (const direction) const |
Return a component field of the field. More... | |
tmp< Field< Type > > | T () const |
Return the field transpose (only defined for second rank tensors) More... | |
operator const Foam::Field< Type > & () const | |
Allow cast to a const Field<Type>&. More... | |
void | operator= (const SubField< Type > &) |
Copy assign via UList operator. Takes linear time. More... | |
void | operator= (const Field< Type > &) |
Copy assign via UList operator. Takes linear time. More... | |
void | operator= (const Type &val) |
Assign all entries to the given value. More... | |
void | operator= (const Foam::zero) |
Assign all entries to zero. More... | |
template<class Form , direction Ncmpts> | |
void | operator= (const VectorSpace< Form, Type, Ncmpts > &rhs) |
Copy assign via UList operator. Takes linear time. More... | |
void | operator+= (const Type &val) |
Add value to each entry. More... | |
void | operator-= (const Type &val) |
Subtract value from each entry. More... | |
void | operator*= (const scalar &s) |
Multiply each entry by value. More... | |
void | operator/= (const scalar &s) |
Divide each entry by value. More... | |
Static Public Member Functions | |
static const SubField< Type > & | null () |
Return nullObject reference SubField. More... | |
SubField is a Field obtained as a section of another Field, without its own allocation. SubField is derived from a SubList rather than a List.
Component type.
Definition at line 66 of file SubField.H.
|
defaultnoexcept |
Default construct, zero-sized and nullptr.
Copy construct (shallow copy)
Definition at line 42 of file SubFieldI.H.
Copy construct from SubList.
Definition at line 52 of file SubFieldI.H.
Construct from UList, the entire size.
Definition at line 62 of file SubFieldI.H.
Construct from UList with a given sub-list size, start at 0.
Definition at line 72 of file SubFieldI.H.
Construct from UList with a given size and start index.
Definition at line 83 of file SubFieldI.H.
|
inline |
Construct from UList and a (start,size) range.
The range is subsetted with the list size itself to ensure that the result always addresses a valid section of the list.
Definition at line 95 of file SubFieldI.H.
|
inline |
Construct from UList and a (start,size) range, but bypassing run-time range checking.
Definition at line 106 of file SubFieldI.H.
|
inlinestatic |
Return nullObject reference SubField.
Definition at line 32 of file SubFieldI.H.
|
inline |
Return a component field of the field.
Definition at line 120 of file SubFieldI.H.
|
inline |
Return the field transpose (only defined for second rank tensors)
Definition at line 129 of file SubFieldI.H.
|
inline |
Allow cast to a const Field<Type>&.
Definition at line 138 of file SubFieldI.H.
|
inline |
Copy assign via UList operator. Takes linear time.
Definition at line 145 of file SubFieldI.H.
Referenced by SubDimensionedField< Type, GeoMesh >::operator=().
|
inline |
Copy assign via UList operator. Takes linear time.
Definition at line 152 of file SubFieldI.H.
|
inline |
Assign all entries to the given value.
Definition at line 159 of file SubFieldI.H.
|
inline |
|
inline |
Copy assign via UList operator. Takes linear time.
Definition at line 175 of file SubFieldI.H.
References forAll.
|
inline |
Add value to each entry.
Definition at line 187 of file SubFieldI.H.
|
inline |
Subtract value from each entry.
Definition at line 197 of file SubFieldI.H.
|
inline |
|
inline |