Skip to content

Conversation

@rdemaria
Copy link
Contributor

Fix an off bound error that show using openmp. @piotrskowronski could you verify?

Fix an off bound error that show using openmp. @piotrskowronski could you verify?
@ldeniau
Copy link
Contributor

ldeniau commented Mar 27, 2024

The fix looks ok to me as the polygon is closed with POLYGN points when allocated in Sn_mad_like.f90.
Apart from small details, it's the same code (after fixing the bound) as mine in MAD-NG (written 5 years ago):
https://github.com/MethodicalAcceleratorDesign/MAD-NG/blob/0d1749f893ef52f932cb24379fb7800743607831/src/mad_poly.c#L37
I found a nice ref with a C implementation at http://geomalgorithms.com/a03-_inclusion.html

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

Successfully merging this pull request may close these issues.

3 participants