nreg=izonin! Read material for each region from egs5job.dataread(4,*) (med(i),i=1,nreg)! Set option except vacuum regiondo i=1,nreg-1if(med(i).ne.0) theniphter(i) = 1 ! Switches for PE-angle samplingiedgfl(i) = 1 ! K & L-edge fluorescenceiauger(i) = 0 ! K & L-Augeriraylr(i) = 0 ! Rayleigh scatteringlpolar(i) = 0 ! Linearly-polarized photon scatteringincohr(i) = 0 ! S/Z rejectioniprofr(i) = 0 ! Doppler broadeningend ifend doimpacr(i) = 0! Electron impact ionization! --------------------------------------------------------! Random number seeds. Must be defined before call hatch! or defaults will be used. inseed (1- 2^31)! --------------------------------------------------------luxlev = 1inseed=1write(6,120) inseed120 FORMAT(/,' inseed=',I12,5X,* ' (seed for generating unique sequences of Ranlux)')! =============call rluxinit! =============! Initialize the Ranlux random-number generator!-----------------------------------------------------------------------! Step 4: Determination-of-incident-particle-parameters!-----------------------------------------------------------------------! Define initial variables for incident particle normally incident! on the slabiqin=0! Incident particle charge - photonsekein=1.253 ! Incident particle kinetic energyxin=0.0! Source positionyin=0.0zin=-5.0uin=0.0! Moving along z axisvin=0.0win=1.0irin=0! Starting region (0: Automatic search in CG)wtin=1.0! Weight = 1 since no variance reduction used! pdf data for many sourcedeltae=0.05 ! Energy bin of response!-----------------------------------------! Get source region from <strong>cg</strong> input data!-----------------------------------------!if(irin.le.0.or.irin.gt.nreg) thencall srzone(xin,yin,zin,iqin+2,0,irin)if(irin.le.0.or.irin.ge.nreg) thenwrite(6,fmt="(' Stopped in MAIN. irin = ',i5)")irinstopend ifcall rstnxt(iqin+2,0,irin)end if!-----------------------------------------------------------------------! Step 5: hatch-call!-----------------------------------------------------------------------!-----------------------------------------------------------------------emaxe = 0.D0 ! dummy value to extract min(UE,UP+RM).write(6,130)130 format(/' Call hatch to get cross-section data')! ------------------------------! Open files (before HATCH call)! ------------------------------open(UNIT=KMPI,FILE='pgs5job.pegs5dat',STATUS='old')open(UNIT=KMPO,FILE='egs5job.dummy',STATUS='unknown')53
write(6,140)140 FORMAT(/,' HATCH-call comes next',/)! ==========call hatch! ==========! ------------------------------! Close files (after HATCH call)! ------------------------------close(UNIT=KMPI)close(UNIT=KMPO)! ----------------------------------------------------------! Print various data associated with each media (not region)! ----------------------------------------------------------write(6,150)150 FORMAT(/,' Quantities associated with each MEDIA:')do j=1,nmedwrite(6,160) (media(i,j),i=1,24)160 FORMAT(/,1X,24A1)write(6,170) rhom(j),rlcm(j)170 FORMAT(5X,' rho=',G15.7,' g/cu.cm rlc=',G15.7,' cm')write(6,180) ae(j),ue(j)180 FORMAT(5X,' ae=',G15.7,' MeVwrite(6,190) ap(j),up(j)ue=',G15.7,' MeV')190 FORMAT(5X,' ap=',G15.7,' MeVend doup=',G15.7,' MeV',/)! -------------------------------------------------------! Print media and cutoff energies assigned to each region! -------------------------------------------------------do i=1,nregif (med(i) .eq. 0) thenwrite(6,200) i200 FORMAT(' medium(',I3,')=vacuum')elsewrite(6,210) i,(media(ii,med(i)),ii=1,24),ecut(i),pcut(i)210 FORMAT(' medium(',I3,')=',24A1,* 'ecut=',G10.5,' MeV, pcut=',G10.5,' MeV')! -----------------------------------------------! Print out energy information of K- and L-X-rays! -----------------------------------------------if (iedgfl(i) .ne. 0) then! Output X-ray energyner = nne(med(i))do iiz=1,nerizn = zelem(med(i),iiz) ! Atomic number of this elementwrite(6,220) izn220 FORMAT(' X-ray information for Z=',I3)write(6,230) (ekx(ii,izn),ii=1,10)230 FORMAT(' K-X-ray energy in keV',/,* 4G15.5,/,4G15.5,/,2G15.5)write(6,240) (elx1(ii,izn),ii=1,8)240 FORMAT(' L-1 X-ray in keV',/,4G15.5,/,4G15.5)write(6,250) (elx2(ii,izn),ii=1,5)250 FORMAT(' L-2 X-ray in keV',/,5G15.5)write(6,260) (elx3(ii,izn),ii=1,7)260 FORMAT(' L-3 X-ray in keV',/,4G15.5,/,3G15.5)end doend ifend ifend dowrite(39,fmt="('MSTA')")write(39,fmt="(i4)") nregwrite(39,fmt="(15i4)") (med(i),i=1,nreg)write(39,fmt="('MEND')")!-----------------------------------------------------------------------! Step 6: Initialization-for-howfar!-----------------------------------------------------------------------!-----------------------------------------------------------------------! Step 7: Initialization-for-ausgab!-----------------------------------------------------------------------ncount = 0ilines = 0nwrite = 1054
- Page 1 and 2:
KEK Internal 2011-5December 2011R/D
- Page 3 and 4:
Lecture Notes ofResponse calculatio
- Page 5 and 6:
3 Details of user code 313.1 Main p
- Page 7 and 8: 1 Combinatrial Geometry (CG)2 Combi
- Page 9 and 10: ody 3 2 body + ; OR B23A1Figure 2
- Page 11 and 12: Z4 +4Z5 +5 -3Z6 +6 -5END1 0 2 3 4 0
- Page 13 and 14: end if! ==============call block_se
- Page 15 and 16: ! pdf data for many sourcedeltae=0.
- Page 17 and 18: ! ---------------------------------
- Page 19 and 20: sigph=dsqrt((ph2s(ie)-avph*avph)/nc
- Page 21 and 22: 6 6.1 NaI 1. Cs-137 (0.662MeV) 2.
- Page 23 and 24: ekein=1.253ekein=1.333{ ! ---------
- Page 25 and 26: ROuter vacuum (region 6)Air region
- Page 27 and 28: nmed=2 medarr(1)='NAImedarr(2)='ALm
- Page 29 and 30: ROuter vacuum (region 4)Air region
- Page 31 and 32: EGS5 sample user code (ucnaicgv.f)R
- Page 33 and 34: operator, it means that the region
- Page 35 and 36: 2 Outlines of sample user code uccg
- Page 37 and 38: include 'auxcommons/edata.f'include
- Page 39 and 40: The material assignment is read in
- Page 41 and 42: ! Write batch numberwrite(39,fmt="(
- Page 43 and 44: ! ---------------------------------
- Page 45 and 46: a distance to the boundary of regio
- Page 47 and 48: { Add sampling routines for source
- Page 49 and 50: ROuter vacuum (region 6)Air region
- Page 51 and 52: to* xi0,yi0,zi0,avab,depes,depe2s,s
- Page 53 and 54: ROuter vacuum (region 4)Air region
- Page 55 and 56: Appendix: Full listings of ucnaicgv
- Page 57: open(39,FILE='egs5job.pic',STATUS='
- Page 61 and 62: ilines = ilines + 1write(6,280) eto
- Page 63 and 64: * 14X,' Positron')do ie=1,50elow=de
- Page 65 and 66: ! ---------------------------------
- Page 67 and 68: ccyidd=y_np+tval0*v_npzidd=z_np+tva