Registered Member
|
Hello,
I would like to introduce a pre-defined matrix such as Zero() or Identity(). Mine is called Invalid() and is currently generated this way inside MatrixBase_plugin.h:
I am a bit embarrassed with this bit of code because each time I call function Invalid() it refills the matrix. Anyone has a better than mine? Thanks, Antoine. |
Moderator
|
You could return a CwiseNullaryOp, here a constant matrix:
ConstantReturnType Invalid() { return Constant(std::numeric_limits<Scalar>::max()); } |
Registered Member
|
Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot], ourcraft