Re: [eigen] return type of inner product

[ Thread Index | Date Index | More Archives ]

2009/10/1 Gael Guennebaud <gael.guennebaud@xxxxxxxxx>:
> hi,
> I still have a FIXME in the Product.h file that I'd like to discuss:
> // FIXME : maybe the "inner product" could return a Scalar
> // instead of a 1x1 matrix ??
> // Pro: more natural for the user
> // Cons: this could be a problem if in a meta unrolled algorithm a matrix-matrix
> // product ends up to a row-vector times col-vector product...
> any opinion ?
> note that here "inner product" denotes any row-vector times col-vector
> products, and not the .dot() function which of course returns a
> scalar.

Hm, I really can't make myself an opinion either way!

I don't think that the problem for meta-unrolled algorithms is very
important, as that's a very rare use case and these could well handle
a special case with a specialization.

So i'm 63.7% in favor of your proposal to make it return a Scalar.


Mail converted by MHonArc 2.6.19+