20#ifndef LIBMESH_RAW_ACCESSOR_H
21#define LIBMESH_RAW_ACCESSOR_H
24#include "libmesh/libmesh_common.h"
26#include "libmesh/tensor_value.h"
27#include "libmesh/vector_value.h"
28#include "libmesh/type_n_tensor.h"
36template <
typename FieldType>
63#ifdef LIBMESH_USE_COMPLEX_NUMBERS
92template <
typename FieldType>
119 libmesh_assert_equal_to (i, 0);
127 libmesh_assert_less (i, this->_dim);
128 return this->_data(i);
135 libmesh_assert_less (k, this->_dim*this->_dim);
140 unsigned int ii = k/_dim;
141 unsigned int jj = k - ii*_dim;
143 return this->_data(ii,jj);
149template <
unsigned int N,
typename ScalarType>
172 ScalarType dummy = 0;
178#ifdef LIBMESH_USE_COMPLEX_NUMBERS
183 libmesh_assert_equal_to (i, 0);
191 libmesh_assert_less (i, this->_dim);
192 return this->_data(i);
199 libmesh_assert_less (k, this->_dim*this->_dim);
204 unsigned int jj = k/_dim;
205 unsigned int ii = k - jj*_dim;
207 return this->_data(ii,jj);
const RawFieldType< FieldType >::type & operator()(unsigned int) const
TypeNTensor< N, ScalarType > FieldType
RawFieldType< FieldType >::type & operator()(unsigned int)
RawAccessor(FieldType &data, const unsigned int dim)
This class provides single index access to FieldType (i.e.
RawFieldType< FieldType >::type & operator()(unsigned int i)
RawAccessor(FieldType &data, const unsigned int dim)
const RawFieldType< FieldType >::type & operator()(unsigned int i) const
This class defines a tensor in LIBMESH_DIM dimensional Real or Complex space.
This class will eventually define a rank-N tensor in LIBMESH_DIM dimensional space of type T.
This class defines a vector in LIBMESH_DIM dimensional Real or Complex space.
The libMesh namespace provides an interface to certain functionality in the library.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
What underlying data type would we need to access in each field?