ALP User Documentation
0.8.preview
Algebraic Programming User Documentation
|
Conjugate-multiply operator that conjugates the left- or right-hand operand before multiplication. More...
Inherits Operator< internal::conjugate_mul< IN1, IN2, OUT, conj_left, implementation > >.
Conjugate-multiply operator that conjugates the left- or right-hand operand before multiplication.
conj_left | Whether to conjugate the left-hand operand. |
If conj_left is false
, then the right-hand operand will be conjugated instead.
Mathematical notation: \( \odot(x,y) \to x^* * y \) if conj_left is true
, and \( \odot(x,y) \to x * y^* \) otherwise.
In general, this operator is not associative nor commutative. This operator is anti-commutative with respect to conjugation.
If the input domains IN1 and IN2 are not complex, then this operator is both associative and commutative. The algebraic type system takes this into account automatically.
If conj_left is true
, IN1 is complex, IN2 is non-complex, and OUT is non-complex, then this operator is both associative and commutative in the generalised sense where casting a complex number to a non-complex domain is interpreted as taking the norm of the complex number.
This also applies when conj_left is false
, IN1 is non-complex, IN2 is complex, and OUT is non-complex.
Since this rather non-standard notion of associativity and commutativity assumes a casting behaviour that is not standard in C++, the algebraic type system does not consider the above two combinations of template arguments when deriving associativity and commutativity properties.
If conj_left is true
, the following property holds: \( (a \odot b) \odot c = ( c \odot b ) \odot a. \)
If conj_left is false
, the following property holds instead: \( a \odot ( b \odot c ) = c \odot ( b \odot a ). \)
These properties are currently not exposed by the algebraic type system, and (thus) not used by the framework.
true
. false
.