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

Question: Algebra for computational geometry and graphics #77

Open
TsurHerman opened this issue Aug 27, 2020 · 4 comments
Open

Question: Algebra for computational geometry and graphics #77

TsurHerman opened this issue Aug 27, 2020 · 4 comments
Labels

Comments

@TsurHerman
Copy link

TsurHerman commented Aug 27, 2020

I would like to experiment with this in my line of work.
What basis/algebra do I need for 3D navigation algorithms / computer graphics?

like:

  1. finding the line intersection of two planes
  2. finding the point intersection of 3 planes.
  3. translation and rotation of points, rotation of vectors.
  4. barycentric coordinates of a point in a 3D polytope
@maxfreu
Copy link

maxfreu commented Aug 27, 2020

I am definitely not an expert, but according to e.g. this video (which I think is really nice), 3D projective geometric algebra is suitable. And I think you can create it using @basis "0,1,1,1".

@chakravala
Copy link
Owner

chakravala commented Aug 31, 2020

Thank you for your question. This repository is currently mainly intended to give access to geometric algebra for researchers.

I recall you @TsurHerman from discussions on the Julia discourse in the past, and would be happy to have you as a user.

You can select an algebra to do all those things you requested in any number of dimensions here (intersections are possible by an application of Grassmann's exterior and regressive products, transformations of geometric objects are enabled by the outermorphisms of the algebra, and barycentric coordinates are handled by adding another dimension to your algebra.

You can use the basis"0,1,1,1" for this purpose, but it's not the only choice, there are multiple choices always.

However, I don't currently have time to teach the usage of these algebras in addition to programming. If you would like tutorials or explanations from me personally, please wait until I publish a paper or until I publish a blog post for more documentation. Until then, it is necessary for you to make your own research or read other publications about how to use these algebras in your work.

@TsurHerman
Copy link
Author

Thanks, I used basis"1,1,1,0" for Projective Geometry in 3D(PGA3) as explained in the YouTube video and the course notes.
Some minor inconvenience is that they start counting indices at 0 where as Grassman.jl starts at 1 ... but I'm a grown man
I can do the index swap myself ... there is no complaint here.

Other than that ever since I went down the rabbit hole of GA (a week or so) I can see why you and others are so fascinated with this construct.
It is fundamental and beautiful.

You can select an algebra to do all those things you requested in any number of dimensions here (intersections are possible by an application of Grassmann's exterior and regressive products, transformations of geometric objects are enabled by the outermorphisms of the algebra, and barycentric coordinates are handled by adding another dimension to your algebra.

Thanks for the notes I'll look into it.
I'll start with PGA3 as it is the basis of Ganja.js and has easy enough documentation to read quickly, and hopefully develop
enough confidence and intuition to experiment with different algebras and different representations in the algebra.

@maxfreu
Copy link

maxfreu commented Sep 1, 2020

You can rename the basis blades; take a look here. And remember to change the sign accordingly when permuting indices :)

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

No branches or pull requests

3 participants