Broadcasting order of arguments
Submitted by nfo..@..il.com
Assigned to Nobody
Link to original bugzilla bug (#906)
Version: 3.2
Description
I want to pointwise multiply the each row of a matrix by a vector which can easily be done with broadcasting as A.rowwise() * a.transpose()
(where A
and a
are appropriately defined). However, the mathematically equivalent expression a.transpose * A.rowwise()
results in a compilation error saying that operator*
is not defined for the types involved.
From Bug #157 (closed) it looks like the operator is just not implemented with the visitor on the right rather than a shortcoming of the expression generation. However, this seems like a pretty high-priority issue to address since the expressions are mathematically the same and it seems ridiculous that people are forced to write them one way. If these missing cases cannot be implemented then at the very least there should be clear documentation in the broadcasting section on this.