On Thu, Sep 3, 2015 at 8:41 AM, Titas Chanda <[email protected]> wrote:
> #### I have already posted it on github. #######
Please post a link, so that people don't need to search for it.
>
>
>
> Hi,
>
>
> sympy sqrt and conjuagte are not commuting for symbols....
>
>
>
>
> import sympy as sm
> a = sm.Symbol('a')
> sm.sqrt(sm.conjugate(a)) == sm.conjugate(sm.sqrt(a))
> False
>
>
>
> They are not even cancelling each other....
That's because they are not equal to each other. Just try some numbers:
In [1]: from cmath import sqrt
In [2]: a = -1
In [3]: sqrt(a.conjugate())
Out[3]: 1j
In [4]: sqrt(a).conjugate()
Out[4]: -1j
If you want to understand why, I have thorough notes here:
http://www.theoretical-physics.net/dev/math/complex.html
Let me know if you have any questions.
Ondrej
>
>
> Thanks....
>
> --
> You received this message because you are subscribed to the Google Groups
> "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/sympy.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/sympy/4f16f8f3-c32e-4d00-989c-e914a2923793%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit
https://groups.google.com/d/msgid/sympy/CADDwiVAQm0x5yvVMtL_k5HSzewCAb1A_LxOaNMNmKB-AAPf_-w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.