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

grade involution (brombo/galgebra#40) #121

Open
eric-wieser opened this issue Dec 4, 2019 · 3 comments
Open

grade involution (brombo/galgebra#40) #121

eric-wieser opened this issue Dec 4, 2019 · 3 comments
Assignees
Labels
enhancement from brombo/galgebra Scraped from old webcaches of the now-deleted https://github.com/brombo/galgebra
Milestone

Comments

@eric-wieser
Copy link
Member

@Nelli-Khlyustova commented on Oct 4, 2018

Is grade involution available for general multivector?
For example, I have V = g3.mv('V', "mv") which is
V + V__xe1 + V__ye2 + V__ze3 + V__xye1^e2 + V__xze1^e3 + V__yze2^e3 + V__xyze1^e2^e3
But I wan to get this:
V - V__x
e1 - V__ye2 - V__ze3 + V__xye1^e2 + V__xze1^e3 + V__yze2^e3 - V__xyze1^e2^e3
How can I do this?

@mevangelista-alvarado commented on Jan 15 •
edited

Hi @Nelli-Khlyustova maybe this function helps you, regards.

def involution(multivector):
    '''This method takes a multivector a make your involution, example involution(x*ey+y*ex^ey)=x*ey- 
       y*ex^ey'''
    grades = multivector.grades
    for grade in grades:
        if grade % 2 == 1:
            multivector = multivector + (-2)*multivector.get_grade(grade)
    return multivector 

From http://webcache.googleusercontent.com/search?q=cache:https://github.com/brombo/galgebra/issues/40

@eric-wieser eric-wieser added the from brombo/galgebra Scraped from old webcaches of the now-deleted https://github.com/brombo/galgebra label Dec 4, 2019
@utensil
Copy link
Member

utensil commented Jun 2, 2020

involution should be implemented. See also my implementation at https://github.com/pygae/GAlgebra.jl/blob/874dd59844fee98b918d070d6265353dcd3c1547/src/mv.jl#L243 .

GitHub
Julia interface to GAlgebra via PyCall. Contribute to pygae/GAlgebra.jl development by creating an account on GitHub.

@utensil utensil self-assigned this Jun 2, 2020
@utensil utensil added this to the 0.6.0 milestone Jun 2, 2020
@eric-wieser
Copy link
Member Author

Should be able to do a (possibly) faster implementation along the lines of

return self.subs({
    b: b if len(i) % 2 == 0 else -b
    for i, b in zip(self.indexes.flat, self.blades.flat)
})

@utensil
Copy link
Member

utensil commented Jun 3, 2020

Yeah indeed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement from brombo/galgebra Scraped from old webcaches of the now-deleted https://github.com/brombo/galgebra
Projects
None yet
Development

No branches or pull requests

2 participants