anchor.diff:                i = i + 1
                 call getarg(i,tag)
                 read(tag,'(BN,F12.0)') cmdin(4)
  +          elseif (trim(tag).eq.'-debug') then
  +              debug = .true.
             elseif (tag(1:2).eq.'-p') then
                 p = 1
             elseif (tag(1:2).eq.'-s') then
  
positive.code:       PARAMETER (pi=4.0d0*datan(1.0d0),r2d=1.8d2/pi,radius=6371.0d0)
        REAL*8 lon1,lat1,lon2,lat2,dist,az,cmdin(4)
        CHARACTER*30 ifile,ofile
        INTEGER c,p,input
        LOGICAL ex
  
  C----
  C Parse command line and read options
  C----
        call gcmdln(ifile,ofile,c,cmdin,p)
  
  C----
  C Check inputs are valid
  C----
        if (c.eq.1) goto 103
        if (ifile.eq.'none') then
            write(*,*) '!! Error: Input lon1 lat1 lon2 lat2 file ',
  
negative.code: 
  C----------------------------------------------------------------------C
  
        SUBROUTINE gcmdln(ifile,ofile,c,cmdin,p,debug)
        IMPLICIT NONE
        CHARACTER*30 ifile,ofile,tag
        INTEGER i,narg,c,p
        REAL*8 cmdin(4)
        LOGICAL debug
        ifile = 'none'
        ofile = 'none'
        debug = .false.
        c = 0
        p = 1
        narg = iargc()
  