Dear Didier,
I want to import data from an ASCII file written as described in the manual as follows :
Number_of_particle Mass(MeV) Beam_energy(MeV) Beam_Frequency(MHz) Beam_courant(A)
X0(m) Xp0(rad) Y0(m) Yp0(rad) Z0(m) Δp0/ps
X1(m) Xp1(rad) Y1(m) Yp1(rad) Z1(m) Δp1/ps
…
Tehn I built a file this way :
10000 938.272 0.095 352.21 0.053074
0.00137746 -0.0482642 0.00052219 0.0109325 0.00428458 10.0623
0.00154513 -0.0249219 0.00135488 0.012837 0.0042817 10.0623
...
So the energy should then be 0.095 KeV, but when I import the file in PlotWin, the energy is 0, and then in TraceWin the energy is 2 MeV, all others parameters being equal to what's in the ASCII file.
I attached the ASCII file.
Emmanuel
Issue on energy value while importing ASCII file
Issue on energy value while importing ASCII file
- Attachments
-
- Beam_dist_in_out_0_TW.txt
- (715.84 KiB) Downloaded 1322 times
Re: Issue on energy value while importing ASCII file
To give you all the details, I had an original file that should fit directly in PlotWin format as being in the form of PlotWin output format:
Nbr_particle Mo(MeV) Eo(MeV) Freq(MHz) Courant(mA) Charge
10000 938.272 0.095 352.21 53.074 1
Exx'(mm.mrad) Eyy'(mm.mrad) Alpxx' Alpyy' Betxx'(mm/mrad) Betyy'(mm.mrad)
0.101547 0.0274281 1.76623 -0.357879 0.151003 0.573096
Xc(mm) Yc(mm) X'c(mrad) Y'c(mrad)
0.0365736 1.37096 -16.3013 10.9045
x(mm) x'(mrad) y(mm) y'(mrad) Phase(deg) Energy(MeV) Cell_Loss
+1.37746 -48.26422 +0.52219 +10.93247 -180.09179 +0.09500 0
+1.54513 -24.92185 +1.35488 +12.83696 -179.97088 +0.09500 0
...
But it didn't work either.
I attach this second file.
Emmanuel
Nbr_particle Mo(MeV) Eo(MeV) Freq(MHz) Courant(mA) Charge
10000 938.272 0.095 352.21 53.074 1
Exx'(mm.mrad) Eyy'(mm.mrad) Alpxx' Alpyy' Betxx'(mm/mrad) Betyy'(mm.mrad)
0.101547 0.0274281 1.76623 -0.357879 0.151003 0.573096
Xc(mm) Yc(mm) X'c(mrad) Y'c(mrad)
0.0365736 1.37096 -16.3013 10.9045
x(mm) x'(mrad) y(mm) y'(mrad) Phase(deg) Energy(MeV) Cell_Loss
+1.37746 -48.26422 +0.52219 +10.93247 -180.09179 +0.09500 0
+1.54513 -24.92185 +1.35488 +12.83696 -179.97088 +0.09500 0
...
But it didn't work either.
I attach this second file.
Emmanuel
- Attachments
-
- Beam_dist_in_out_0-m.txt
- (1.13 MiB) Downloaded 878 times
Re: Issue on energy value while importing ASCII file
Dear Emmanuel,
In your first file, I just replaced Δp/p0 with ‘0’ to solve the problem (see attached file)
[/attachment]
As far as your second file is concerned, everything is wrong, both the header and the list of particles, so I don't really know how to correct it. Nothing seems to correspond to what is described in the PlotWin manual !
Regards,
Didier
In your first file, I just replaced Δp/p0 with ‘0’ to solve the problem (see attached file)
[/attachment]
As far as your second file is concerned, everything is wrong, both the header and the list of particles, so I don't really know how to correct it. Nothing seems to correspond to what is described in the PlotWin manual !
Regards,
Didier
- Attachments
-
- Beam_dist_in_out_0_TW.txt
- (676.77 KiB) Downloaded 1229 times