www.mooseframework.org
Classes | Functions
RankThreeTensor.h File Reference

Go to the source code of this file.

Classes

class  RankThreeTensor
 RankThreeTensor is designed to handle any N-dimensional third order tensor, r. More...
 

Functions

template<typename T >
void mooseSetToZero (T &v)
 Helper function templates to set a variable to zero. More...
 
template<>
void mooseSetToZero< RankThreeTensor > (RankThreeTensor &v)
 Helper function template specialization to set an object to zero. More...
 
template<>
void dataStore (std::ostream &, RankThreeTensor &, void *)
 
template<>
void dataLoad (std::istream &, RankThreeTensor &, void *)
 
RankThreeTensor operator* (Real a, const RankThreeTensor &b)
 
RankTwoTensor operator* (const RealVectorValue &, const RankThreeTensor &)
 r=v*A where r is rank 2, v is vector and A is rank 3 More...
 

Function Documentation

template<>
void dataLoad ( std::istream &  ,
RankThreeTensor ,
void *   
)

Definition at line 41 of file RankThreeTensor.C.

42 {
43  dataLoad(stream, rtht._vals, context);
44 }
void dataLoad(std::istream &stream, RankThreeTensor &rtht, void *context)
template<>
void dataStore ( std::ostream &  ,
RankThreeTensor ,
void *   
)

Definition at line 34 of file RankThreeTensor.C.

35 {
36  dataStore(stream, rtht._vals, context);
37 }
void dataStore(std::ostream &stream, RankThreeTensor &rtht, void *context)
template<typename T >
void mooseSetToZero ( T &  v)
inline

Helper function templates to set a variable to zero.

Specializations may have to be implemented (for examples see RankTwoTensor, RankFourTensor).

The default for non-pointer types is to assign zero. This should either do something sensible, or throw a compiler error. Otherwise the T type is designed badly.

Definition at line 269 of file MaterialPropertyInterface.h.

270 {
276  v = 0;
277 }
template<>
void mooseSetToZero< RankThreeTensor > ( RankThreeTensor v)

Helper function template specialization to set an object to zero.

Needed by DerivativeMaterialInterface

Definition at line 27 of file RankThreeTensor.C.

28 {
29  v.zero();
30 }
void zero()
Zeros out the tensor.
RankThreeTensor operator* ( Real  a,
const RankThreeTensor b 
)
inline

Definition at line 199 of file RankThreeTensor.h.

199 { return b * a; }
RankTwoTensor operator* ( const RealVectorValue &  ,
const RankThreeTensor  
)

r=v*A where r is rank 2, v is vector and A is rank 3

Definition at line 344 of file RankThreeTensor.C.

345 {
346  RankTwoTensor result;
347 
348  for (unsigned int i = 0; i < LIBMESH_DIM; ++i)
349  for (unsigned int j = 0; j < LIBMESH_DIM; ++j)
350  for (unsigned int k = 0; k < LIBMESH_DIM; ++k)
351  result(i, j) += p(k) * b(k, i, j);
352 
353  return result;
354 }
RankTwoTensor is designed to handle the Stress or Strain Tensor for a fully anisotropic material...
Definition: RankTwoTensor.h:45