SyTen
tensorblock_operators.h File Reference

Operators for TensorBlock. More...

+ Include dependency graph for tensorblock_operators.h:
+ This graph shows which files directly or indirectly include this file:

Namespaces

 syten
 Syten namespace.
 

Functions

Convenience functions defined for each block
template<Rank rank>
SRDef syten::abs (TensorBlock< rank > const &a)
 Gives some measure on the absolute value of the block. More...
 
template<Rank rank>
SRDef syten::absSqd (TensorBlock< rank > const &a)
 Squared version of syten::abs as it is sometimes used in places. More...
 
template<Rank rank>
std::pair< std::size_t, SRDef > syten::avgAbs (TensorBlock< rank > const &a)
 Returns the average of the absolute values of the non-zero entries of the tensor block in a pair <num_entries, summed_value>. More...
 
template<Rank rank>
SRDef syten::max (TensorBlock< rank > const &a)
 Returns the element with the greatest magnitude in the tensor block. More...
 
template<Rank rank>
std::ostreamsyten::operator<< (std::ostream &out, TensorBlock< rank > const &t)
 Pretty output for a tensor block. More...
 
SDef syten::trace (TensorBlock< 2 > const &a)
 Calculates the trace of this block. More...
 
Operators for scaling of TensorBlock and scalars
template<Rank rank>
TensorBlock< rank > syten::operator* (SDef const s, TensorBlock< rank > const &t)
 Multiplies each element of t and s to return s t More...
 
template<Rank rank>
TensorBlock< rank > syten::operator* (TensorBlock< rank > const &t, SDef const s)
 Multiplies each element of t and s to return s t More...
 
template<Rank rank>
TensorBlock< rank > & syten::operator*= (TensorBlock< rank > &t, SDef const s)
 Multiplies each element of t by a scalar s More...
 
template<Rank rank>
TensorBlock< rank > syten::operator/ (TensorBlock< rank > const &t, SDef const s)
 Divides each element of t by s to return 1/s t More...
 
template<Rank rank>
TensorBlock< rank > & syten::operator/= (TensorBlock< rank > &t, SDef const s)
 Divides each element of t by s More...
 

Detailed Description

Operators for TensorBlock.