anchor.diff:        call sdr2sdr(line,soln)
         read(soln,*) str2,dip2,rak2
         write(soln,1001) str,dip,rak,str2,dip2,rak2
  +
  +#else
  +
  +      write(0,*) 'mij2sdr: mtutil not compiled with LAPACK libraries;',
  +     1           ' returning with zeros'
  +      write(soln,1001) 0.0, 0.0, 0.0, 0.0, 0.0, 0.0
  +
  +#endif
  +
    1001 format(6F6.0)
         RETURN
         END
  
positive.code:       a(3,1) =  m(5)
        a(1,2) = -m(6)     ! mtp = -mxy
        a(1,2) = -m(6)
  C Query the optimal workspace
        lwork = -1
        call dsyev('Vectors','Upper',n,a,lda,w,work,lwork,info)
        lwork = min(lwmax,int(work(1)))
  C Solve eigenproblem
        call dsyev('Vectors','Upper',n,a,lda,w,work,lwork,info)
        p(1) = a(1,1)
        p(2) = a(2,1)
        p(3) = a(3,1)
  
negative.code:       a(3,1) =  m(5)
        a(1,2) = -m(6)     ! mtp = -mxy
        a(1,2) = -m(6)
  
  C Query the optimal workspace
        lwork = -1
        call dsyev('Vectors','Upper',n,a,lda,w,work,lwork,info)
        lwork = min(lwmax,int(work(1)))
  C Solve eigenproblem
        call dsyev('Vectors','Upper',n,a,lda,w,work,lwork,info)
  
  C Compute best-fitting focal mechanism
        do 103 i = 1,3
            p(i) = a(i,1)
  