Complex Multiplication
-
As I was skimming through a reference book tonight I ran across a description of the template class, complex. I know nothing of it, having had no prior need for it, but I'm curious about the operator:
complex& operator*=(const complex& rhs)
Does the return value contain the dot (scalar) or the cross (vector) product? And if it's the cross product, which part of the return value represents the component normal to the Re/Im plane? Can't imagine any immediate use for knowing, but who knows when the circumstance might arise... -
As I was skimming through a reference book tonight I ran across a description of the template class, complex. I know nothing of it, having had no prior need for it, but I'm curious about the operator:
complex& operator*=(const complex& rhs)
Does the return value contain the dot (scalar) or the cross (vector) product? And if it's the cross product, which part of the return value represents the component normal to the Re/Im plane? Can't imagine any immediate use for knowing, but who knows when the circumstance might arise...Check out the <complex> header, all the code's there. I found two *= functions, one that does each type of product. --Mike-- My really out-of-date homepage Buffy's on. Gotta go, bye! Sonork - 100.10414 AcidHelm Big fan of Alyson Hannigan.
-
Check out the <complex> header, all the code's there. I found two *= functions, one that does each type of product. --Mike-- My really out-of-date homepage Buffy's on. Gotta go, bye! Sonork - 100.10414 AcidHelm Big fan of Alyson Hannigan.
Thanks! As I mentioned, I don't have an immediate use for it, but one of the projects I've got in the back of my head may need the capability. It's more of a vector problem than a complex number application, but as long as we're limited to two dimensions (and the project is, fundamentally, two-dimensional) a solution using complex numbers will do nicely..