Reference documentation for deal.II version GIT relicensing-437-g81ec864850 2024-04-19 07:30:02+00:00
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number > Class Template Reference

#include <deal.II/base/symmetric_tensor.h>

Public Types

using reference = typename AccessorTypes< rank, dim, constness, Number >::reference
 
using tensor_type = typename AccessorTypes< rank, dim, constness, Number >::tensor_type
 

Public Member Functions

DEAL_II_HOST constexpr Accessor< rank, dim, constness, P - 1, Number > operator[] (const unsigned int i)
 
DEAL_II_HOST constexpr Accessor< rank, dim, constness, P - 1, Number > operator[] (const unsigned int i) const
 

Private Member Functions

DEAL_II_HOST constexpr Accessor (tensor_type &tensor, const TableIndices< rank > &previous_indices)
 
DEAL_II_HOST constexpr Accessor (const Accessor &)=default
 

Private Attributes

tensor_typetensor
 
const TableIndices< rank > previous_indices
 

Friends

template<int , int , typename >
class ::SymmetricTensor
 
template<int , int , bool , int , typename >
class Accessor
 
class ::SymmetricTensor< rank, dim, Number >
 
class Accessor< rank, dim, constness, P+1, Number >
 

Detailed Description

template<int rank, int dim, bool constness, int P, typename Number>
class internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >

Definition at line 481 of file symmetric_tensor.h.

Member Typedef Documentation

◆ reference

template<int rank, int dim, bool constness, int P, typename Number >
using internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::reference = typename AccessorTypes<rank, dim, constness, Number>::reference

Import two alias from the switch class above.

Definition at line 487 of file symmetric_tensor.h.

◆ tensor_type

template<int rank, int dim, bool constness, int P, typename Number >
using internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::tensor_type = typename AccessorTypes<rank, dim, constness, Number>::tensor_type

Definition at line 489 of file symmetric_tensor.h.

Constructor & Destructor Documentation

◆ Accessor() [1/2]

template<int rank, int dim, bool constness, int P, typename Number >
DEAL_II_HOST constexpr internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::Accessor ( tensor_type tensor,
const TableIndices< rank > &  previous_indices 
)
constexprprivate

Constructor. Take a reference to the tensor object which we will access.

The second argument denotes the values of previous indices into the tensor. For example, for a rank-4 tensor, if P=2, then we will already have had two successive element selections (e.g. through tensor[1][2]), and the two index values have to be stored somewhere. This class therefore only makes use of the first rank-P elements of this array, but passes it on to the next level with P-1 which fills the next entry, and so on.

The constructor is made private in order to prevent you having such objects around. The only way to create such objects is via the Table class, which only generates them as temporary objects. This guarantees that the accessor objects go out of scope earlier than the mother object, avoid problems with data consistency.

◆ Accessor() [2/2]

template<int rank, int dim, bool constness, int P, typename Number >
DEAL_II_HOST constexpr internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::Accessor ( const Accessor< rank, dim, constness, P, Number > &  )
constexprprivatedefault

Copy constructor.

Member Function Documentation

◆ operator[]() [1/2]

template<int rank, int dim, bool constness, int P, typename Number >
DEAL_II_HOST constexpr Accessor< rank, dim, constness, P - 1, Number > internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::operator[] ( const unsigned int  i)
constexpr

Index operator.

◆ operator[]() [2/2]

template<int rank, int dim, bool constness, int P, typename Number >
DEAL_II_HOST constexpr Accessor< rank, dim, constness, P - 1, Number > internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::operator[] ( const unsigned int  i) const
constexpr

Index operator.

Friends And Related Symbol Documentation

◆ ::SymmetricTensor

template<int rank, int dim, bool constness, int P, typename Number >
template<int , int , typename >
friend class ::SymmetricTensor
friend

Definition at line 547 of file symmetric_tensor.h.

◆ Accessor

template<int rank, int dim, bool constness, int P, typename Number >
template<int , int , bool , int , typename >
friend class Accessor
friend

Definition at line 549 of file symmetric_tensor.h.

◆ ::SymmetricTensor< rank, dim, Number >

template<int rank, int dim, bool constness, int P, typename Number >
friend class ::SymmetricTensor< rank, dim, Number >
friend

Definition at line 549 of file symmetric_tensor.h.

◆ Accessor< rank, dim, constness, P+1, Number >

template<int rank, int dim, bool constness, int P, typename Number >
friend class Accessor< rank, dim, constness, P+1, Number >
friend

Definition at line 549 of file symmetric_tensor.h.

Member Data Documentation

◆ tensor

template<int rank, int dim, bool constness, int P, typename Number >
tensor_type& internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::tensor
private

Store the data given to the constructor.

Definition at line 541 of file symmetric_tensor.h.

◆ previous_indices

template<int rank, int dim, bool constness, int P, typename Number >
const TableIndices<rank> internal::SymmetricTensorAccessors::Accessor< rank, dim, constness, P, Number >::previous_indices
private

Definition at line 542 of file symmetric_tensor.h.


The documentation for this class was generated from the following file: