www.mooseframework.org
Public Member Functions | Private Attributes | List of all members
PolycrystalICTools::AdjacencyMatrix< T > Class Template Reference

Simple 2D block matrix indicating graph adjacency. More...

#include <PolycrystalICTools.h>

Public Member Functions

 AdjacencyMatrix (unsigned int size)
 
 ~AdjacencyMatrix ()=default
 
 AdjacencyMatrix (const AdjacencyMatrix &f)=delete
 
AdjacencyMatrixoperator= (const AdjacencyMatrix &f)=delete
 
 AdjacencyMatrix (AdjacencyMatrix &&f)=default
 
AdjacencyMatrixoperator= (AdjacencyMatrix &&f)=default
 
T & operator() (unsigned int i, unsigned int j)
 
operator() (unsigned int i, unsigned int j) const
 
std::size_t size () const
 
T * rawDataPtr ()
 

Private Attributes

const std::size_t _size
 
std::vector< T > _data
 

Detailed Description

template<typename T>
class PolycrystalICTools::AdjacencyMatrix< T >

Simple 2D block matrix indicating graph adjacency.

We use a 1D storage structure so that we can pass it to PETSc easily.

Definition at line 22 of file PolycrystalICTools.h.

Constructor & Destructor Documentation

template<typename T>
PolycrystalICTools::AdjacencyMatrix< T >::AdjacencyMatrix ( unsigned int  size)
inline
template<typename T>
PolycrystalICTools::AdjacencyMatrix< T >::~AdjacencyMatrix ( )
default
template<typename T>
PolycrystalICTools::AdjacencyMatrix< T >::AdjacencyMatrix ( const AdjacencyMatrix< T > &  f)
delete
template<typename T>
PolycrystalICTools::AdjacencyMatrix< T >::AdjacencyMatrix ( AdjacencyMatrix< T > &&  f)
default

Member Function Documentation

template<typename T>
T& PolycrystalICTools::AdjacencyMatrix< T >::operator() ( unsigned int  i,
unsigned int  j 
)
inline

Definition at line 37 of file PolycrystalICTools.h.

37 { return _data[i * _size + j]; }
template<typename T>
T PolycrystalICTools::AdjacencyMatrix< T >::operator() ( unsigned int  i,
unsigned int  j 
) const
inline

Definition at line 38 of file PolycrystalICTools.h.

38 { return _data[i * _size + j]; }
template<typename T>
AdjacencyMatrix& PolycrystalICTools::AdjacencyMatrix< T >::operator= ( const AdjacencyMatrix< T > &  f)
delete
template<typename T>
AdjacencyMatrix& PolycrystalICTools::AdjacencyMatrix< T >::operator= ( AdjacencyMatrix< T > &&  f)
default
template<typename T>
T* PolycrystalICTools::AdjacencyMatrix< T >::rawDataPtr ( )
inline

Definition at line 41 of file PolycrystalICTools.h.

Referenced by PolycrystalICTools::assignOpsToGrains().

41 { return _data.data(); }
template<typename T>
std::size_t PolycrystalICTools::AdjacencyMatrix< T >::size ( ) const
inline

Definition at line 40 of file PolycrystalICTools.h.

40 { return _size; }

Member Data Documentation

template<typename T>
std::vector<T> PolycrystalICTools::AdjacencyMatrix< T >::_data
private
template<typename T>
const std::size_t PolycrystalICTools::AdjacencyMatrix< T >::_size
private

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