Applying Wakes to Energy Compressor

Moderators: cyao, michael_borland

Post Reply
Evan_Ericson
Posts: 6
Joined: 01 Oct 2019, 09:34

Applying Wakes to Energy Compressor

Post by Evan_Ericson » 20 Aug 2020, 12:31

Hello,

This is my first time using elegant. I am attempting to model an energy compression system consisting of a magnetic chicane and a linear accelerator. I am using the TWLA element to model the accelerator followed by WAKE, TRWAKE elements to model the wakes of the TWLA. I have simulated my structure using shorter and shorter bunches and have found the structure's longitudinal and transverse wake functions are reasonably approximated by Bane's analytic equations:

Screen Shot 2020-08-20 at 11.14.04 AM.png

where a, s_1, s_2 are based on the geometry of the structure.

1) For my accelerator geometry, the Bane's approximation equations are valid up to z=5mm (1.67e-11 sec) behind the charge that excites the wake. The bunch entering the accelerator is 17mm (5.67e-11 sec) long. Should I make my wake function input file zero for all times greater than t=1.67e-11 sec? If I don't set the wake function to zero after t=1.67e-11 sec, does Elegant apply an energy change to the tail of the beam that it should not (is not physical)? Does this upper limit of the approximation not matter if my simulated wakepotentials for short bunches follows the approximation further out than the upper limit of the analytic function?

2) The TRWAKE element include options to scale the transverse wake functions by the the beta functions of the accelerator. Will I need to compute the beta functions near my accelerating structure and use those values for xfactor, yfactor or is that only for special cases?

Thank you,

Evan

michael_borland
Posts: 1927
Joined: 19 May 2008, 09:33
Location: Argonne National Laboratory
Contact:

Re: Applying Wakes to Energy Compressor

Post by michael_borland » 07 Sep 2020, 11:54

Evan,

To get the best results, you should find a way to extend the wake potential beyond 16.7 ps. Usually there are different approximations for short and long times, which can be joined into a single wake. Barring that, if the wake potential has at least dropped down to very small values by 16.7 ps but you still have particles beyond that, I suggest extended with zeros.

You only need to use the factor parameters on TRWAKE if (1) you are placing the TRWAKE elements in the actual location of the impedance. (2) lumping together many impedances into a single location, where the object locations have "significantly" different beta functions. Usually in linac modeling people ignore this subtlety as it tends to average out. If the impedance in question is distributed along the linac, you can split the linac into sections, so the weighting happens automatically. Otherwise, if you want to be really precise, set the factor parameter to (AverageOfBeta)/(BetaAtTRWAKE).

--Michael

Evan_Ericson
Posts: 6
Joined: 01 Oct 2019, 09:34

Re: Applying Wakes to Energy Compressor

Post by Evan_Ericson » 10 Sep 2020, 12:16

Hello,

Thank you for your reply. I've computed the wakefunction for my 16-cell structure. They match the equations previously posted which are for a set of periodic cells. In the paper where the approximations are derived a distinction is made between the wakefunction of a single cell and an array of cells. The wakefunctions of a periodic structure is not just the wakefuction of a single cell multiplied by the number of cells in the structure.

Using the WAKE element and its default factor, I do not see any wake effect on the longitudinal phase space. Only when I put FACTOR=16 do I see an effect. Does using a factor of 16 effectively model a structure of 16*16 cells (not what I want)? Why is there no visible effect when FACTOR=1?

Looking at the LCLS example, I see a factor of ~86 was used however I cannot be sure whether their input wake was for a single cell or for a structure of ~80 cells.

This is the element in Elegant:
LONGWAKE:WAKE,INPUTFILE="baneLongWake.sdds",TCOLUMN="t",WCOLUMN="w",N_BINS=0,FACTOR="16 1 *"

Thanks,

Evan

michael_borland
Posts: 1927
Joined: 19 May 2008, 09:33
Location: Argonne National Laboratory
Contact:

Re: Applying Wakes to Energy Compressor

Post by michael_borland » 10 Sep 2020, 15:04

Evan,

It shouldn't be necessary to set FACTOR to 16 to get an effect. It will just multiply the effect by 16. Similar, with FACTOR=1, you'll just get the effect of the given wake without any additional scaling.

If you post your input files, I'll take a look.

--Michael

Evan_Ericson
Posts: 6
Joined: 01 Oct 2019, 09:34

Re: Applying Wakes to Energy Compressor

Post by Evan_Ericson » 11 Sep 2020, 15:37

Hello,

I have attached the input, lattice and wake files.

I appreciate your help,

Evan
Attachments
clsEcs.zip
(9.03 KiB) Downloaded 303 times

michael_borland
Posts: 1927
Joined: 19 May 2008, 09:33
Location: Argonne National Laboratory
Contact:

Re: Applying Wakes to Energy Compressor

Post by michael_borland » 14 Sep 2020, 21:40

Evan,

The lattice file you sent didn't seem to use the WAKE element. However, it was easy enough to set up a simple beamline that consisted of just a CHARGE element and a WAKE element that uses the wake file you provided.

I find that as I vary the FACTOR parameter, the final momentum deviation varies linearly, as I would expect. The effect on the phase space is subtle for FACTOR=1 and obvious for FACTOR=16, but a factor of 16 will do that. Unless I'm missing something, the results seem fine.
factorEffect.png
factorEffect.png (8.6 KiB) Viewed 9474 times
factor1Comp.png
factor16Comp.png
--Michael
Attachments
example.zip
(6.68 KiB) Downloaded 296 times

Evan_Ericson
Posts: 6
Joined: 01 Oct 2019, 09:34

Re: Applying Wakes to Energy Compressor

Post by Evan_Ericson » 17 Sep 2020, 11:48

I deleted the Wake element while doing some testing and forgot to include it again before attaching the files. In any case, your response helps. I was expecting a larger effect.

Thanks for looking into my issue.

Evan

Post Reply