Subroutine MFWHMU1(ve) c ========================= c c Routine to fill the hit (LT1) part of /FWHMU/. c Starts from /MFLT1/, that is hits from LT strip clusters. c Implicit None c #include "partap.inc" #include "fwhmu.inc" #include "mflt1.inc" #include "mfsigm.inc" #include "mfgeox.inc" c real ve(3) c integer ip,io,is,jr,jp,jr1,jr2,jp1 real s2r,s2p,zeta,fi,cs,sn,pi,pi4,pi8,theta1,theta2,theta,ph, . x1,y1,z1,r1,x2,y2,z2,r2,r12,phio,vx,vy,vz c integer quad(8) data quad /1,1,2,2,3,3,4,4/ integer ipl(6),ip1(10) data ipl /1,3,4,5,7,9/ c real dr save dr logical first /.true./ save first c c if(first) then first=.false. pi=acos(-1.) pi4=pi/4. pi8=pi/8. dr=pi/180. endif c vx=ve(1) vy=ve(2) vz=ve(3) c nhmf=0 do io=1,8 phio=(io-1)*pi4+pi8 z1=ZFM(ipl(1),io) do jr1=1,nclur(io) do jp1=1,nclup(io) cs=cos(phix(jp1,io)) sn=sin(phix(jp1,io)) x1=rhox(jr1,io)*cs y1=rhox(jr1,io)*sn nhmf=nhmf+1 if(nhmf.gt.mxhm) then ccc write(6,*) 'MFWHMU1. Too many hits, array cut.' nhmf=mxhm goto 9900 endif Call mfCaPo(x1-vx,y1-vy,z1-vz,r1,theta,ph) XHMF(1,nhmf)=x1 XHMF(2,nhmf)=y1 XHMF(3,nhmf)=z1 XHMF(4,nhmf)=theta XHMF(5,nhmf)=ph XHMF(6,nhmf)=io XHMF(7,nhmf)=jr1 XHMF(8,nhmf)=jp1 s2r=drhox(jr1,io)**2/12. s2p=dphix(jr1,io)**2/12. EHMF(1,nhmf)=cs*cs*s2r+XHMF(2,nhmf)**2*s2p EHMF(2,nhmf)=sn*sn*s2r+XHMF(1,nhmf)**2*s2p EHMF(3,nhmf)=s2r*z1**2/(z1**2+rhox(jr1,io)**2)**2 EHMF(4,nhmf)=s2p enddo enddo 20 enddo 9900 return end c