Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename PMComplex >> conjugated to complexConjugate #192

Open
olekscode opened this issue Feb 23, 2021 · 5 comments
Open

Rename PMComplex >> conjugated to complexConjugate #192

olekscode opened this issue Feb 23, 2021 · 5 comments
Assignees

Comments

@olekscode
Copy link
Member

olekscode commented Feb 23, 2021

Because numbers can also be conjugate in a different sense: 5 + 5 sqrt is conjugate to 5 - 5 sqrt.
https://math.stackexchange.com/questions/3397053/whats-the-correct-definition-of-conjugate-and-do-we-identify-them

Also, this message should be implemented by Number

5 complexConjugate.  "5"
(5 + 3i) complexConjugate. "5 - 3i"

And testing:

5 isComplexConjugateOf: 5. "true"
(5 + 3i) isComplexConjugateOf: (5 - 3i). "true"
@olekscode olekscode changed the title Rename PMComplex >> conjugated to conjugated Rename PMComplex >> conjugated to complexConjugate Feb 23, 2021
@hemalvarambhia hemalvarambhia self-assigned this Apr 2, 2022
@SergeStinckwich SergeStinckwich changed the title Rename PMComplex >> conjugated to complexConjugate Rename PMComplex >> conjugated to complexConjugate Apr 5, 2022
@hemalvarambhia
Copy link
Contributor

Screenshot 2022-04-10 at 21 50 50

Screenshot 2022-04-10 at 21 50 34

@hemalvarambhia
Copy link
Contributor

I am noticing now that the Complex Number Test Class has a large number of methods. A refactor might split this up, and there are a number of ways to do that (I'll provide a list in a moment...).

@nicolas-cellier-aka-nice
Copy link
Contributor

Because quaternions also have a conjugate operation, will you need yet another quaternionConjugate selector?

@hemalvarambhia
Copy link
Contributor

I referred to Wikipedia, and the word used there is conjugation:

Conjugation of quaternions is analogous to conjugation of complex numbers and to transposition (also known as reversal) of elements of Clifford algebras. To define it, let {\displaystyle q=a+b,\mathbf {i} +c,\mathbf {j} +d,\mathbf {k} } be a quaternion. The conjugate of q is the quaternion {\displaystyle q^{*}=a-b,\mathbf {i} -c,\mathbf {j} -d,\mathbf {k} }. It is denoted by q∗, qt, {\displaystyle {\tilde {q}}}, or q.[7] Conjugation is an involution, meaning that it is its own inverse, so conjugating an element twice returns the original element. The conjugate of a product of two quaternions is the product of the conjugates in the reverse order. That is, if p and q are quaternions, then (pq)∗ = q∗p∗, not p∗q∗.

The conjugation of a quaternion, in stark contrast to the complex setting, can be expressed with multiplication and addition of quaternions:

{\displaystyle q^{*}=-{\frac {1}{2}}(q+,\mathbf {i} ,q,\mathbf {i} +,\mathbf {j} ,q,\mathbf {j} +,\mathbf {k} ,q,\mathbf {k} )~.}

@hemalvarambhia
Copy link
Contributor

hemalvarambhia commented Apr 23, 2022

Are we discovering that conjugate may have meanings in different contexts? I.e. bounded contexts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants