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

Is there a function for line-line intersection? #424

Open
davibarreira opened this issue Dec 13, 2022 · 0 comments
Open

Is there a function for line-line intersection? #424

davibarreira opened this issue Dec 13, 2022 · 0 comments

Comments

@davibarreira
Copy link

Hey, thanks a lot for the package. I was wondering if there is a function for line-line intersection, or perhaps line-segment to line-segment intersection. I've tried the meet function, but it does not work. I've also tried the get_line_intersection, but it returns an error.

Here is a simple example:

a = up(0)
b = up(cl.e1 + cl.e2)
l1 = (a ^ b ^ cl.einf).normal()

a = up(2*cl.e2)
b = up(2*cl.e1 + 2*cl.e2)
l2 = (a ^ b ^ cl.einf).normal()

meet(l1,l2) # returns 0
get_line_intersection(l1,l2) # error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant