Commit 86ebb042 authored by Daniel Wortmann's avatar Daniel Wortmann

Merge branch 'develop' of iffgit.fz-juelich.de:fleur/fleur into develop

parents d83bc813 2917b701
......@@ -72,9 +72,9 @@ then
cd $buildname
for file in *
do
if [ "$file" == "external" ]
if [[ "$file" == "external" ]] || [[ "$file" == "Testing" ]]
then
echo "Keeping 'external' directory"
echo "Keeping $file directory"
else
rm -r $file
fi
......
......@@ -17,10 +17,15 @@ CONTAINS
INTEGER,INTENT(in) :: nk
CLASS(t_mat),INTENT(inout) :: hmat,smat
REAL :: max_imag
!Check if we could exploit a real matrix even without inversion symmetry
realcomplex:IF (.NOT.noco%l_noco.AND..NOT.hmat%l_real) THEN
IF (ALL(ABS(kpts%bk(:,nk))<1E-10)) THEN
IF (ANY(ABS(AIMAG(hmat%data_c))>1e-10)) EXIT realcomplex
max_imag=MAXVAL(ABS(AIMAG(hmat%data_c)))
IF (max_imag>1e-10) THEN
PRINT *,"Real matrix expected but imaginary part is:",max_imag
RETURN
ENDIF
IF (mpi%irank==0) THEN
PRINT *,"Complex matrix made real"
......
......@@ -60,7 +60,6 @@ CONTAINS
d2 = SQRT(cell%omtil/cell%area)
!---> set up mapping function from 3d-->2d lapws
DO jspin = 1,input%jspins
......@@ -167,16 +166,17 @@ CONTAINS
ik = map2(i,jspin1)
DO j = 1,i
jk = map2(j,jspin2)
hij = CONJG(a(i,jspin1))* (tuuv(ik,jk)*a(j,jspin2) +tudv(ik,jk)*b(j,jspin2))&
+ CONJG(b(i,jspin1))* (tddv(ik,jk)*b(j,jspin2) +tduv(ik,jk)*a(j,jspin2))
IF (jspin2>jspin1) THEN
hij = CONJG(CONJG(a(j,jspin2))* (tuuv(jk,ik)*a(i,jspin1) +tudv(jk,ik)*b(i,jspin1))&
+ CONJG(b(j,jspin2))* (tddv(jk,ik)*b(i,jspin1) +tduv(jk,ik)*a(i,jspin1)))
ELSE
hij = CONJG(a(i,jspin1))* (tuuv(ik,jk)*a(j,jspin2) +tudv(ik,jk)*b(j,jspin2))&
+ CONJG(b(i,jspin1))* (tddv(ik,jk)*b(j,jspin2) +tduv(ik,jk)*a(j,jspin2))
ENDIF
IF (hmat(1,1)%l_real) THEN
hmat(s1,s2)%data_r(j,i0) = hmat(s1,s2)%data_r(j,i0) + REAL(hij)
ELSE
IF (s1==s2) THEN
hmat(s1,s2)%data_c(j,i0) = hmat(s1,s2)%data_c(j,i0) + hij
ELSE
hmat(s1,s2)%data_c(j,i0) = hmat(s1,s2)%data_c(j,i0) + conjg(hij)
ENDIF
hmat(s1,s2)%data_c(j,i0) = hmat(s1,s2)%data_c(j,i0) + hij
ENDIF
ENDDO
ENDDO
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment