3D Math Data structures/SIMD
Janice Caron
caron800 at googlemail.com
Sun Dec 23 01:08:36 PST 2007
On 12/23/07, "Jérôme M. Berger" <jeberger at free.fr> wrote:
> However, it is the mathematically accepted definition for a binary
operator
You got me on that one. I completely stand corrected. Guess I've been
doing computing for so long that I fell into the trap of mixing
computer language jargon with math jargon. In D, and other C-like
languages, an "operator" is anything that uses infix notation. In
maths, as you pointed out, it has another meaning entirely. But even
so, this is D we're talking about, and I don't see anyone arguing that
matrix multiplication shouldn't use opMul.
> I'd tend to agree on that one. Except that now, we need to find a
> reasonably short and meaningful name for "element-wise
> multiplication" ("dot", "cross" and "outer" work fine for the other
> types of multiplication).
Once upon a time, we were promised elementwise operations across the
board. For example
a[] = b[]; //elementwise assignment
a[] = b[] + c[]; //elementwise addition
a[] = b[] * c[]; //elementwise multiplication
Maybe there was some reason why Walter couldn't get it to work, but it
would be nice to see it back on the drawing board. Even if it couldn't
be made to work for generic arrays, maybe it could be made to work for
new primitve types like float4?
More information about the Digitalmars-d
mailing list