ELFIN Sample Input files

Takeshi Nakamura

SPring-8

Kamigori-cho, Ako-gun, Hyogo 678-12 JAPAN nakamura@spring8.or.jp

January 12, 1999

1 High Gain Long Undulator

Below is the input file for the case B in Table 1 in ”OPTICAL GUIDING SIMULATIONS FOR HIGH GAIN-SHORT WAVE LENGTH FELs,” J.E. LaSALA, D.A.G. DEACON and E.T. SCHARLEMANN, Nucl. Instr. and Meth. A250(1986)389.

===ELFIN input data==========================================================
Num_of_Grid  Num_of_Particle
128            16000
===== Number_of_Repetition ==================================================
ELFIN repeats the section between BEGIN...END in Configulation defined below
  1
-----Configuration of System ------------------------------------------------
 (elemant names are within 6 characters)
'AINI ESRC FEL TERM'
==== Element Parameter ekind=[FEL,ESOURC,AINIT,MIRROR,AFREE,OUTPUT,TERM]=====
Name       Kind_of_Element
'FEL'      'FEL'
-----------------------------------------------------------------------------
Width_of_Calcuraion_Area(SquareArea)
3.200000e-03
-----------------------------------------------------------------------------
Num_of_Sampling_Points  Num_of_Step_along_Z
18                      36
-----------WIGGLER PARAMETERS------------------------------------------------
Length  aw0(r.m.s.) Period    hx           hy     Kind<wgkind>[OPTIC,STATIC]
27.0000 (4.0600,0)  0.1140 (55.1157,0) (55.1157,0)       'STATIC'
-----------------------------------------------------------------------------
wignum wigpar(1) wigpar(2) wigpar(3) wigpar(4)(reserved parameter for wig.)
1      0.        0.        0.        0.
-----------SPATIAL FILTERING (width and # of spline on it )------------------
Filter_Width(If you don't want, this >> width )  Num_of_Splining
3.200000e-03                                        1
---OUTPUT CONTROL PARAMETERS ------------------------------------------------
Laser_Histgram(x y)   _Print(x y)  Particle_Histgram(x y)  _Print(x y)
1    1                 1      1        1    1                1     1
=============================================================================
Name       Kind_of_Element
'ESRC'     'ESOURC'
-----------------------------------------------------------------------------
Peak_Current(A)
2.7000e+02
-----------------------------------------------------------------------------
Gamma        Gamma_Spread(r.m.s. for Gaussian)
2.0000e+03       1.1578e+00
-----------------------------------------------------------------------------
Longitudinal_Distrbution_Type(Gaussian=0)
0.0
-----------------------------------------------------------------------------
X             X_Spread      Beta_X    Beta_X_Spread  Distance_To_Waist
0.0000e+00   2.7600e-04   0.0000e+00    3.0800e-05     0.0000
---Same parameters as x direction above--------------------------------------
Y             Y_Spread      Beta_Y    Beta_Y_Spread  Distance_To_Waist
0.0000e+00   2.7600e-04   0.0000e+00    3.0800e-05     0.0000
-----------------------------------------------------------------------------

4-Dimemsional_Dstribution_Type(x,bx,y,by)(Gaussian=0)
0.0
-----------------------------------------------------------------------------
Num_of_Longitudinal_Points
4
--- seed for random number generator ----------------------------------------
Random_Seed Update_Seed_or_not_for_each_time_This_module_called
5                  0
--- ignore this -------------------------------------------------------------
redfct
0.0
=============================================================================
Name      Kind_of_Element
'AINI'    'AINIT'
-----------------------------------------------------------------------------
 Width
3.200000e-03
-----------------------------------------------------------------------------
Laser_Wave_Length   Input_Power   Waist_Size(1/e)      Distance_To_Waist
2.5000e-07          1.0000e+01     6.0000e-04                4.5000
=============================================================================
Name       Kind_of_Element
'DEBUG'    'DEBUG'
=============================================================================
Name       Kind_of_Element
'TERM'     'TERM'
=============================================================================

2) Oscillator Following is an input file for oscillator configulation with a cavity. This is for the case of Table 1 in ”THREE-DIMENSIONAL SIMULATIONS OF FREE ELECTRON LASER PHYSICS,” B. D. McVey, Nucl. Instr. and Meth. A250(1986)449.

===ELFIN input data==========================================================
Num_of_Grid  Num_of_Particle
128            16000
===== Number_of_Repetition ==================================================
ELFIN repeats the section between BEGIN...END in Configulation defined below
3
-----Configuration of System ------------------------------------------------
 (elemant names are within 6 characters)
'AINI
  BEGIN ESRC FEL AF1 OUT MRF AF2  AFH OUT AFH AF3 OUT MRB AF4  END
  TERM        '
==== Element Parameter ekind=[FEL,ESOURC,AINIT,MIRROR,AFREE,OUTPUT,TERM]=====
Name       Kind_of_Element
'FEL'      'FEL'
-----------------------------------------------------------------------------
Width_of_Calcuraion_Area(SquareArea)
1.280000e-02
-----------------------------------------------------------------------------
Num_of_Sampling_Points  Num_of_Step_along_Z
9                       36
-----------WIGGLER PARAMETERS------------------------------------------------
Length   aw0(r.m.s.)   Period    hx        hy      Kind<wgkind>[OPTIC,STATIC]
1.0 (5.4089850e-01,0) 2.73e-02  (0,0)  (2.30153e+02,0)  'STATIC'

-----------------------------------------------------------------------------
wignum wigpar(1) wigpar(2) wigpar(3) wigpar(4)(reserved parameter for wig.)
1      0.        0.        0.        0.
-----------SPATIAL FILTERING (width and # of spline on it )------------------
Filter_Width(If you don't want, this >> width )  Num_of_Splining
1.280000e-02                                          1
---OUTPUT CONTROL PARAMETERS ------------------------------------------------
Laser_Histgram(x y)   _Print(x y)  Particle_Histgram(x y)  _Print(x y)
1    1                 1      1        1    1                1     1
=============================================================================
Name       Kind_of_Element
'ESRC'     'ESOURC'
-----------------------------------------------------------------------------
Peak_Current(A)
1.00000e+02
-----------------------------------------------------------------------------
Gamma        Gamma_Spread(r.m.s. for Gaussian)
42.6869             2.134345e-1
-----------------------------------------------------------------------------
Longitudinal_Distrbution_Type(Uniform=-2)
-2
-----------------------------------------------------------------------------
X             X_Spread      Beta_x    Beta_x_Spread  Distance_To_Waist
0.00000e+00  5.67785e-04  0.00000e+00  1.68190e-03  5.00000e-01
---Same parameters as x direction above--------------------------------------
Y             Y_Spread      Beta_Y    Beta_Y_Spread  Distance_To_Waist
0.00000e+00  5.67785e-04  0.00000e+00  1.68190e-03  5.00000e-01
-----------------------------------------------------------------------------
4-Dimemsional_Dstribution_Type(x,bx,y,by)(Gaussian=0)
0.0
-----------------------------------------------------------------------------
Num_of_Longitudinal_Points
16
--- seed for random number generator ----------------------------------------
Random_Seed Update_Seed_or_not_for_each_time_This_module_called
5                  0
--- ignore this -------------------------------------------------------------
redfct
0.0
======== Initial Laser Field =================================================
Name       Kind_of_Element
'AINI'     'AINIT'
-----------------------------------------------------------------------------
Width
1.280000e-02
-----------------------------------------------------------------------------
Laser_Wave_Length   Input_Power   Waist_Size(1/e)      Distance_To_Waist
1.00000e-05        1.00000e+01    1.41835e-03            5.00000e-01
=============================================================================
Name      Kind_of_Element
'OUT'     'OUTPUT'
---OUTPUT CONTROL PARAMETERS ------------------------------------------------
Laser_Histgram(x y)   _Print(x y)  Particle_Histgram(x y)  _Print(x y)
1   0                  1    0          1    0                1    0

=============================================================================
Name       Kind_of_Element
'MRF'      'MIRROR'
-Width_of_Calcuration Area --------------------------------------------------
 Width
5.120000e-02
-Curvature---Diameter-Refrectance--Tilts------Shifts-------Num_of_Spline-----
                                  x     y     x     y
3.350000e+00   1.0      0.80     0.0   0.0   0.0   0.0         2
=============================================================================
Name       Kind_of_Element
'MRB'      'MIRROR'
-----------------------------------------------------------------------------
 Width
5.120000e-02
-Curvature---Diameter-Refrectance--Tilts------Shifts-------Num_of_Spline-----
                                  x     y     x     y
3.800000e+00  1.0        1.0      0.0  0.0    0.0  0.0         2
======= Free Space for Laser ================================================
Name       Kind_of_Element
'AF1'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
1.280000e-02       5.120000e-02
-----------------------------------------------------------------------------
Length
2.726193e+00
=============================================================================
Name       Kind_of_Element
'AF2'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
5.120000e-02  1.280000e-02
-----------------------------------------------------------------------------
Length
2.726193e+00
=============================================================================
Name        Kind_of_Element
'AF3'       'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
1.280000e-02  5.120000e-02
-----------------------------------------------------------------------------
Length
3.191807e+00
=============================================================================
Name       Kind_of_Element
'AF4'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
5.120000e-02  1.280000e-02
-----------------------------------------------------------------------------
Length
3.191807e+00

=============================================================================
Name       Kind_of_Element
'AFH'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
1.280000e-02  1.280000e-02
-----------------------------------------------------------------------------
Length
5.000000e-01
=============================================================================
Name     Kind_of_Element
'DEBUG'  'DEBUG'
=============================================================================
Name     Kind_of_Element
'TERM'   'TERM'
=============================================================================

3) Variable Name in ELFIN and Input File Following input file shows that the relation of the variable name used in ELFIN and input data for the case 2).

===ELFIN input data==========================================================
Num_of_Grid  Num_of_Particle
<na>           <np>
===== Number_of_Repetition ==================================================
ELFIN repeats the section between BEGIN...END in Configulation defined below
<nrep>
-----Configuration of System ------------------------------------------------
 (elemant names are within 6 characters)<cfname,ncf>
<cfname>
===== FEL device: CALL rnfel in fel.f =======================================
Name<ename>       Kind_of_Element<ekind>   CALL rnfel in fel.f
'FEL'      'FEL'
-----------------------------------------------------------------------------
Width_of_Calcuraion_Area(SquareArea)<width>
<width>
-----------------------------------------------------------------------------
Num_of_Sampling_Points  Num_of_Step_along_Z
<nsp>                    <nz>
-----------WIGGLER PARAMETERS------------------------------------------------
Length   aw0(r.m.s.)   Period    hx        hy      Kind<wgkind>[OPTIC,STATIC]
<lw>      <aw0>        <lw>      <hx>     <hy>         <wigkind>
-----------------------------------------------------------------------------
wignum wigpar(1) wigpar(2) wigpar(3) wigpar(4)(reserved parameter for wig.)
<wignum>  <wigpar(1)>  <wigpar(2)>  <wigpar(3)>  <wigpar(4)>
-----------SPATIAL FILTERING (width and # of spline on it )------------------
Filter_Width(If you don't want, this >> width )  Num_of_Splining
<fltwid>                                           <nspln>
---OUTPUT CONTROL PARAMETERS ------------------------------------------------
Laser_Histgram(x y)   _Print(x y)       Particle_Histgram(x y)  _Print
<ahswx> <ahswy>     <ameswx> <ameswy>    <phswx>   <phswy>      <parsw>
== Electron Source : CALL rnesrc in esrc.f ==================================
Name       Kind_of_Element
'ESRC'     'ESOURC'
-----------------------------------------------------------------------------
Peak_Current(A)

<curr>
-----------------------------------------------------------------------------
Gamma        Gamma_Spread(r.m.s. for Gaussian)
<gm0>        <gmspd0>
-----------------------------------------------------------------------------
Longitudinal_Distrbution_Type
<gmdst>
-----------------------------------------------------------------------------
X             X_Spread      Beta_x    Beta_x_Spread  Distance_To_Waist
<xp0>         <xpspd0>      <bx0>     <bxspd0>       <lx>
---Same parameters as x direction above--------------------------------------
Y             Y_Spread      Beta_Y    Beta_Y_Spread  Distance_To_Waist
<yp0>         <ypspd0>      <by0>     <byspd0>       <ly>
-----------------------------------------------------------------------------
4-Dimemsional_Dstribution_Type(x,bx,y,by)
<trsdst>
-----------------------------------------------------------------------------
Num_of_Longitudinal_Points
<nl>
--- seed for random number generator ----------------------------------------
Random_Seed Update_Seed_or_not_for_each_time_This_module_called
<parnr0>     <nrupdt>
--- ignore this -------------------------------------------------------------
sptfct
<sptfct>
== Initial Laser Field: CALL rnaini in aini.f ===============================
Name       Kind_of_Element
AINI       'AINIT'
-----------------------------------------------------------------------------
Width
<width>
-----------------------------------------------------------------------------
Laser_Wave_Length   Input_Power   Waist_Size(1/e)      Distance_To_Waist
<ll>                <pin>          <w0>                 <lf>
=== Output Control : CALL output in output.f ================================
Name      Kind_of_Element
'OUT'     'OUTPUT'
---OUTPUT CONTROL PARAMETERS ------------------------------------------------
Laser_Histgram(x y)   _Print(x y)  Particle_Histgram(x y)  _Print(x y)
<ahswx> <ahswy>     <ameswx> <ameswy>    <phswx>   <phswy>      <parsw>
=== Mirror : CALL rnmirr in mirror.f ========================================
Name       Kind_of_Element
'MRF'      'MIRROR'
-Width_of_Calcuration Area --------------------------------------------------
 Width
<width>
-Curvature-Diameter-Refrectance----Tilts----------Shifts----Num_of_Spline----
                                  x     y         x     y
<curv>     <diam>   <refrec> <thetax> <thetay> <delx> <dely>  <sorder>
=============================================================================
Name       Kind_of_Element
'MRB'      'MIRROR'
-----------------------------------------------------------------------------
 Width

<width>
-Curvature-Diameter-Refrectance----Tilts----------Shifts----Num_of_Spline----
                                  x     y         x     y
<curv>     <diam>   <refrec> <thetax> <thetay> <delx> <dely>  <sorder>
=== Free Space for Laser : CALL rnafre in afee.f ============================
Name       Kind_of_Element
'AF1'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
<width1>           <width2>
-----------------------------------------------------------------------------
Length
<length>
=============================================================================
Name       Kind_of_Element
'AF2'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
<width1>           <width2>
-----------------------------------------------------------------------------
Length
<length>
=============================================================================
Name        Kind_of_Element
'AF3'       'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
<width1>           <width2>
-----------------------------------------------------------------------------
Length
<length>
=============================================================================
Name       Kind_of_Element
'AF4'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
<width1>           <width2>
-----------------------------------------------------------------------------
Length
<length>
=============================================================================
Name       Kind_of_Element
'AFH'      'AFREE'
-----------------------------------------------------------------------------
Width_At_Entrance  Width_At_Exit
<width1>           <width2>
-----------------------------------------------------------------------------
Length
<length>
=============================================================================
Name     Kind_of_Element
'DEBUG'  'DEBUG'
=============================================================================
Name     Kind_of_Element

'TERM'   'TERM'
=============================================================================

References

[1] ”OPTICAL GUIDING SIMULATIONS FOR HIGH GAIN-SHORT WAVE LENGTH FELs,” J.E. LaSALA, D.A.G. DEACON and E.T. SCHARLEMANN, Nucl. Instr. and Meth. A250(1986)389.

[2] B. D. McVey, ”THREE-DIMENSIONAL SIMULATIONS OF FREE ELECTRON LASER PHYSICS,” Nucl. Instr. and Meth. A250(1986)449.