Subroutine FWMIPS(ve) C ====================== C C This routine does call Island and CalMip to look for CAL MIPS, C if `CalMipCall' is set to 1 (see routine MFMPAR), otherwise C if .true. it is assumed that the calls are done elsewhere and the C common /CALMIPC/ is properly filled. C It then looks for Mips that are `forward', `barrel' and `rear'. C Implicit None #include "calmipc.inc" #include "fwmip.inc" #include "mfflg.inc" C real ve(3) c real rd /57.29577950/ real twopi /6.283185308/ save rd,twopi c-- real ThetaMipLim(2) data ThetaMipLim /36.7,129.1/ save ThetaMipLim c-- real ThetaMip,RMip integer i,jz c c--- islands [check if to-be-called] if(CalMipCall.gt.0) then Call CellFill Call Island Call IslFill Call CalMip endif c nmip(1)=0 nmip(2)=0 nmip(3)=0 c do 10 i=1,nCalMip RMip=sqrt(xCalMip(i)**2+yCalMip(i)**2+zCalMip(i)**2) ThetaMip=acos(zCalMip(i)/RMip)*rd if(ThetaMip.lt.ThetaMipLim(1)) then jz=1 elseif(ThetaMip.lt.ThetaMipLim(2)) then jz=2 else jz=3 endif if(nmip(jz).lt.nmipMax) then nmip(jz)=nmip(jz)+1 xmip(nmip(jz),jz)=xCalMip(i) ymip(nmip(jz),jz)=yCalMip(i) zmip(nmip(jz),jz)=zCalMip(i) idmip(nmip(jz),jz)=i imipused(nmip(jz),jz)=0 call mfcapo(xCalMip(i)-ve(1), & yCalMip(i)-ve(2), & zCalMip(i)-ve(3), & RMip, & thmip(nmip(jz),jz), & phmip(nmip(jz),jz)) endif 10 continue C 9900 continue if(Mdebug.gt.0) then Write(6,*) 'FWMIPS. CalMips: ',nmip endif C End C