xiaoqiugood的个人博客分享 http://blog.sciencenet.cn/u/xiaoqiugood

博文

再谈保持对称性不变的优化

已有 7568 次阅读 2014-10-20 10:18 |个人分类:结构优化|系统分类:科研笔记

关注:

1) POTIM、ISIF参数的含义

2) POTIM、ISIF的配合使用保持对称性不变

 

 

 

Thanks to  Xinqiu Chen and Xiyue Li

 

1. POTIM取大一点,仍采用ISIF=3

 

 

 

2.  分两步优化,

(1) 在每个压力点下优化晶格常数,保持原子位置不动     ISIF=7

 

(2) 在每个压力点下优化原子位置,保持晶格常数不动     ISIF=2

 

 

 

或许可解决对称性自动转化问题


The following table shows the meaning of ISIF.  At the moment cell changes are only supported for  relaxations and nor fot molecular dynamics simulations.

ISIFcalculatecalculaterelaxchangechange
 forcestress tensorionscell shapecell volume
0yesnoyesnono
1yestrace only $ ^*$yesnono
2yesyesyesnono
3yesyesyesyesyes
4yesyesyesyesno
5yesyesnoyesno
6yesyesnoyesyes
7yesyesnonoyes

$ ^*$ Trace only means that only the total pressure, i.e. the line



 

(一) POTIM参数解释:

 

POTIM= [real]

Default: 
no default, must be set by userif IBRION=0 (MD)
POTIM= 0.5if IBRION=1,2,3 (relaxation)



In case IBRION=0 (MD) , POTIM specifies the time step in fs. For IBRION=1,2 or 3, POTIM serves as a scaling constant for the forces.

POTIM supplies the time step  for an ab-initio molecular dynamics (IBRION=0),

and must be entered by the user for all MD simulations.


In addition POTIM severs as a ``scaling constant'' in all minimization algorithms (quasi-Newton, conjugate gradient, and damped molecular dynamics).  Especially the Quasi-Newton algorithm is sensitive to the choice of this parameter

 

 


(二) IBRION解释

IBRION=2

A conjugate-gradient algorithm (a simple discussion of this algorithm

can be found for instance in [28]) is used to relax the ions into their instantaneous groundstate.


In the first step ions (and cell shape) are changed along the direction of the steepest descent (i.e. the direction of the calculated forces and stress tensor).

The conjugate gradient method requires a line minimization, which  is performed in several steps:

i) first  a trial step into the search direction (scaled gradients) is done, with the length of the trial step controlled by the POTIM parameter (section 6.23). Then the energy and the forces are recalculated.


ii) The approximate minimum of the total energy is calculated from a cubic  (or quadratic) interpolation  taking into account the change of the total energy and the change of the forces (3 pieces of information), then a corrector step to the approximate minimum is performed.


iii) After the corrector step the forces and energy are recalculated and  it is checked whether the forces  contain a significant component parallel to the previous search direction. If this is the case,  the line minimization is improved by further corrector steps using a variant of Brent's algorithm[28].

To summarize: In the first ionic step the forces are calculated for the initial configuration read from POSCAR , the second step is a trial (or predictor step), the third step is a corrector step. If the line minimization is sufficiently accurate in this step,  the next trial step is performed.

NSTEP: 
1initial positions
2trial step
3corrector step, i.e. positions corresponding to anticipated minimum
4trial step
5corrector step
... 



 



##################ISIF=7##################

cp  cont-120g POSCAR

for i in  1200 1100 1000 900 800

do
cat > INCAR << EOF
SYSTEM = Various- local optimisation
PREC = Accurate
ENCUT = 500.0
EDIFF = 1E-6
EDIFFG = -2E-3
#SYMPREC=1e-3
IBRION = 2
POTIM = 0.05
ISIF = 7
NSW = 100

#LSDA-plus-U
ISPIN=2
LDAU = .TRUE.
LDAUTYPE = 2
LDAUL = -1  3
LDAUU = 0.00 4.10
LDAUJ = 0.0   0.1
LDAUPRINT = 0
LMAXMIX = 6

PSTRESS = $i
ISMEAR = 1
SIGMA = 0.2
#ISYM=0
#LREAL = .FALSE.
LCHARG = FALSE
LWAVE = FALSE
EOF


# start calculation

$PARA -n $NP -machinefile .nodelists.$$ $EXEC
 
cp CONTCAR CONTCAR_$i-01
cp OSZICAR OSZICAR_$i-01
cp OUTCAR OUTCAR_$i-01
cp STDOUT STDOUT_$i-01
cp CONTCAR POSCAR

# 2nd
$PARA -n $NP -machinefile .nodelists.$$ $EXEC

cp CONTCAR CONTCAR_$i-02
cp OSZICAR OSZICAR_$i-02
cp OUTCAR OUTCAR_$i-02
cp STDOUT STDOUT_$i-02
cp CONTCAR POSCAR

#3rd
$PARA -n $NP -machinefile .nodelists.$$ $EXEC


cp CONTCAR CONTCAR_$i-03
cp OSZICAR OSZICAR_$i-03
cp OUTCAR OUTCAR_$i-03
cp STDOUT STDOUT_$i-03
cp CONTCAR POSCAR

#4th
$PARA -n $NP -machinefile .nodelists.$$ $EXEC

wait

cp CONTCAR POSCAR
mv  CONTCAR CONTCAR_$i-04
mv  OUTCAR OUTCAR_$i-04
mv OSZICAR OSZICAR_$i-04
mv STDOUT STDOUT_$i-04
done

###############ISIF=2#############

for i in  1200 1100 1000 900 800

do
cat > INCAR << EOF
SYSTEM = Various- local optimisation
PREC = Accurate
ENCUT = 500.0
EDIFF = 1E-6
EDIFFG = -2E-3
#SYMPREC=1e-3
IBRION = 2
POTIM = 0.05 【是否太小】
ISIF = 2
NSW = 100

#LSDA-plus-U
ISPIN=2
LDAU = .TRUE.
LDAUTYPE = 2
LDAUL = -1  3
LDAUU = 0.00 4.10
LDAUJ = 0.0   0.1
LDAUPRINT = 0
LMAXMIX = 6

PSTRESS = $i
ISMEAR = 1
SIGMA = 0.2
#ISYM=0
#LREAL = .FALSE.
LCHARG = FALSE
LWAVE = FALSE
EOF


cp CONTCAR_$i-04 POSCAR
# start calculation

$PARA -n $NP -machinefile .nodelists.$$ $EXEC
 
cp CONTCAR CONTCAR_$i-01
cp OSZICAR OSZICAR_$i-01
cp OUTCAR OUTCAR_$i-01
cp STDOUT STDOUT_$i-01
cp CONTCAR POSCAR

# 2nd
$PARA -n $NP -machinefile .nodelists.$$ $EXEC

cp CONTCAR CONTCAR_$i-02
cp OSZICAR OSZICAR_$i-02
cp OUTCAR OUTCAR_$i-02
cp STDOUT STDOUT_$i-02
cp CONTCAR POSCAR

#3rd
$PARA -n $NP -machinefile .nodelists.$$ $EXEC


cp CONTCAR CONTCAR_$i-03
cp OSZICAR OSZICAR_$i-03
cp OUTCAR OUTCAR_$i-03
cp STDOUT STDOUT_$i-03
cp CONTCAR POSCAR

#4th
$PARA -n $NP -machinefile .nodelists.$$ $EXEC

wait

cp CONTCAR POSCAR
mv  CONTCAR CONTCAR_$i-04
mv  OUTCAR OUTCAR_$i-04
mv OSZICAR OSZICAR_$i-04
mv STDOUT STDOUT_$i-04
done


 










https://blog.sciencenet.cn/blog-567091-837093.html

上一篇:内耗--固体中缺陷的研究
下一篇:包含gamma点的态密度及声子谱计算
收藏 IP: 221.10.91.*| 热度|

0

该博文允许注册用户评论 请点击登录 评论 (0 个评论)

数据加载中...

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-11-25 06:35

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部