modulate_elements

Moderators: cyao, michael_borland

fliller
Posts: 38
Joined: 06 Aug 2008, 14:02

Re: modulate_elements

Post by fliller » 06 Feb 2013, 14:57

Here you go!
Attachments
ForMike.zip
Hack version
(5.04 KiB) Downloaded 243 times

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

Re: modulate_elements

Post by michael_borland » 06 Feb 2013, 15:10

Thanks!

fliller
Posts: 38
Joined: 06 Aug 2008, 14:02

Re: modulate_elements

Post by fliller » 15 Feb 2013, 14:41

Michael,

I _may_ have found another bug in Modulate_elements. Attached is a demo which saws the possible bug. It is similar to the previous example except that now I turn on the RF system. When I turn on the RF, there are two things I see:
1) for modulate elements, I need to have negative times in my file which specifies the element values, othwerwise I get an error that the interpolation fails when it encounters a particle with negative times.
2) the phase space behaviour is _VERY_ different with the RF on. Some of this is expected, synchrotron oscillations etc, but the islands I get with no RF completely disappear. If I start the scan at settings which generate the islands, they appear, but if I try to move the islands with the scan, they do not move.

I believe this may be an error in the code, but I am not whole heartedly convinced, but it smells like a duck, and walks like a duck.

Ray
Attachments
ForMike.zip
(4.62 KiB) Downloaded 219 times

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

Re: modulate_elements

Post by michael_borland » 15 Feb 2013, 15:40

Ray,

I'm a bit swamped right now. One suggestion is to try the MODRF element, which allow imposing various modulations in an rf cavity. Also, RAMPRF allows specifying time-dependent waveforms for phase and amplitude.

--Michael

fliller
Posts: 38
Joined: 06 Aug 2008, 14:02

Re: modulate_elements

Post by fliller » 15 Feb 2013, 15:53

Michael,

The modulation is not on the RF, it is still on the quadrupoles. I am just adding in the RF to the dynamics.

Ray

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

Re: modulate_elements

Post by michael_borland » 15 Feb 2013, 15:55

Ray,

Ok, I'll try to have a look in the next few days. One thing you might check is whether it is the same with QUAD and KQUAD elements. It should be very similar.

--Michael

fliller
Posts: 38
Joined: 06 Aug 2008, 14:02

Re: modulate_elements

Post by fliller » 15 Feb 2013, 16:46

Michael,

It is pratically unchanged.

Ray

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

Re: modulate_elements

Post by michael_borland » 15 Feb 2013, 17:36

Ray,

Try setting change_t=0 on the RFCA. Otherwise, you are reseting the average particle coordinates to <t>=0, which is going to mess up the calculation of the modulation amplitude.

--Michael

fliller
Posts: 38
Joined: 06 Aug 2008, 14:02

Re: modulate_elements

Post by fliller » 19 Feb 2013, 07:55

Michael,

BINGO, worked like a charm. Thanks for your help.

Ray

Post Reply