C-----------------------------------------------------------------------------
      SUBROUTINE RBOTM 
C-----------------------------------------------------------------------------
C     RECEIVER MODEL USING FIXED OFFSET TO TERRAIN HEIGHT
C     COMMON DECK "RKAM" INSERTED HERE                   
      implicit double precision (a-h,o-z)
      DOUBLE PRECISION KR,KTH,KPH
      COMMON//R,TH,PH,KR,KTH,KPH,RKVARS(14),TPULSE,CSTEP,DRDT(20) 
      COMMON/WW/ dum(10), MAXW,W(1000)
C     RECEIVER HEIGHT   275-299          
      EQUIVALENCE (W(275),RMODEL),(W(276),RFORM),(W(277),RID) 
C     COMMON DECK "RR" INSERTED HERE       
      DOUBLE PRECISION MODREC
      COMMON/RR/ MODREC(4)                 
      COMMON/RR/F,PFR,PFRR,PFRTH,PFRPH     
      COMMON/RR/PFTH,PFPH,PFTHTH,PFPHPH,PFTHPH,FSELECT,FTIME  
C     COMMON DECK "GG" INSERTED HERE 
      DOUBLE PRECISION MODG
      COMMON/GG/MODG(4)              
      COMMON/GG/G,PGR,PGRR,PGRTH,PGRPH
      COMMON/GG/PGTH,PGPH,PGTHTH,PGPHPH,PGTHPH,GSELECT,GTIME   
C     COMMON DECK "B8" INSERTED HERE                           
      INTEGER RMX,RNTBL,RITBL,RFRMTBL,IDSR(10)                 
      COMMON/B8/RMX,RNTBL(10),RITBL(10),RFRMTBL(10),RGP(10)    
      EQUIVALENCE (RGP,IDSR)                                   
      INTEGER RPX    ,RQTBL(10),RLTBL(10),RIRMTBL(10)          
      DATA RPX/1/         
      DATA RQTBL/1,11,8*0/
      DATA RLTBL/1,9*0/   
      DATA RIRMTBL/1,9*0/ 
      DATA RECORR/2.0/    
C                         
      ENTRY SETRCV        
      RMX=RPX                           
      CALL IMOVE(RNTBL,RQTBL,10)        
      CALL IMOVE(RITBL,RLTBL,10)        
      CALL IMOVE(RFRMTBL,RIRMTBL,10)    
      RETURN               
C                          
      ENTRY IRECVR                        
      IF(W(275) .NE. 2.) THEN
           PRINT*,' Model check number mismatch: '
           STOP ' W(275) should be 2 if you are using model RBOTM.'
      ENDIF

      MODREC(1)=5HRBOTM                                
      MODREC(2)= w(277)
      RETURN                                           
C                                                      
      ENTRY RECEVER                       
C     GET CURRENT TERRAIN HEIGHT(MUST USE GET1 TO AVOID RECURSION
C     SINCE WE ARE PROBABLY BEING CALLED BY GET RIGHT NOW)    
      F=GET1(G)-W(20)                     
      CALL RMOVE(PFR,PGR,9)               
      END                                 
