src issueshttps://gitlab.psi.ch/OPAL/src/-/issues2023-12-20T13:35:05+01:00https://gitlab.psi.ch/OPAL/src/-/issues/793OutputPlane2023-12-20T13:35:05+01:00ext-rogers_cOutputPlaneFor some precision work it is important to have accurate readout of particle positions at a particular plane. In the presence of fields, PROBE function interpolation is not accurate enough.
As registered in Issue #22 it would be useful ...For some precision work it is important to have accurate readout of particle positions at a particular plane. In the presence of fields, PROBE function interpolation is not accurate enough.
As registered in Issue #22 it would be useful to have a probe that can be perpendicular to a reference trajectory (for e.g. calculating dispersions/etc).
To meet these requirements I have implemented a new _PluginElement_ called OutputPlane. Features:
- detects hits using a RK4 stepping routine, iteratively finding correct step size to find the intersection of tracks with the plane and registering a hit at the exact point
- position can be specified in 2D using PROBE-style placement or 3D with a centre and normal vector
- position can be specified to update to be aligned with the position/momentum vector when a particle with user-defined ID crosses the plane.
- rectangular or circular apertures can be specified (maximum distance from PROBE centre to register hits)ext-rogers_cext-rogers_chttps://gitlab.psi.ch/OPAL/src/-/issues/786Unused degrader attributes2023-10-10T16:03:08+02:00ext-calvo_ppedro.calvo@ciemat.esUnused degrader attributesThe attributes of the degrader (`XSIZE` and `YSIZE`) are currently unused. A function should be added to verify that the particles are inside the element employing these attributes according to the [description](http://amas.web.psi.ch/op...The attributes of the degrader (`XSIZE` and `YSIZE`) are currently unused. A function should be added to verify that the particles are inside the element employing these attributes according to the [description](http://amas.web.psi.ch/opal/Documentation/master/#sec.elements.degrader-opal-t).2023.1ext-calvo_ppedro.calvo@ciemat.esext-calvo_ppedro.calvo@ciemat.eshttps://gitlab.psi.ch/OPAL/src/-/issues/765Momentum tolerance in Opal-t2023-10-05T17:49:18+02:00ext-calvo_ppedro.calvo@ciemat.esMomentum tolerance in Opal-tPart of #727
A new parameter `MOMENTUM_TOLERANCE` has recently been introduced to control fractional tolerance to deviations in the distribution compared to the reference data at initialisation. This parameter should be extended to be ...Part of #727
A new parameter `MOMENTUM_TOLERANCE` has recently been introduced to control fractional tolerance to deviations in the distribution compared to the reference data at initialisation. This parameter should be extended to be useful in Opal-t.2023.1ext-calvo_ppedro.calvo@ciemat.esext-calvo_ppedro.calvo@ciemat.eshttps://gitlab.psi.ch/OPAL/src/-/issues/764RingDefinition - Beam rotation and Momentum Tolerance2023-05-16T12:15:30+02:00ext-rogers_cRingDefinition - Beam rotation and Momentum Tolerance### Summary
I would like to be able to introduce an arbitrary rotation to beams in RingDefinition, independent of the azimuthal angle at which the ring is injected. At the moment, transverse "kicks" are enabled by `BEAM_PRINIT` but this...### Summary
I would like to be able to introduce an arbitrary rotation to beams in RingDefinition, independent of the azimuthal angle at which the ring is injected. At the moment, transverse "kicks" are enabled by `BEAM_PRINIT` but this does not permit full rotation through 360 degrees.
My use case:
We decided at a recent meeting that for consistency with the ring layout on the ground in the ring we are designing, the ring should start at "12 o'clock" and proceed in a clockwise direction. OPAL-Cycl mode currently supports element placements in clockwise or anticlockwise direction but beam can only proceed in an anti-clockwise direction.2023.1ext-rogers_cext-rogers_chttps://gitlab.psi.ch/OPAL/src/-/issues/758Quality of life improvements to PyOpal2023-05-05T12:02:53+02:00ext-rogers_cQuality of life improvements to PyOpalFollowing on from #745
Couple of extra "usability" features:
* It should be possible to pass multiple arguments to a "setup" function for PyOpal objects
* If an argument is passed that is not recognised, PyOpal should throw an error. A...Following on from #745
Couple of extra "usability" features:
* It should be possible to pass multiple arguments to a "setup" function for PyOpal objects
* If an argument is passed that is not recognised, PyOpal should throw an error. At the moment PyOpal quietly ignores unrecognised arguments - technically, this is consistent with "normal" python but it is not very nice
* It should be possible to define something as a required argument; if it is undefined, and user tries to use the class in anger (e.g. call to get_field_value) then PyOpal should throw an error.
* It should be possible to make PyOpal run silently (i.e. suppress output) or send output to a file. Bonus points if we can send PyOpal output to sys.stdout!
* In PyOpal/PyCore/Globals.cpp there is a hard coded constant for --processes (3). This should be user defined.2023.1ext-rogers_cext-rogers_chttps://gitlab.psi.ch/OPAL/src/-/issues/757Zero field should create a warning2023-04-12T10:58:36+02:00adelmannZero field should create a warning### Summary
In case a zero field is read in, a warning should be issued.
Such almost zero fields make sense however one field component must be non zero.
The attached example shows the zero field and the fixed zero field.
[zero-field-...### Summary
In case a zero field is read in, a warning should be issued.
Such almost zero fields make sense however one field component must be non zero.
The attached example shows the zero field and the fixed zero field.
[zero-field-example.zip](/uploads/334c29c62cd2efbaff2e81f244885022/zero-field-example.zip)2023.1adelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/749More geometries for cyclotron elements2023-01-27T17:57:31+01:00snuverink_jjochem.snuverink@psi.chMore geometries for cyclotron elementsFrom @zhang_h: It would be better if the collimators in forms other than a rectangular could also be defined in OPAL_cycl. The collimators in Ring or Injector2 or COMET could be in forms of a trapezoid, a triangle, a circle, and an ellipse.From @zhang_h: It would be better if the collimators in forms other than a rectangular could also be defined in OPAL_cycl. The collimators in Ring or Injector2 or COMET could be in forms of a trapezoid, a triangle, a circle, and an ellipse.https://gitlab.psi.ch/OPAL/src/-/issues/745PyOPAL - FFA lattice2023-04-20T16:54:05+02:00ext-rogers_cPyOPAL - FFA lattice### Summary
Implement supporting code to model our current FFA lattice in PyOPAL. That means writing API for following elements:
- ScalingFFAMagnet and EndFieldModels
- DumpEMFields
- LocalCartesianOffset (other offsets?)
- Probe
- Mult...### Summary
Implement supporting code to model our current FFA lattice in PyOPAL. That means writing API for following elements:
- ScalingFFAMagnet and EndFieldModels
- DumpEMFields
- LocalCartesianOffset (other offsets?)
- Probe
- MultipoleT
- VariableRFCavity and TimeDependence plugin
- General consideration of stability/etc
Maybe some other things I forgot.
Also (of course)
- Code
- Test
I will do Documentation in a separate feature when I am more happy with the whole framework.2023.1ext-rogers_cext-rogers_chttps://gitlab.psi.ch/OPAL/src/-/issues/716Remove usage of IPPL:Tenzor class2023-08-23T16:29:38+02:00adelmannRemove usage of IPPL:Tenzor class### Summary
Remove IPPL `AppTypes/Tenzor.h` usage in
- Classic/AbsBeamline/Bend2D.cpp
- Classic/Algorithms/Quaternion.h:class
- Classic/Algorithms/CoordinateSystemTrafo.h
- Classic/Algorithms/Quaternion.cpp
- Classic/Utilities/MSLang.h
...### Summary
Remove IPPL `AppTypes/Tenzor.h` usage in
- Classic/AbsBeamline/Bend2D.cpp
- Classic/Algorithms/Quaternion.h:class
- Classic/Algorithms/CoordinateSystemTrafo.h
- Classic/Algorithms/Quaternion.cpp
- Classic/Utilities/MSLang.h
- Algorithms/ParallelCyclotronTracker.cpp
- Distribution/Distribution.cpp
- Distribution/Distribution.h
`Tenzor` is mostly used as matrix and in the `Classic/Algorithms/Quaternion.cpp`.
Maybe replacing `Quaternion` by Boost could also be an option.2023.1sadr_msadr_mhttps://gitlab.psi.ch/OPAL/src/-/issues/705Enabling 3DDynamics to accept complex field2022-01-26T20:26:07+01:00ext-piot_pEnabling 3DDynamics to accept complex field### Summary
Right now OPAL only allows for 3D map to be real-values. For a project at AWA we need the map to be complex values. I would like to implement by introducing a 3DDynamicsComplex flat in the external map describing the field w...### Summary
Right now OPAL only allows for 3D map to be real-values. For a project at AWA we need the map to be complex values. I would like to implement by introducing a 3DDynamicsComplex flat in the external map describing the field with columns being Re(Ex), Re(Ey) Re(Ez), Im(Ex), Im(Ey) Im(Ez), Re(Hx), Re(Hy) Re(Hz), Im(Hx), Im(Hy) Im(Hz) . I will try to implement this in the next few days -- this is related to the question from one of my colleagues (Seong-Yeol). Any better suggestion?ext-piot_pext-piot_phttps://gitlab.psi.ch/OPAL/src/-/issues/688Make element MultipoleT useable from Opal-t2021-10-24T18:12:24+02:00krausMake element MultipoleT useable from Opal-tMultipoleT currently only supports Opal-cycl even though in the documentation it was stated that its only supports Opal-t (corrected 21.10.2021). Multipoles with fringe fields are also useful for Opal-t.MultipoleT currently only supports Opal-cycl even though in the documentation it was stated that its only supports Opal-t (corrected 21.10.2021). Multipoles with fringe fields are also useful for Opal-t.https://gitlab.psi.ch/OPAL/src/-/issues/686Use a library that provides dimensional analysis and unit/quantity manipulation.2023-07-24T11:02:38+02:00krausUse a library that provides dimensional analysis and unit/quantity manipulation.Once we switch to c++20 then we should use [this library](https://github.com/mpusz/units) to make unit convertions safe. Ideally we also provide units for the parser such that the user can provide quantities in different units than meter...Once we switch to c++20 then we should use [this library](https://github.com/mpusz/units) to make unit convertions safe. Ideally we also provide units for the parser such that the user can provide quantities in different units than meter, seconds etc.
See also [here](https://mpusz.github.io/units/introduction.html) and [here](https://www.youtube.com/watch?v=7dExYGSOJzo).https://gitlab.psi.ch/OPAL/src/-/issues/616Enable H5 files as input for FROMFILE distributions2021-06-10T17:35:43+02:00krausEnable H5 files as input for FROMFILE distributionsIf one wants to use the distribution from a "temporal" monitor or from the regular phase space dump then one has to export the phase space of the HDF5 file to Ascii. Instead we should allow to use the HDF5 directly.If one wants to use the distribution from a "temporal" monitor or from the regular phase space dump then one has to export the phase space of the HDF5 file to Ascii. Instead we should allow to use the HDF5 directly.https://gitlab.psi.ch/OPAL/src/-/issues/606Container support2021-06-10T17:42:42+02:00bellotti_rContainer supportI suggest to provide container images for OPAL. It is quite complicated to build it, and requires running specific scripts in a specific order. On the other hand, pulling (or building) an image is just one command. The system agnostic ap...I suggest to provide container images for OPAL. It is quite complicated to build it, and requires running specific scripts in a specific order. On the other hand, pulling (or building) an image is just one command. The system agnostic approach circumvents problems when clusters provide different versions of the dependencies, or change them.https://gitlab.psi.ch/OPAL/src/-/issues/562General elements for electrostatitic and magnetostatic fields2021-06-10T17:47:02+02:00krausGeneral elements for electrostatitic and magnetostatic fields### Summary
Currently not every element can be modeled with a specific element in Opal. Instead one has to use 3D field maps and either a solenoid (only for magneto static fields) or an rf cavity. This isn't very intuitive. Instead we c...### Summary
Currently not every element can be modeled with a specific element in Opal. Instead one has to use 3D field maps and either a solenoid (only for magneto static fields) or an rf cavity. This isn't very intuitive. Instead we could provide "blank" elements for the general case, e.g. GENERALELECTROSTATIC and GENERALMAGNETOSTATIC.https://gitlab.psi.ch/OPAL/src/-/issues/457Dipoles in Opal-T to support quadrupole component field gradients2021-12-27T11:30:52+01:00snuverink_jjochem.snuverink@psi.chDipoles in Opal-T to support quadrupole component field gradientsThe following discussion from !269 should be addressed:
- @snuverink_j started a [discussion](https://gitlab.psi.ch/OPAL/src/merge_requests/269#note_16644): (+3 comments)
> The commenting out was introduced by @kraus in 595b4b83 ....The following discussion from !269 should be addressed:
- @snuverink_j started a [discussion](https://gitlab.psi.ch/OPAL/src/merge_requests/269#note_16644): (+3 comments)
> The commenting out was introduced by @kraus in 595b4b83 .. perhaps he can comment. Note that the class at that time was called `Bend` : https://gitlab.psi.ch/OPAL/src/blob/595b4b83818596b5f7a72e086cbbda4325f70aa8/src/Classic/AbsBeamline/Bend.cpp
- @kraus The dipoles in Opal-T used to support field gradients in version 1.6 and before. When I rewrote Opal-T I disabled it to speed up the development. However it was my intention to re-enable it (but didn't happen). I still think that we should support the quadruple component.https://gitlab.psi.ch/OPAL/src/-/issues/402VFFA2019-12-13T15:41:37+01:00ext-rogers_cVFFAImplement analytical Vertical FFA field map in OPAL with fields as per draft note:
[vertical-ffa-note.pdf](/uploads/1010e8589a932e447794df7ea11d0fb0/vertical-ffa-note.pdf)Implement analytical Vertical FFA field map in OPAL with fields as per draft note:
[vertical-ffa-note.pdf](/uploads/1010e8589a932e447794df7ea11d0fb0/vertical-ffa-note.pdf)OPAL-2.2.0ext-rogers_cext-rogers_chttps://gitlab.psi.ch/OPAL/src/-/issues/379Add phase-space halo parameter to stat and smb file2020-04-22T11:53:50+02:00frey_mAdd phase-space halo parameter to stat and smb fileWe currently write the spatial-profile parameter to the stat file. However, I think, it makes sense to write also the phase-space halo parameter to the file. The formulas are in https://journals.aps.org/prab/abstract/10.1103/PhysRevSTAB....We currently write the spatial-profile parameter to the stat file. However, I think, it makes sense to write also the phase-space halo parameter to the file. The formulas are in https://journals.aps.org/prab/abstract/10.1103/PhysRevSTAB.5.124202frey_mfrey_mhttps://gitlab.psi.ch/OPAL/src/-/issues/376Feature Request: OPAL Cheat Sheet2020-06-10T08:29:27+02:00bellotti_rFeature Request: OPAL Cheat SheetI think a cheat sheet would be very helpful for people who are new to OPAL. Especially to get an overview about what is possible, and which commands exist without having to go through the wiki section by section. Of course, detailed info...I think a cheat sheet would be very helpful for people who are new to OPAL. Especially to get an overview about what is possible, and which commands exist without having to go through the wiki section by section. Of course, detailed information should still be looked up.
My suggestion is to give a short config snippet for the most common building blocks. [This PDF](https://pandas.pydata.org/Pandas_Cheat_Sheet.pdf) might be a good guideline what I mean.
What do you think?adelmannadelmannhttps://gitlab.psi.ch/OPAL/src/-/issues/359CCollimator not properly implemented for horizontal cut2021-06-10T17:53:04+02:00frey_mCCollimator not properly implemented for horizontal cutAs far as I understand, the CCollimator checks the [vertical direction](https://gitlab.psi.ch/OPAL/src/blob/master/src/Classic/AbsBeamline/CCollimator.cpp#L60) in order to find out if the bunch is close to the collimator. However, this o...As far as I understand, the CCollimator checks the [vertical direction](https://gitlab.psi.ch/OPAL/src/blob/master/src/Classic/AbsBeamline/CCollimator.cpp#L60) in order to find out if the bunch is close to the collimator. However, this only works for vertical collimators (consisting of 2 CCollimator elements, i.e. upper and lower plate). In case of horizontal collimators this does not apply.frey_msnuverink_jjochem.snuverink@psi.chfrey_m