Hi,
I am trying to import, from an ASCII file, an electron beam distribution, with a low kinetic energy (2.65043 keV) and a large energy spread.
once .dst file generated by Plotwin, transverse plane is ok, see attached image.
While on the longitudinal plane the distribution seems to be "distorted", see attached image . \delta coordinates seem to be ok, but not in Z?
when importing other distribution at higher energies > 100 keV, I do not have the problem anymore.
I also attach the ASCII distribution file.
Could you help me with that?
cheers
Import low energy distribution (issue on longitudinal plane)
-
- Beginner
- Posts: 5
- Joined: Tue 16 Feb 2021 13:55
- Country:
France (fr)
Import low energy distribution (issue on longitudinal plane)
- Attachments
-
- distrib.txt
- (405.99 KiB) Downloaded 1705 times
-
- XXp.png (1.47 MiB) Viewed 36442 times
-
- deltaZ.png (611.58 KiB) Viewed 36442 times
Re: Import low energy distribution (issue on longitudinal plane)
Dear Fred,
The problem here is paraxality. The particles in the DST file are defined using the phase energy and not Z-Dp/p, because that is how partran works. When you import the file, the conversion is linear without taking into account the transverse divergence of the particles and considering an average energy. This is sufficient for most beams, but not in your case. You must therefore use the second type of import defined in the PlotWin documentation where the energy and phase of the particles will be used and defined.
But whatever your choice between defining a beam via E-P or Z-Dp, the 2 phase space plots will never be satisfactory at the same time, this is the limit of the current historical codes, partan works in E-P and TraceWin in Z-Dp/p.
See chapter : "Conversions between [z-z’], [z-δ] and [Δφ-ΔW] phase planes" of TraveWin manual
Regards,
Didier
The problem here is paraxality. The particles in the DST file are defined using the phase energy and not Z-Dp/p, because that is how partran works. When you import the file, the conversion is linear without taking into account the transverse divergence of the particles and considering an average energy. This is sufficient for most beams, but not in your case. You must therefore use the second type of import defined in the PlotWin documentation where the energy and phase of the particles will be used and defined.
But whatever your choice between defining a beam via E-P or Z-Dp, the 2 phase space plots will never be satisfactory at the same time, this is the limit of the current historical codes, partan works in E-P and TraceWin in Z-Dp/p.
See chapter : "Conversions between [z-z’], [z-δ] and [Δφ-ΔW] phase planes" of TraveWin manual
Regards,
Didier
-
- Beginner
- Posts: 5
- Joined: Tue 16 Feb 2021 13:55
- Country:
France (fr)
Re: Import low energy distribution (issue on longitudinal plane)
Hello ,
Many Thanks Didier for your feedback.
I tried with the second type of import file. Indeed it remains the same for plots with Z. But Time and phase are OK.
See attached images, just FYI.
cheers,
fred
Many Thanks Didier for your feedback.
I tried with the second type of import file. Indeed it remains the same for plots with Z. But Time and phase are OK.
See attached images, just FYI.
cheers,
fred
- Attachments
-
- Ascii_type2.png (355.06 KiB) Viewed 36434 times
-
- Pwin_type2.png (431.96 KiB) Viewed 36434 times
Re: Import low energy distribution (issue on longitudinal plane)
Dear Fred,
Could you attached your second file?
I'll have a look about it.
Regards,
Didier
Could you attached your second file?
I'll have a look about it.
Regards,
Didier
Re: Import low energy distribution (issue on longitudinal plane)
Dear Fred,
Finally, I modified PlotWin code to let the user select or not the paraxlity option when the imported file is only defined via [Z-Dp/p].
Regards,
Didier
Finally, I modified PlotWin code to let the user select or not the paraxlity option when the imported file is only defined via [Z-Dp/p].
Regards,
Didier
-
- Beginner
- Posts: 5
- Joined: Tue 16 Feb 2021 13:55
- Country:
France (fr)
Re: Import low energy distribution (issue on longitudinal plane)
Dear Didier,
Thanks a lot for adding the option.
I tested it with type 1 ascii file. The "shape" in the Z-Zp plane or Z-delta is OK, but I notice a shift (about 1 mm) in the Z position as regard to the value I put in the ascii file. see attached image.
It is still confusing for me why there is this 'Shape difference' in Z-Zp and phi-W planes, compare to the first picture I sent where I compute the particles positions with the conversions formula that are used in the Tracewin help.
I also attached both type of ascii files I used.
cheers,
fred
Thanks a lot for adding the option.
I tested it with type 1 ascii file. The "shape" in the Z-Zp plane or Z-delta is OK, but I notice a shift (about 1 mm) in the Z position as regard to the value I put in the ascii file. see attached image.
It is still confusing for me why there is this 'Shape difference' in Z-Zp and phi-W planes, compare to the first picture I sent where I compute the particles positions with the conversions formula that are used in the Tracewin help.
I also attached both type of ascii files I used.
cheers,
fred
- Attachments
-
- type1_without_paraxiality_option.png (366.55 KiB) Viewed 36416 times
-
- distribType2.txt
- (2.5 MiB) Downloaded 1736 times
-
- distrib.txt
- (405.99 KiB) Downloaded 1732 times
Re: Import low energy distribution (issue on longitudinal plane)
Dear Fred,
Whatever file used I read Zo=-0.106 mm. Same result for dst files with ou with paraxality option for the first one.
For your second remark, I think we have to discuss.
Regards,
Didier
Whatever file used I read Zo=-0.106 mm. Same result for dst files with ou with paraxality option for the first one.
For your second remark, I think we have to discuss.
Regards,
Didier