Re: [eigen] Matrix2i mean

[ Thread Index | Date Index | More Archives ]


You could potentially use SafeInt as your custom scalar type:
(with a performance penalty) then you should be safe from these issues.


On Tue, 5 Nov 2019 at 15:46, Peter <list@xxxxxxxxxxxxxxxxx> wrote:
Dear Christoph,

Am 05.11.19 um 16:36 schrieb Christoph Hertzberg:

> You could create your own custom type `my_int16` for which `my_int16 * my_int16` results in a `my_int32` (this needs to be told to Eigen, similar to how real*complex products are handled).

This could indeed be a way.
BTW, I was thinking in the spirit of exact scalar products for floating points like in C-XSC.
Maybe an option for Eigen 7.0.

Best regards,

Mail converted by MHonArc 2.6.19+