Reduce maximum lattice motion.

Add linopt 3, which does linopt 2 when going uphill
This commit is contained in:
Kurt Glaesmann 2011-04-07 20:21:13 +00:00
parent fb61c5e591
commit 2a4a475387
8 changed files with 661621 additions and 443955 deletions

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

64
QA/tests/talc/talc4.nw Normal file
View file

@ -0,0 +1,64 @@
echo
PERMANENT_DIR /scratch/talc4
SCRATCH_DIR /scratch/talc4
#Perdikatsis B, Burzlaff H
#Zeitschrift fur Kristallographie 156 (1981) 177-186
#Strukturverfeinerung am talk Mg3[(OH)2Si4O10]
#http://rruff.geo.arizona.edu/AMS/result.php?mineral=Talc
# Change units to make life hard
geometry units bohr nocenter noautosym noautoz print
system crystal
lat_a 5.290
lat_b 9.173
lat_c 9.460
alpha 90.46
beta 98.68
gamma 90.09
end
symmetry P-1
Si 0.24527 0.50259 0.29093
Si 0.24590 0.83587 0.29108
Mg 0.00000 0.00000 0.00000
Mg 0.50012 0.83332 0.99994
O 0.19910 0.83440 0.11760
O 0.69700 0.66740 0.11260
O 0.19800 0.50120 0.11760
O 0.01990 0.92870 0.34810
O 0.52020 0.91090 0.34940
O 0.24290 0.66990 0.34840
H 0.71900 0.66900 0.20300
end
#***** setup the nwpw gamma point code ****
nwpw
energy_cutoff: 21.0d0
wavefunction_cutoff: 21.0d0
ewald_ncut: 8
lcao #old default
end
set nwpw:lcao_iterations 20
set nwpw:minimizer 2
nwpw
tolerances 1.0d-9 1.0d-9
end
driver
clear
maxiter 200
end
set includestress .true. # tell driver to optimize unit cell
set includelattice .true.
set nwpw:mulliken .false.
set cgsd:mulliken .false.
set band:mulliken .false.
set nwpw:mulliken_kawai .false.
set driver:linopt 2
# These do the same things, but in different ways
set geometry:inactlist 1:21
set nwpw:zero_forces .true.
task pspw optimize

81540
QA/tests/talc/talc4.out Normal file

File diff suppressed because it is too large Load diff

63
QA/tests/talc/talc5.nw Normal file
View file

@ -0,0 +1,63 @@
echo
PERMANENT_DIR /scratch/talc5
SCRATCH_DIR /scratch/talc5
#Perdikatsis B, Burzlaff H
#Zeitschrift fur Kristallographie 156 (1981) 177-186
#Strukturverfeinerung am talk Mg3[(OH)2Si4O10]
#http://rruff.geo.arizona.edu/AMS/result.php?mineral=Talc
# Change units to make life hard
geometry units bohr nocenter noautosym noautoz print
system crystal
lat_a 5.290
lat_b 9.173
lat_c 9.460
alpha 90.46
beta 98.68
gamma 90.09
end
symmetry P-1
Si 0.24527 0.50259 0.29093
Si 0.24590 0.83587 0.29108
Mg 0.00000 0.00000 0.00000
Mg 0.50012 0.83332 0.99994
O 0.19910 0.83440 0.11760
O 0.69700 0.66740 0.11260
O 0.19800 0.50120 0.11760
O 0.01990 0.92870 0.34810
O 0.52020 0.91090 0.34940
O 0.24290 0.66990 0.34840
H 0.71900 0.66900 0.20300
end
#***** setup the nwpw gamma point code ****
nwpw
energy_cutoff: 21.0d0
wavefunction_cutoff: 21.0d0
ewald_ncut: 8
lcao #old default
end
set nwpw:lcao_iterations 20
set nwpw:minimizer 2
nwpw
tolerances 1.0d-9 1.0d-9
end
driver
clear
maxiter 200
end
set includestress .true. # tell driver to optimize unit cell
set nwpw:mulliken .false.
set cgsd:mulliken .false.
set band:mulliken .false.
set nwpw:mulliken_kawai .false.
set driver:linopt 2
# These do the same things, but in different ways
set geometry:inactlist 1:21
set nwpw:zero_forces .true.
task pspw optimize

86647
QA/tests/talc/talc5.out Normal file

File diff suppressed because it is too large Load diff

View file

@ -130,8 +130,16 @@ c
call driver_take_step(rtdb, geom) ! Updates geom using alpha*ds
else if (linopt .eq. 1) then
call driver_line_search1(rtdb, geom) ! Updates geom,alpha
else
else if (linopt .eq. 2) then
call driver_line_search2(rtdb, geom) ! Updates geom,alpha
else
if (istep.gt.1 .and. (
> (energy-energyp) .gt. eprec .or.
> (energyp-energyp2) .gt. eprec)) then
call driver_line_search2(rtdb, geom) ! More aggressive, if uphill
else
call driver_line_search1(rtdb, geom)
endif
endif
c
c We have now taken a step. Replace the approximate step taken
@ -1786,26 +1794,27 @@ c
if (j.gt.3) j=1
dsmax = max(dsmax, abs(ds(i))*scaler(j))
enddo
! Note that the linear optimizer can increase the step size by 4X
if (ostress) then
do i = top+1,nvar
j = ((i-top)+2)/(3) ! 1,1,1,2,2,2,3,3,3
dsmax = max(dsmax, abs(ds(i)/scaler(j))*12)!2.5% max, if trust=.3
dsmax = max(dsmax, abs(ds(i)/scaler(j))*24)!1.25% max, if trust=.3
dsmax = max(dsmax, abs(ds(i)))
enddo
do i = top+1,nvar,3
j = ((i-top)+2)/(3) ! 1,1,1,2,2,2,3,3,3
dum1 = abs(ds(i))+abs(ds(i+1))+abs(ds(i+2)) ! Total change in a vector
dsmax = max(dsmax, abs(dum1/scaler(j))*9)!3.5% max, if trust=.3
dsmax = max(dsmax, abs(dum1/scaler(j))*18)!1.75% max, if trust=.3
dsmax = max(dsmax, abs(dum1))
enddo
endif
if (ostress2) then
do i = top+1,top+3! Lengths
j=i-top
dsmax = max(dsmax, abs(ds(i)/scaler(j))*6)!5% max, if trust=.3
dsmax = max(dsmax, abs(ds(i)/scaler(j))*12)!2.5% max, if trust=.3
enddo
do i = top+4,nvar ! Angles
dsmax = max(dsmax, abs(ds(i))*3.43774d0)!5 degrees max if trust=.3
dsmax = max(dsmax, abs(ds(i))*6.87548d0)!2.5 degrees max if trust=.3
enddo
endif
else