anchor.diff:  m(1,3) = m(3,1)
   m(2,3) = m(3,2)
   
  -write(*,*) "Original matrix:"
  -write(*,"(3F15.8)") ((m(i,j), j=1,3),i=1,3)
  -write(*,*)
  +write(ilog,*) "Original matrix:"
  +write(ilog,"(3F15.8)") ((m(i,j), j=1,3),i=1,3)
  +write(ilog,*)
   
   ! At this point m can be either (a) inverted and diagonalized or (b) diagonalized and eigenvalues inverted.
   ! The problem with (a) is that the inverse procedure does NOT guarantee symmetric matrix as the result.
  
positive.code: ! (b):
  call DSYEV( 'V', 'U', 3, m, 3, b, WORK, size(WORK), ok )
  if (ok .eq. 0) then
      write(*,*) "Principle effective masses and directions:"
      do i=1, 3
          write(*,"(A25,F10.2)") "Effective mass:", 1.0D0/b(i)
          write(*,"(A25,3F10.6)") "Cartesian coordinate:", (m(j,i), j=1,3)
          v = real_cart2fract(f, m(i,:))
          call normal(v,3)
          write(*,"(A25,3F10.3)") "Direct lattice vectors:", (v(j), j=1,3)
      end do
  else
      write (*,*) "INFO from DGEEV: ", ok
  endif
  
  end program
  
negative.code: integer(kind=4) :: itrash, count, nbands, band, A(4)
  character(len=1) :: prg
  external :: DSYEV
  
  open(unit=ilog,file='emc_calc.log',form='formatted')
  write(ilog,*) "Effective Mass Calculator calculator ", version_number
  write(ilog,*)
  
  ! read input ########################################################
  
  