* 96Cd setting from S352 experiment July 2008
* Input file by P. Boutachkov, 25.6.2008
*
* effective lengths adjusted for RUN81-TA1B/TA2B optics 11 Dec 2006, H. Weick 
* Apertures defined by Th. Baumann and D. Cortina-Gil in Aug. 1997 
*
* Saves at the following positions:
*
* SAVE #1, after Target
* SAVE #2, at S1 after slits/degrader
* SAVE #3, at S2 before matter/slits
* SAVE #4, at S2 before wedge, after Sci21
* SAVE #5, at S2 after wedge at S2 Focal Plane
* SAVE #6, at S2 after all matter
* SAVE #7, at S3 before slits
* SAVE #8, at S4 before matter
* SAVE #9, at S4 before MUSIC 1
* SAVE #10,at S4 after MUSIC 1
* SAVE #11, After SC41
* SAVE #12, After SC42
* SAVE #13, Before Implantation 
* SAVE #14, After Si-Stopper at S4 FOCAL PLANE
 
 epax 2
 atima-1.0
* option listmode cwn
 option listmode tree
*  
 BEAM                                    Xe124 beam, 850 A MeV
 10000
 850.0, 0, 124, 54
 4
 0.10,  5.00, 0, 0, 0
 4
 0.15,  3.33, 0, 0, 0
 4
 0.1,  0, 0, 0, 0
***********************************************
 MATRIXFILE
/u/weick/gicosy/frs/run81/mocadi/

***********************************************

MATTER                      ' SIS Carbon Window 35mug/cm^2'
12, 6, 2253
3, 0.035
0
0., 0., 0.
1, 1
0, 0, 0, 0

MATTER  	        '  SEETRAM three 48Ti foils'
48, 22, 4519
3, 13.5
0
0., 0., 0.
1, 1
0, 0, 0, 0


*PRIMARY_BEAM
*1

***********************************************
 TARGET                        *9Be target 1848 mg/cm^3
 9., 4, 1848, 1		       *target material, shape of distribution (Goldhaber)
 96, 48          	       *set fragment A, Z
 5, 4009, 0.0, 0.0, 0.0	       *target thickness mg/cm^2
 1, 1, 1, 1, -1, 0	       *reaction options
*Fklwi, Fenstr, Fgold, Fwico, Fkauf, Fspalt


FRAGMENT 
 2, 3
48, 97		* 97Cd
47, 95		* 95Ag
47, 96		* 96Ag


/*
FRAGMENT 
 2, 10
48, 97		* 97Cd
48, 98		* 98Cd
48, 99		* 99Cd
49, 98		* 98In
49, 99		* 99In
47, 95		* 95Ag
47, 96		* 96Ag
47, 97		* 97Ag
46, 93		* 93Pd
46, 96		* 96Pd
50, 99		* 99Sn
*/

***********************************************
 ERWARTUNGSWERTE                 '1: After Target '
 SAVE                            
* END
*******************************************
DRIFT
49.2
*Y-SLIT
SLIT
-100.0, 100.0, -10.0, 10.0

DRIFT
36.8
*X-SLIT
SLIT
-10.0, 10.0, -100.0, 100.0
DRIFT
68.02     to eff. edge

***********************************************************************************
* From Target Area TA to S1

 MATRIX
 RUN81TA2BRISING001.MAT			TS2QT11 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING002.MAT			TS2QT11
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING003.MAT			TS2QT11 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 DRIFT
   45.789787
 MATRIX
 RUN81TA2BRISING004.MAT			TS2QT12 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING005.MAT			TS2QT12
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING006.MAT			TS2QT12 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 DRIFT
   46.181583
 MATRIX
 RUN81TA2BRISING007.MAT			TS2QT13 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING008.MAT			TS2QT13
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING009.MAT			TS2QT13 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 DRIFT
    7.809323
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING010.MAT			TS2KS1
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
   59.559204
 MATRIX
 RUN81TA2BRISING011.MAT			TS3MU1 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING012.MAT			TS3MU1
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING013.MAT			TS3MU1
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING014.MAT			TS3MU1 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 DRIFT
   59.559204
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING015.MAT			TS3KS1
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
    7.800004
 MATRIX
 RUN81TA2BRISING016.MAT			TS3QD11 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING017.MAT			TS3QD11
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING018.MAT			TS3QD11 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 DRIFT
   46.195782
 MATRIX
 RUN81TA2BRISING019.MAT			TS3QD12 ff
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING020.MAT			TS3QD12
 95.93977, 48, 654.6447                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING021.MAT			TS3QD12 ff
 95.93977, 48, 654.6447                          
 3, 3                                    

**************************************************************************************
DRIFT
128.0
* 125.895775 original value
*
******************** S1 *****************
*ERWARTUNGSWERTE         '2: S1 before slits'
*SAVE
                    
SLIT                    
* xmin, xmax, ymin, ymax 
-30.0, 30.0, -30.0, 30.0


MATTER                  Al-Degrader 2000mg/cm^2
27, 13, 2700,
3, 2000.0, 0, 0, 0,
0, 0, 0
0, 0, 0
1, 1
0, 0, 0, 0

* thickness of degrader: 0.7407cm
* optical length after degrader:125.895775+126.084152-128.0-0.7407=123.239 

ERWARTUNGSWERTE          '2: After degrader S1'
SAVE                     

DRIFT
123.239
*  126.084152 original value

**************************************************************************************
* From S1 to S2
* 95.93977, 48, 552.9029

 MATRIX
 RUN81TA2BRISING022.MAT			TS3QD21 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING023.MAT			TS3QD21
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING024.MAT			TS3QD21 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 DRIFT
   46.603741
 MATRIX
 RUN81TA2BRISING025.MAT			TS3QD22 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING026.MAT			TS3QD22
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING027.MAT			TS3QD22 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 DRIFT
    8.019595
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING028.MAT			TS3KS3
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
   59.559204
 MATRIX
 RUN81TA2BRISING029.MAT			TS3MU2 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING030.MAT			TS3MU2
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING031.MAT			TS3MU2
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING032.MAT
 95.93977, 48, 552.9029			TS3MU2 ff   
 3, 3                                    
 DRIFT
   59.559204
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING033.MAT			TS3KS3
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
    7.651551
 MATRIX
 RUN81TA2BRISING034.MAT			TS3QT31 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING035.MAT			TS3QT31
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING036.MAT			TS3QT31 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 DRIFT
   46.135696
 MATRIX
 RUN81TA2BRISING037.MAT			TS3QT32 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING038.MAT			TS3QT32
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING039.MAT			TS3QT32 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 DRIFT
   45.926147
 MATRIX
 RUN81TA2BRISING040.MAT			TS3QT33 ff
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING041.MAT			TS3QT33
 95.93977, 48, 552.9029                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING042.MAT			TS3QT33 ff
 95.93977, 48, 552.9029                           
 3, 3       


**************************************************************************************                             
* The total drift length at S2 should be 451.91
* the drift length from Ts3QT33 to the S2-focus is 225.9420252
*
************************************************** S2 ********************************

DRIFT
99.242

ERWARTUNGSWERTE              '3: S2 before matter'
SAVE                         * 

*y-slits
SLIT
-30, 30, -30, 30 

DRIFT
21.5

*x-slits
SLIT
-30, 30, -30, 30

DRIFT
32.49

*Start of TOF Measurement
RESET

*************************************
*SCI Ladder BC420 3.20mm SCI21
MATTER
0, 201, 1032,
2, 0.320,
0
0., 0., 0.
1, 1	
0, 0, 0, 0
* optical length 0.320
*************************************

ERWARTUNGSWERTE            '4: before wedge, after Sci21'
SAVE    

DRIFT 
64.4067               * Adjust depending on Wedge Thickness (see ooffice file)
                   

************************************
*Profiled Degrader d=Thickness0+Thickness1*x+Thickness2*x^2
*Achromatic Wedge

WEDGE
27, 13, 2700
1800, -10.9343, 0		        
6, 0, 0, 0
1, 1, -1, 1
0, 0, 0, 0                                         
*
* optical length 0.93cm
*

******** Adjustable DRIFT ***************
DRIFT
5.2587  * variable depending on Wedge Thickness
*****************************************

ERWARTUNGSWERTE            '5: after wedge at S2 Focal Plane'
SAVE			   * 

DRIFT
39.8080  * Fixed drift

MATTER                       *  New Iron vacuum window exit/ No Ti
56, 26, 7870
2, 0.01
0
0., 0., 0.
1, 1
0, 0, 0, 0
* optical length 0.02

***********************we are in the air now **********************
DRIFT-IN-GAS                   Air
8.2860,0,202,10.655796         * DRIFT DISTANCE/POSITIONS TPCs
1,1

******************* FIRST TPC at S2 ********************
MATTER				Kapton Window
0, 213, 1392,
3, 7.52
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                    Ar gas in the detector
11.5,40,18,20.51
1,1
MATTER				Kapton foil
0, 213, 1392,
3, 3.75
0
0., 0., 0.
1, 1
0, 0, 0, 0
* optical length 11cm
********************END FIRST TPC*************************

DRIFT-IN-GAS                   Air
105.1919,0,202,135.2768        * MEASURED DISTANCE BETWEEN TPCs
1,1

******************* SECOND TPC at S2*****************
MATTER				Kapton Window
0, 213, 1392,
3, 7.52
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                    Ar gas in the detector
11.5,40,18,20.51
1,1
MATTER				Kapton foil
0, 213, 1392,
3, 3.75
0
0., 0., 0.
1, 1
0, 0, 0, 0
*length 11cm
*******************END SECOND TPC**************************

DRIFT-IN-GAS                   Air
9.2460,0,202,11.890356         * 
1,1

/*
MATTER			       *Nb-Striper 223mg/cm^2 optical length 0.026021 cm
92.90638, 41, 8570.0
3, 223.0, 0, 0, 0
0, 0, 0
0, 0, 0
1, 1
0, 0, 0, 0
*/
***********************we go into vacuum again ********************

MATTER                          Titanium vacuum window entrance
48, 22, 4519,
3, 90.0
0
0., 0., 0.
1, 1
0, 0, 0, 0
* optical length 0.02

DRIFT
42.4521

ERWARTUNGSWERTE              '6: S2 after all matter'
SAVE			      

************************************************************************************

 MATRIX
 RUN81TA2BRISING043.MAT			TS4QT11 ff
 95.93977, 48, 408.6582                    
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING044.MAT			TS4QT11
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING045.MAT			TS4QT11 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   45.932011
 MATRIX
 RUN81TA2BRISING046.MAT			TS4QT12 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING047.MAT			TS4QT12 
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING048.MAT			TS4QT12 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   46.064606
 MATRIX
 RUN81TA2BRISING049.MAT			TS4QT13 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING050.MAT			TS4QT13
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING051.MAT			TS4QT13 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
    7.601257
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING052.MAT			TS4KS1
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
   59.559204
 MATRIX
 RUN81TA2BRISING053.MAT			TS4MU1 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING054.MAT			TS4MU1
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING055.MAT			TS4MU1
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING056.MAT			TS4MU1 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   59.559204
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING057.MAT			TS4KS2
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
    7.895144
 MATRIX
 RUN81TA2BRISING058.MAT			TS4QD21 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING059.MAT			TS4QD21
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING060.MAT			TS4QD21 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   46.394325
 MATRIX
 RUN81TA2BRISING061.MAT			TS4QD22 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING062.MAT			TS4QD22
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING063.MAT			TS4QD22 ff
 95.93977, 48, 408.6582                          
 3, 3                                    

**************************************************************************************
 DRIFT
  125.999176

******************** S3 *****************
ERWARTUNGSWERTE 		     '7: S3 before slits'
SAVE

*Slits in x and y - just in case they might be needed
SLIT
-30,30,-30,30
                                
************************************************************************************
*
 DRIFT
  125.829254
 MATRIX
 RUN81TA2BRISING064.MAT			TS4QD31 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING065.MAT			TS4QD31
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING066.MAT			TS4QD31 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   45.894859
 MATRIX
 RUN81TA2BRISING067.MAT			TS4QD32 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING068.MAT			TS4QD32
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING069.MAT			TS4QD32 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
    7.565603
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING070.MAT			TS4KS3
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
   59.559204
 MATRIX
 RUN81TA2BRISING071.MAT			HFSMU1 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING072.MAT
 95.93977, 48, 408.6582		HFSMU1
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING073.MAT
 95.93977, 48, 408.6582		HFSMU1   
 3, 3                                    
 COLL
 1, 0, 0, 12.75, 5.0, 0.0
 MATRIX
 RUN81TA2BRISING074.MAT			HFSMU1 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   59.559204
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 MATRIX
 RUN81TA2BRISING075.MAT			HFSKS1
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 11.88, 12.4, 6.965
 DRIFT
    7.634240
 MATRIX
 RUN81TA2BRISING076.MAT			HFSQt11 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING077.MAT			HFSQT11
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING078.MAT			HFSQT11 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   45.854671
 MATRIX
 RUN81TA2BRISING079.MAT			HFSQT12 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING080.MAT			HFSQT12
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING081.MAT			HFSQT12 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 DRIFT
   45.412300
 MATRIX
 RUN81TA2BRISING082.MAT			HFSQT13 ff
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING083.MAT			HFSQT13
 95.93977, 48, 408.6582                          
 3, 3                                    
 COLL
 4, 0, 0, 12.4, 12.58, 7.47
 MATRIX
 RUN81TA2BRISING084.MAT			HFSQT13 ff
 95.93977, 48, 408.6582                           
 3, 3

**************************************************************************************

ERWARTUNGSWERTE   		'8: S4 before matter'
SAVE                            

* distance from the magnet yoke is 82.5 cm
* the MAT extends 4.6/2 cm
* Hence the distance is 80.75-4.6/2~80 cm.4.6/2
* The distance to the S4 focal point is 440.7 cm from the magnet yoke
DRIFT
78.45

MATTER                          Titanium vacuum window exit
48, 22, 4519,
3, 90.0
0
0., 0., 0.
1, 1
0, 0, 0, 0
* optical length 0.02


***********************we are in the air now ***************

* The Distance is  440.7  for RISING where the focus should be
* measured from the last quadrupole magnet - 4.6/2 as the ELEMENT LENGTH
* of the last quadropol is 1.046137290E+00 M
* Hence: 438.4 cm
*
******************** S4 DETECTORS *****************

DRIFT-IN-GAS                   Air 1.286mg/cm2
5.5,0,202,7.073   
1,1

******************* FIRST TPC ********************
MATTER				Kapton Window
0, 213, 1392,
3, 7.52
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                    Ar gas in the detector
11.5,40,18,20.51
1,1
MATTER				Kapton foil
0, 213, 1392,
3, 3.75
0
0., 0., 0.
1, 1
0, 0, 0, 0
* optical length 11cm
********************END FIRST TPC*************************

DRIFT-IN-GAS                   Air
8.0,0,202,10.312   
1,1

********************MultiWire 41 ************
MATTER			      Kapton Window
0, 213, 1420
3, 3.55
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                  Ar_CO2_30 gas in detector
15.5, 0, 210, 28.49
1, 1
MATTER                        Kapton Window
0, 213, 1420
3, 3.55
0
0., 0., 0.
1, 1
0, 0, 0, 0
* length 10cm
**********************END MW 41***********************

DRIFT-IN-GAS                   Air
5.5,0,202,7.07  
1,1

ERWARTUNGSWERTE            '9: Before MUSIC 1 at S4'
SAVE

******************** MUSIC 1 ****************
MATTER                        Mylar Window
0, 214, 1397,
3, 3.48
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                  for air
1.5, 0, 202, 1.930
1, 1
MATTER                        glass window
0, 208, 2230,
3, 52.71
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                 CF4 gas in detector
42.0, 0, 211, 153.7
1,1
MATTER                        glass window
0, 208, 2230,
3, 52.71
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                  for air
1.5, 0, 202, 1.930
1, 1
MATTER                        Mylar Window
0, 214, 1397,
3, 3.48
0
0., 0., 0.
1, 1
0, 0, 0, 0
*length 45.2cm
*****************END MUSIC 1***************************

ERWARTUNGSWERTE            '10: After MUSIC 1 at S4'
SAVE

DRIFT-IN-GAS                   Air
11.9739,0,202,15.3985     *prev. 12.0,0,202,15.432     
1,1

***************** MUSIC 2 ******************
MATTER                        Mylar Window
0, 214, 1397,
3, 3.48
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                  for air
1.5, 0, 202, 1.930
1, 1
MATTER                        glass window
0, 208, 2230,
3, 52.71
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                 CF4 gas in detector
42.0, 0, 211, 153.7
1,1
MATTER                        glass window
0, 208, 2230,
3, 52.71
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                  for air
1.5, 0, 202, 1.930
1, 1
MATTER                        Mylar Window
0, 214, 1397,
3, 3.48
0
0., 0., 0.
1, 1
0, 0, 0, 0
*length 45.2cm
******************END MUSIC 2*************************

DRIFT-IN-GAS                   Air
4.5,0,202,5.787          
1,1

******************* SECOND TPC *****************
MATTER				Kapton Window
0, 213, 1392,
3, 7.52
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                    Ar gas in the detector
11.5,40,18,20.51
1,1
MATTER				Kapton foil
0, 213, 1392,
3, 3.75
0
0., 0., 0.
1, 1
0, 0, 0, 0
*length 11cm
*******************END SECOND TPC**************************

DRIFT-IN-GAS                   Air
9.5,0,202,12.217
1,1

********************MultiWire 42 ************
MATTER			      Kapton Window
0, 213, 1420
3, 3.55
0
0., 0., 0.
1, 1
0, 0, 0, 0
DRIFT-IN-GAS                  Ar_CO2_30 gas in detector
13.5, 0, 210, 24.81
1, 1
MATTER                        Kapton Window
0, 213, 1420
3, 3.55
0
0., 0., 0.
1, 1
0, 0, 0, 0
* length 10cm
*********************END MW42*********************

DRIFT-IN-GAS                   Air
3.5,0,202,4.501  
1,1

*******************SLITS S4************************
* Slits ONLY in x
SLIT
-30,30,-30,30
*
*******************END SLITS S4**************************

DRIFT-IN-GAS                   Air
32.5,0,202,41.795
1,1

****************************SCI 41 *******************
*SCI  BC420 3.15mm SCI41
MATTER				*(polyolefin window)
0,	217,	1070,
3,	42.8
0
0.,	0.,	0.
1,	1
0,	0,	0,	0


MATTER
0, 201, 1032,
2, 0.315,
0
0., 0., 0.
1, 1
0, 0, 0, 0

MATTER				*(polyolefin window)
0,	217,	1070,
3,	42.8
0
0.,	0.,	0.
1,	1
0,	0,	0,	0

* optical length 0.315
************************END SCI41******************************

ERWARTUNGSWERTE            '11: After SC41'
SAVE

DRIFT-IN-GAS                   Air
19.0,0,202,24.434   
1,1 

***********************DEGRADER S4******************************

MATTER			Al-Degrader variable mg/cm^2
27, 13, 2700,
3, 2190.0, 0, 0, 0,
0, 0, 0
0, 0, 0
1, 1
0, 0, 0, 0

************************END DEGRADER S4***************************

DRIFT-IN-GAS                   Air
18.5,0,202,23.791
1,1

****************************SCI 42 *******************
*SCI  BC420 2mm SCI42

MATTER				*(polyolefin window)
0,	217,	1070,
3,	42.8
0
0.,	0.,	0.
1,	1
0,	0,	0,	0

MATTER
0, 201, 1032,
2, 0.200,
0
0., 0., 0.
1, 1
0, 0, 0, 0

MATTER				*(polyolefin window)
0,	217,	1070,
3,	42.8
0
0.,	0.,	0.
1,	1
0,	0,	0,	0

* optical length 0.200
************************END SCI42******************************

ERWARTUNGSWERTE            '12: After SC42'
SAVE

* optical length VARIABLE to ADAPT in sum to 440.7-4.6/2 cm  
* sum of the drifts until this point-11.65 cm for the Si: 
* difference 94.4

DRIFT-IN-GAS                   Air
88.0,0,202,113.168       
1,1

*****************************************************               

DRIFT-IN-GAS                   Air
4.340,0,202,5.575       * prev. 4.335,0,202,5.575       
1,1



ERWARTUNGSWERTE            '13: Before Implantation'
SAVE       

/*
MATTER				'Active Stopper'
28, 14, 2329.99,
2, 0.3, 0, 0, 0,                 '3*0.1cm'
0, 0, 0
0, 0, 0
1, 1
0, 0, 0, 0

DRIFT-IN-GAS                   Air
38.4885,0,202,49.496211
1,1
*/

*
* 1 mm  Si --> 233 mg/cm2
* 1.5 mm Si --> 349.4985 mg/cm2

STOP 
28,14

*STOP
*0,201

ERWARTUNGSWERTE            '14: After Si-Stopper at S4 focal plane'
SAVE  

************************************************************************************

END


