again changes in the output [Gerardo]

git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@1072 c92efa57-630b-4861-b058-cf58834340f0
This commit is contained in:
ballabio 2004-07-14 15:32:56 +00:00
parent e4c3aded3a
commit 91b6ca3e71
3 changed files with 34 additions and 1 deletions

View File

@ -79,8 +79,9 @@ subroutine dynmatrix
! if only one mode is computed write the dynamical matrix and stop
!
if (iswitch.eq. - 4) then
WRITE( stdout, '(/,5x,"Dynamical matrix:")')
do nu = 1, 3 * nat
WRITE( stdout, '(2i5,2f10.6)') modenum, nu, dyn (modenum, nu)
WRITE( stdout, '(5x,2i5,2f10.6)') modenum, nu, dyn (modenum, nu)
enddo
call stop_ph (.false.)

View File

@ -363,6 +363,31 @@ function check_key()
}
}
# check passed
return 1;
}
else if (key == "DYNMAT")
{
tolerance = 2e-2;
# number of lines must match
if (i1 != i2)
return 0;
# all pairs of lines must match
for (j=0; j<i1; j++)
{
# all components must match
split(line1[j], x1);
split(line2[j], x2);
for (k=5; k<=6; k++)
{
delta = x1[k] - x2[k];
if (delta*delta > tolerance*tolerance)
return 0;
}
}
# check passed
return 1;
}

View File

@ -148,6 +148,13 @@ function check_line()
{
print_key("OMEGA");
}
else if (match($0, "Dynamical matrix:"))
{
print;
while (getline && NF > 0)
print_key("DYNMAT");
print;
}
else if (match($0, "atom.*type.*force ="))
{
print_key("FORCE");