Skip to content

Implement arc! primitive - #51

Merged
j-fu merged 4 commits into
masterfrom
arc_primitive
Oct 12, 2026
Merged

j-fu merged 4 commits into
masterfrom
arc_primitive

Conversation

@jpthiele

@jpthiele jpthiele commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor

This adds a new primitive for mesh construction.
With it we can now construct a set of faces whose points lie on a circle around the parameter center.

Important note:
This still needs some more testing and especially automated tests.
It works for the 'Plate with a hole', but there the center is the origin and both points lie in the first quadrant.

I'll try to work on some tests tomorrow, so as a note to me (and maybe someone else) I would test

  • That an error is correctly thrown if start- and endpoint are not on the same circle around the center
  • That it correctly constructs arcs with points in all four quadrants w.r.t. the center
  • That it correclty constructs a large counter-clockwise arc when the endpoint is 'in front' of the starpoint when seen in between [0,2pi]
  • That it correctly constructs the arc for a nonzero center point

@jpthiele

Copy link
Copy Markdown
Contributor Author

Btw: I have found an error incircle! sin and cos where the wrong way around.
I fixed that in this PR since I added a test to ensure both produce the same points.

@j-fu FYI: If all tests pass now this PR is ready from my side

Comment thread src/primitives.jl Outdated
@j-fu

j-fu commented Oct 11, 2026

Copy link
Copy Markdown
Member

Looks good to me now. May be add a statement to the changelog.

@jpthiele

Copy link
Copy Markdown
Contributor Author

Looks good to me now. May be add a statement to the changelog.

Check!

And I rebased on current master so the changelog is up to date.

@j-fu
j-fu merged commit 5ed2f22 into master Oct 12, 2026
8 checks passed
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.

2 participants