Re: [eigen] On a flexible API for submatrices, slicing, indexing, masking, etc. |
[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]
On 5 Jan 2017, at 12:06, Gael Guennebaud <gael.guennebaud@xxxxxxxxx> wrote:Finally, these examples also reveal that the "_expression_-based" API outperforms all other alternatives, in all cases.moreover, that api looks much more composable than alternatives; for example, one could overload && || to meandisjunction and union resp., to write things likeA( 5 <= iota <= 9 && iota*2+1 ) // all odd numbers between 5 and 9this improves decoupling of subexpressions in a meaningful way ( at the cost of more metaprogramming to translate commonforms into the underlying optimal ’slicing’ logic ).
as a side note, concerning ic<N> and friends, why not using something ala std::placeholders: ?iota * _2 + _1( sorry if it has already been suggested :) )
Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |