-
Notifications
You must be signed in to change notification settings - Fork 31
Lattice Helper: insert_element_every_ds
#877
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
Lattice Helper: insert_element_every_ds
#877
Conversation
insert_element_every_dsinsert_element_every_ds
015e28b to
d7ef26a
Compare
Add a helper to split a lattice every `ds` to insert another thin element, e.g., a BeamMonitor.
insert_element_every_dsinsert_element_every_ds
d7ef26a to
15354bf
Compare
|
@cemitch99 I think we could merge this one and then cut the |
| s_next_insert += ds; | ||
| } | ||
| // case 2: current element ends exactly with next insert | ||
| else if (s_next_insert == cur_s_out) { |
Check notice
Code scanning / CodeQL
Equality test on floating-point values Note
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is intentional to cover this corner case.
cemitch99
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great capability to have.
Add a helper to split a lattice every
dsto insert another thin element, e.g., a BeamMonitor.Close #537
Tasks
insert_elements(),insert(...),splice(...), ...?