Skip to content

First prototype of aperture modelling functionality#753

Open
szymonlopaciuk wants to merge 66 commits intoxsuite:mainfrom
szymonlopaciuk:aperture-model
Open

First prototype of aperture modelling functionality#753
szymonlopaciuk wants to merge 66 commits intoxsuite:mainfrom
szymonlopaciuk:aperture-model

Conversation

@szymonlopaciuk
Copy link
Collaborator

@szymonlopaciuk szymonlopaciuk commented Feb 19, 2026

Description

First prototype of the aperture modelling functionality. See examples/aperture_model/001_lhc_mqfa.py for an example usage.

Currently allows:

  • Loading an aperture model from a line with limits, a line with MAD-X metadata, or a line with associated_apertures defined on elements.
  • Calculation of the n1 using two different methods.
  • Calculation of the beam envelope at arbitrary sigmas and pipe cross sections.
  • Works in straight sections, and when profiles are not transformed w.r.t. their reference.

Currently not functional/under development:

  • Correct handling of pipes in arcs.
  • Correct interpolation (currently simply takes the nearest profile to the right).
  • GPU untested, though OpenMP supported.

This is very much work in progress but could already be used in some scenarios.

Checklist

Mandatory:

  • I have added tests to cover my changes
  • All the tests are passing, including my new ones
  • I described my changes in this PR description

Optional:

  • The code I wrote follows good style practices (see PEP 8 and PEP 20).
  • I have updated the docs in relation to my changes, if applicable
  • I have tested also GPU contexts

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