if (iwatch .gt. 0) call swatch(iarg,iwatch)! ========================! ---------------------------------! Keep track <strong>of</strong> how deep stack gets! ---------------------------------if (np.gt.MXSTACK) thenwrite(6,100) np,MXSTACK100 FORMAT(//' In AUSGAB, np=',I3,' >= maximum stack',* ' allowed which is',I3/1X,79('*')//)stopend if! ------------------------! Set some local variables! ------------------------irl = ir(np)iql = iq(np)edepwt = edep*wt(np)! ----------------------------------------------------------------! Print out stack information (for limited number cases and lines)! ----------------------------------------------------------------if (ncount .le. nwrite .and. ilines .le. nlines) thenilines = ilines + 1write(6,101) e(np),x(np),y(np),z(np),u(np),v(np),w(np),* iql,irl,iarg101 FORMAT(7G15.7,3I5)end if! -----------------------------------------------------------! Keep track <strong>of</strong> energy deposition (for conservation purposes)! -----------------------------------------------------------if (iarg .gt. 5) returnesum(iql+2,irl,iarg+1) = esum(iql+2,irl,iarg+1) + edepwtnsum(iql+2,irl,iarg+1) = nsum(iql+2,irl,iarg+1) + 1i=mod(irl-1,imax)if (i.eq.0) i=imaxk=1+(irl-1-i)/ijmaxj=1+(irl-1-i-(k-1)*ijmax)/imaxif (irl.gt.1.and.edep.ne.0.D0) thendepe(i,j,k)=depe(i,j,k)+edepwtend if!--------------------------------! Check cross <strong>phantom</strong> surface!--------------------------------if(i.eq.imax/2+1.and.j.eq.jmax/2+1) then ! X-Y central regionif (abs(irl-irold).eq.ijmax.and.iq(np).eq.0) thenif ((w(np).gt.0.0.and.k.eq.2).or.* (w(np).le.0.0.and.k.eq.1)) thenif (dabs(w(np)).ge.0.0349) thencmod=dabs(w(np))elsecmod=0.01745end ifesing=e(np)dcon=encoea(esing)! PHOTX datafexps=fexps+e(np)*dcon*wt(np)/cmodif (w(np).lt.0.0) latch(np)=1if (w(np).gt.0.0.and.latch(np).eq.0) thenfaexp=faexp+e(np)*dcon*wt(np)/cmodend ifend ifend ifend if12
! ------------------------------------! Output particle information for plot! ------------------------------------if (ncount.le.maxpict) thencall plotxyz(iarg,np,iq(np),x(np),y(np),z(np),e(np),ir(np),* w(np))end ifreturnend2.12 subroutine howfarhowfar howfar (idisc=1) ucxyz <strong>phantom</strong>.f voxel howfar subroutine howfarimplicit noneinclude 'include/egs5_h.f'include 'include/egs5_epcont.f'include 'include/egs5_stack.f'include 'auxcommons/aux_h.f'include 'auxcommons/geoxyz.f'include 'auxcommons/instuf.f'real*8* dist,dnearlinteger* irl,irx,iry,irzirl = ir(np)! Main EGS "header" file! COMMONs required by EGS5 code! Auxiliary-code "header" fileif (irl .le. 0) thenwrite(6,*) 'Stopped in howfar <strong>with</strong> irl
- Page 1 and 2: KEK Internal 2011-8December 2011R/D
- Page 3 and 4: Lecture Notes ofDose distribution c
- Page 5 and 6: 2.8.1 Statistical uncertainty . . .
- Page 7 and 8: 1 ucxyz phantom.f ucxyz phantom.f
- Page 9 and 10: common/score/! Variables to score*
- Page 11 and 12: emaxe = 0.D0 ! dummy value to extra
- Page 13 and 14: vin=dsin(phai)*sinthdis=sposi/winxp
- Page 15 and 16: 2.9 Step 9: Output of results ()wr
- Page 17: ipeangswiedgeswiaugerswirayswipolar
- Page 21 and 22: end ifend ifend ifdnear(np)=dnearlr
- Page 23 and 24: 4 ucxyz phantom.f (egs5job.out, e
- Page 25 and 26: 4.2 1. cp ucxyz phantom1.f ucxyz ph
- Page 27 and 28: call randomset(rnnow)do ie=1,nsebin
- Page 29 and 30: Linux 4 ucxyz phantom3 25 Enter
- Page 31 and 32: Linux ucxyz phantom5 , 4 25 "Doe
- Page 33 and 34: 1 Outlines of sample user code ucxy
- Page 35 and 36: common/score/! Variables to score*
- Page 37 and 38: Output the material data and parame
- Page 39 and 40: totke = totke + availkelatchi=0! Ke
- Page 41 and 42: * rhor(irl),dose(i,j,kkk),doseun(i,
- Page 43 and 44: Ifahistorynumberislessthanmaxpict,
- Page 45 and 46: 3 Exercise problems3.1 Problem 1 :
- Page 47 and 48: ! Source position from phantom surf
- Page 49 and 50: At the above data, a first 201 is t
- Page 51 and 52: &INP AE=0.521,AP=0.0100,UE=2.011,UP
- Page 53 and 54: (b) Add new material (Iron).ChangeA
- Page 55 and 56: !**********************************
- Page 57 and 58: !----------------------------------
- Page 59 and 60: faexp=0.D0faexps=0.D0faexp2s=0.D0fe
- Page 61 and 62: ! =======================if (iwatch
- Page 63 and 64: do k=kdosl(idose),kdosu(idose)do j=
- Page 65 and 66: ! Record 10a ipeangsw, Switches for
- Page 67 and 68: if (maxz.gt.LKMAX) thenwrite(ifto,'
- Page 69 and 70:
zbound(in+1)=zbound(in)+widthend do
- Page 71 and 72:
if(idosu(idgrp).le.0 .or. idosu(idg
- Page 73 and 74:
!--------------------------------if
- Page 75 and 76:
end ifend ifelse if (u(np) .lt. 0.0