Page 1 of 1

Fractional momentum spread sigma_dp

Posted: 20 Apr 2023, 11:08
by Repetto
Hello,
I am simulating a bunched beam with sigma_dp = 0.001, but respect to my data it's not the same.
In fact, I would like to have an asymmetric sigma_dp (an asymmetry on the left side of my gaussian simulation) to have a better agreement with my data.
Is it possible? If yes, how can I modify my elegant file?
Thank you in advance,
Silvia

Re: Fractional momentum spread sigma_dp

Posted: 02 Jun 2023, 09:48
by michael_borland
Silvia,

You can use the program sddssampledist to generate an arbitrary momentum distribution outside of elegant, then load the particles via the sdds_beam command.

Let's assume that your beam is gaussian in (x, xp, y, yp, t), but has a different distribution in momentum. The procedure to generate this beam would be
  1. Run elegant to make a nominal distribution of particles.
  2. Throw out the unwanted p coordinates.
  3. Generate new p coordinates by sampling a desired distribution (sddssampledist).
  4. Merge with other coordinates.
The attached archive has a concrete example.

--Michael

Re: Fractional momentum spread sigma_dp

Posted: 02 Jun 2023, 09:50
by michael_borland
Silvia,

There are also several examples in the the elegant examples file, under customBeamDistributions.

--Michael