[GiNaC-devel] [GiNaC-list] multiplying a matrix with 0 makes it become a scalar 0
Jens Vollinga
jensv at nikhef.nl
Mon Sep 22 11:52:01 CEST 2008
Dear all,
concerning this question from the GiNaC-list:
dummy-address at web.de schrieb:
> cout << "(3*blah).evalm(): " << (3*blah).evalm() << endl;
> // output:
> // [[3*a], [3*b], [3*c]]
>
> cout << "0*blah: " << 0*blah << endl;
> // output:
> // 0
seems to be a bug, and a rather old one (2000/2001).
My only idea at the moment is to check explicitly for matrices in the
epvector (mul.cpp lines 428-430) which is kind of stupid. Or we could
introduce another info_flag for non-scalar objects (set by matrix then)
and check for that flag? Any other ideas?
Regards,
Jens
More information about the GiNaC-devel
mailing list