Using galgebra at github.com/brombo/galgebra

and

from ga import Ga
base = Ga('e*1|2')
I = base.I()
Iinv = I.inv()
print 'I =',I
print '1/I =',Iinv
print 'I*(1/I) =',I*Iinv

I get

I = e_1^e_2/sqrt(Abs((e_1.e_1)*(e_2.e_2) - (e_1.e_2)**2))
1/I = -sqrt(Abs((e_1.e_1)*(e_2.e_2) -
(e_1.e_2)**2))*e_1^e_2/((e_1.e_1)*(e_2.e_2) - (e_1.e_2)**2)
I*(1/I) = 1

Somethings have changed quite a bit.  Look at the documentation at
github.com/brombo/galgebra

On Sat, Apr 4, 2015 at 11:10 AM, Mike Boyle <[email protected]>
wrote:

> This bug apparently shows up with some help from the formatting method.
> In particular, if you take out the
>
> sympy.galgebra.Format(ipy=True)
>
> line, you get the correct answer.
>
> The formatting code in galgebra is a bit of a mess, and in fact the whole
> project is moving <https://github.com/sympy/sympy/issues/8365> out of
> sympy to its own project <https://github.com/brombo/galgebra>.  Anyway,
> I've opened up a bug report about this on github
> <https://github.com/sympy/sympy/issues/9245>.  In the meantime, I suggest
> you just stick to ugly formatting.
>
>
>
>
> On Friday, April 3, 2015 at 9:55:17 PM UTC-4, chaowen guo wrote:
>>
>> A test example:
>>
>> import sympy.galgebra
>> sympy.galgebra.Format(ipy=True)
>> base=sympy.galgebra.MV.setup('e*1|2')
>> str(sympy.galgebra.MV.I.inv())
>>
>> output: '-\\bm{e_{1}\\W e_{2}}'
>> and the output just print the numerator and neglect denominator
>>
>> because the correct answer is:
>> str(sympy.galgebra.MV.Iinv)
>> output: '- \\frac{1}{\\lp e_{1}\\cdot e_{1}\\rp  \\lp e_{2}\\cdot
>> e_{2}\\rp  - \\lp e_{1}\\cdot e_{2}\\rp ^{2}}\\bm{e_{1}\\W e_{2}}'
>> now it has numerator and denominator
>>
>> Chaowen GUO
>>
>  --
> 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/24b155aa-dc45-4666-87a7-29313b4000fe%40googlegroups.com
> <https://groups.google.com/d/msgid/sympy/24b155aa-dc45-4666-87a7-29313b4000fe%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>
> 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/CALOxT-nm8vZaByZy8HDUxrcQksfaS0eh-FCovS1OK8VQZzLMDw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to