(file) Return to simulate_init.inc CVS log (file) (dir) Up to [HallC] / Poltar

  1 jones 1.1 ! SIMULATE_INIT.INC
  2           
  3           ! Note: All angles are in radians
  4           !	All distances are in cm
  5           !	All energies (momenta,masses) are in MeV
  6           !	All deltas are in percent
  7           !	All densities (thicknesses) are in g/cm3 (g/cm2)
  8           
  9           ! Define some record structures, and constants
 10           
 11           	include 'structures_init.inc'
 12           	include 'constants.inc'
 13           
 14           ! Now for the actual variables
 15           
 16           ! ??? these montecarlo-specific values should go in a DAT file.
 17           ! ... the slop that will be allowed on the cuts when they are to be applied "loosely"
 18           	real*8 slop_param_d_HMS, slop_param_t_HMS, slop_param_p_HMS
 19           	parameter	(slop_param_d_HMS=0.5)
 20           	parameter	(slop_param_t_HMS=0.005)
 21           	parameter	(slop_param_p_HMS=0.005)
 22 jones 1.1 	real*8 slop_param_d_SOS, slop_param_t_SOS, slop_param_p_SOS
 23           	parameter	(slop_param_d_SOS=1.0)
 24           	parameter	(slop_param_t_SOS=0.008)
 25           	parameter	(slop_param_p_SOS=0.008)
 26           	real*8 slop_param_d_HRSR, slop_param_t_HRSR, slop_param_p_HRSR
 27           	parameter       (slop_param_d_HRSR=0.5)
 28           	parameter       (slop_param_t_HRSR=0.005)
 29           	parameter       (slop_param_p_HRSR=0.005)
 30           	real*8 slop_param_d_HRSL, slop_param_t_HRSL, slop_param_p_HRSL
 31           	parameter       (slop_param_d_HRSL=0.5)
 32           	parameter       (slop_param_t_HRSL=0.005)
 33           	parameter       (slop_param_p_HRSL=0.005)
 34           
 35           ! ... the common blocks
 36           
 37           !RMM changed ordering in /gnrl/ to fix memory alignment problems
 38           
 39           	real*8	Mh, Mh2, Mh2_final	!mh,mh2 are INITIAL hadron mass(**2)
 40           	real*8	Ebeam, dEbeam, Ebeam_vertex_ave, genvol, genvol_inclusive
 41           	real*8	luminosity, targetfac, normfac
 42           	real*8	wtcontribute, dE_edge_test, Egamma_gen_max
 43 jones 1.1         real*8  targ_Bangle,targ_Bphi
 44           	real*8  drift_to_cal,targ_pol,sign_hms_part
 45           
 46           	record /gen_limits/	gen
 47           	record /both_spec/	spec
 48           	record /cuts_true/	cuts
 49           	record /edge_true/	edge
 50           	record /edge_true/	VERTEXedge
 51           	record /double_arm_cuts/ SPedge
 52           	record /slop/		slop
 53           	record /EXP_field/	EXPER
 54           	logical mc_smear
 55           	logical debug(5)
 56           	integer*4 nevent, ntried, ngen, deForest_flag, Nntu
 57           	integer*4 ncontribute, ncontribute_no_rad_proton, spect_mode, phsp_mode
 58           	integer*4 which_kaon, which_pion, which_dvcs
 59           	integer*4 electron_arm, hadron_arm
 60           	character base*40
 61           	character extra_dbase_file*60
 62           	character tgt_field_file*60
 63           	logical using_E_arm_montecarlo, using_P_arm_montecarlo
 64 jones 1.1 	logical doing_phsp, using_rad, hard_cuts
 65           	logical doing_hyd_elast, doing_deuterium, doing_heavy
 66           	logical doing_eep, doing_pion, doing_piplus, doing_kaon
 67           	logical doing_dvcs
 68           	logical using_cit_generation, using_Coulomb, using_Eloss
 69           	logical correct_Eloss, correct_raster,using_tgt_field
 70           
 71           
 72           
 73           
 74           	common /gnrl/   Mh, Mh2, Mh2_final, Ebeam, dEbeam, Ebeam_vertex_ave,
 75           	1 genvol, genvol_inclusive, luminosity, targetfac,
 76           	2 normfac, wtcontribute, dE_edge_test, Egamma_gen_max,
 77           	3 targ_Bangle,targ_Bphi,
 78           	3 drift_to_cal,targ_pol,sign_hms_part,
 79           	4 gen, spec, cuts, edge, SPedge, VERTEXedge,
 80           	5 slop, EXPER, mc_smear, debug, nevent, ntried, ngen,
 81           	6 deForest_flag, Nntu, ncontribute, ncontribute_no_rad_proton, 
 82           	7 spect_mode, phsp_mode, which_kaon,which_pion, which_dvcs,
 83           	8 electron_arm, hadron_arm,
 84           	9 base, extra_dbase_file, tgt_field_file, 
 85 jones 1.1 	1 using_E_arm_montecarlo,  using_P_arm_montecarlo, doing_phsp, 
 86           	2 using_rad, hard_cuts, doing_hyd_elast, doing_deuterium, doing_heavy,
 87           	3 doing_eep,doing_pion,doing_piplus,doing_kaon,doing_dvcs,
 88           	4 using_cit_generation, using_Coulomb,
 89           	5 using_Eloss, correct_Eloss, correct_raster,using_tgt_field
 90           
 91           
 92           
 93           ! ........ note: make these first two parameters at least ONE BIGGER than the actual dimensions you want to read in
 94           	integer*4 ntheorymax,nrhoPmmax
 95           	parameter	(ntheorymax=500)
 96           	parameter	(nrhoPmmax=21)
 97           	real*8		theory, Em_theory, bs_norm_theory, nprot_theory
 98           	real*8		Emsig_theory, Em_int_theory, E_Fermi
 99           	integer		nrhoPm
100           	character	theory_file*80, theory_base*40, theory_target*40
101           
102           	record /axis/	Pm_theory
103           
104           	common /theory/ theory(nrhoPmmax,ntheorymax),
105           	1    Em_theory(nrhoPmmax), bs_norm_theory(nrhoPmmax),
106 jones 1.1 	2    nprot_theory(nrhoPmmax), Emsig_theory(nrhoPmmax),
107           	4    Em_int_theory(nrhoPmmax), E_Fermi,
108           	5    Pm_theory(nrhoPmmax),
109           	6    theory_file, theory_base, theory_target,
110           	7    nrhoPm
111           
112           C decdist(30) is just an array of miscellaneous shared variables, SOME of
113           C which are related to decay.  Here are the ones that are currently in use:
114           Cxx	decdist(30)    = position where event decays (cm)
115           C	decdist(3)  = sum of sigcc (to calculate "central sigcc")
116           Cxx	decdist(4)  = radphot   (for ntuple output)
117           Cxx	decdist(5)  = flag for type of radiation (which particle).
118           Cxx	decdist(6)  = resfac in ntup. (sum of resolution modifiers for HMS/SOS)
119           Cxx	decdist(21) = sigma_eep (which is eepi cross section - Sigcc in ntup.)
120           C
121           C	real*8 decdist(30)
122           
123           	real*8 ctau
124           	logical doing_hydpi, doing_deutpi, doing_hepi
125           	logical doing_hydkaon, doing_deutkaon, doing_hekaon
126                   logical doing_hyddvcs, doing_deutdvcs, doing_hedvcs
127 jones 1.1 	logical doing_decay
128           
129           	common /decd/ ctau,doing_decay,
130           	1 doing_hydpi,doing_deutpi,doing_hepi,
131           	2 doing_hydkaon,doing_deutkaon,doing_hekaon,
132           	3 doing_hyddvcs, doing_deutdvcs, doing_hedvcs
133           
134           C Trying to get rid of the decdist array of random variables.
135           C Structure for variables that we want to available to the ntuple.
136           	structure /ntupvars/
137           		real*8 radphot, radarm
138           		real*8 resfac
139           		real*8 sigcm,sigl,sigt
140           		real*8 krel, mm, mmA, t
141           	end structure
142           
143           	record /ntupvars/ ntup
144           
145           C decdist is zpos of decay if doing_decay, survivalprobability if
146           C .not.doing_decay.  NOT included in ntup.* structure because it is used
147           C in the single arm MC, which we want to keep structure-free.
148 jones 1.1 
149                   real*8 decdist
150           
151           	common /ntuple_variables/ ntup, decdist
152           
153           
154           
155           C Kaon cross section lookup tables (real*4 for CERNLIB fint compatability).
156           	real*4 zrff1(10,11,19),zrff2(10,11,19),zrff3(10,11,19)
157           	real*4 zrff4(10,11,19),zrff5(10,11,19),zrff6(10,11,19)
158           	real*4 ziff1(10,11,19),ziff2(10,11,19),ziff3(10,11,19)
159           	real*4 ziff4(10,11,19),ziff5(10,11,19),ziff6(10,11,19)
160           	real*4 zsrff1(20,10,19),zsrff2(20,10,19),zsrff3(20,10,19)
161           	real*4 zsrff4(20,10,19),zsrff5(20,10,19),zsrff6(20,10,19)
162           	real*4 zsiff1(20,10,19),zsiff2(20,10,19),zsiff3(20,10,19)
163           	real*4 zsiff4(20,10,19),zsiff5(20,10,19),zsiff6(20,10,19)
164           	real*4 thrown(50,50,50)
165           	real*4 genera(50,50,50)
166           	real*4 recons(50,50,50)
167           	real*4 weightc(20,50)
168           	real*4 weightd(8,40,30)
169 jones 1.1 
170           	common /sigkaon/ thrown,genera,recons,weightc,weightd,
171           	1 zrff1,zrff2,zrff3,zrff4,zrff5,zrff6,
172           	2 ziff1,ziff2,ziff3,ziff4,ziff5,ziff6,
173           	3 zsrff1,zsrff2,zsrff3,zsrff4,zsrff5,zsrff6,
174           	4 zsiff1,zsiff2,zsiff3,zsiff4,zsiff5,zsiff6
175           
176           
177           
178           C momentum distribution (nump=#/points, pval=p, mprob=integral (p^2 f(p) dp)
179           	real*8 pval(2000),mprob(2000)
180           	real*8 pfer,pferx,pfery,pferz
181           	integer*4 nump
182           	real*8 he_em
183           	integer*4 nume
184           	real*8 eval(2000)
185           
186           	common /pfermi/ eval,pval,mprob,pfer,pferx,pfery,pferz,he_em,nump,nume
187           
188           ! ... and some variable blocks of general interest defined in external files
189           	include 'target.inc'

Analyzer/Replay: Mark Jones, Documents: Stephen Wood
Powered by
ViewCVS 0.9.2-cvsgraph-1.4.0