Hi
I am evaluating Eigen::Tensor, it is very nice and allows to reduce some of my code a lot.
In tensor calculus the trace is an important operation.
could it be supported by Eigen:Tensor ?
For example
Eigen::Tensor<double,3> S( 2,2,2 );
Eigen::array<DimPair, 1> dims = {{DimPair(0, 1)}};
// compute the trace of S along the first and second dimensions
Eigen::Tensor<double,1> V=S.trace( dims );
Best regards
C.
--
Christophe Prud'hommeFeel++ Project Manager
Professor in Applied Mathematics
@ Université de Strasbourg (France)