Add time-dependent beamline element properties with turn-by-turn multipolar components
The goal is to develop the possibility to declare and define time-dependent beamline element properties in the input gmad
file.
For example, if defining a quadrupole, the strength could be made time-dependent by setting it to a data file. The data file would contain at least two columns: one for the turn number and one for the property which should be varied (in case of multipolar components for a multipole, like knl
or ksl
, multiple columns would be defined).
Comments (3)
-
-
reporter Quick comment about functions: for my use cases I also need to be able to specify explicit values on a turn-by-turn basis (no analytical or semi-analytical form for the function, but rather discrete points).
-
In the “rfkicker-syncbrho” branch (which will soon merge into “rfkicker” branch and then soon into “develop”), I’ve introduced the concept of a field modulator that modifies the strength. Just now this is limited to being used for field maps but it lays the ground work for having time or turn or event varying field strengths.
- Log in to comment
Excellent! Yes, we had thought about this sometime in the past a little but never made any moves. We had also thought about strengths varying with a variety of parameters:
The function could also be a variety of things:
Interpretation of a user-specified function may also be useful for example in our laser developments for Geant4 / BDSIM where we could specify our own functions for intensity vs time etc.
One thought in the past was to wrap BDSMagnetStrength with another class to allow the scaling. But perhaps it would ultimately be that we have to construction some functor / function class that would be used in place of any individual strength parameter in each integrator or field class. Note we must also scale the associated B field functions as well as the accelerator-specific integrators so that when we ‘fall-back’ to a regular G4ClassicalRK4 we have the correct field strength. Just a few quick thoughts.
I guess applications would be fast losses in the LHC for you? Various failure scenarios? Also, I had thought about rapid cycling synchrotrons.