Registered Member
|
Hi, I am new to using Eigen, so I apologize if this is an obvious question, but I was unable to find any answer through google or this forum
I have written the following
and the code crashes with an error message
If I change it to
i.e. I remove the transpose at the end, the code runs fine and I get what I expect. So why does the final transpose cause the code to crash, is it simply not possible to transpose at the end of an expression like that or is there something else I am missing? Grateful for any answers. |
Moderator
|
I cannot reproduce using either 3.1, 3.2, 3.3 versions of Eigen, and gcc or clang, with and without compiler optimizations. Test program:
As usual with memory issue, the core of the problem is not where the problem occurs. Running your program within a memory debugger tool (like valgrind) should help you to spot the true issue. Of course, if you can reproduce your issue with a self-contained exemple (as the one above), then please provide eigen version, compiler version, and all compiler flags so that we can reproduce. |
Registered Member
|
Hmm, that's peculiar.
I am running eigen 3.1.3 (in Windows/Visual Studio, without optimization) but my code barely does anything else than what I posted. The full file is
I also tried copying your code and replacing the entire mainloop with it and I got the same error as before. So perhaps it is somehow a platform issue? EDIT: I suppose all compiler flags would be
Which is mostly just **** that is auto-included in Visual Studio... |
Registered Member
|
I can run your last code without problem (VS2013, eigen 3.2.6). Is there anything to check in the header "UnitTest.h" ?
|
Moderator
|
Your are using a pretty old version of Eigen, please try first with the latest stable release (3.2.6).
|
Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot], q.ignora