Skip to content

Commit

Permalink
gamma line calculation for bcc and fcc (#801)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinwenminion authored Aug 3, 2022
1 parent cf6bdf2 commit a78f8a5
Show file tree
Hide file tree
Showing 38 changed files with 39,281 additions and 9 deletions.
384 changes: 384 additions & 0 deletions dpgen/auto_test/Gamma.py

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dpgen/auto_test/Lammps.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ def make_input_file(self,

# dumpfn(task_param, os.path.join(output_dir, 'task.json'), indent=4)

etol = 1e-12
ftol = 1e-6
etol = 0
ftol = 1e-10
maxiter = 5000
maxeval = 500000
B0 = 70
Expand Down
17 changes: 10 additions & 7 deletions dpgen/auto_test/common_prop.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from dpgen.auto_test.Interstitial import Interstitial
from dpgen.auto_test.Surface import Surface
from dpgen.auto_test.Vacancy import Vacancy
from dpgen.auto_test.Gamma import Gamma
from dpgen.auto_test.calculator import make_calculator
from dpgen.dispatcher.Dispatcher import make_dispatcher
from dpgen.dispatcher.Dispatcher import make_submission
Expand All @@ -19,21 +20,23 @@
lammps_task_type = ['deepmd', 'meam', 'eam_fs', 'eam_alloy']


def make_property_instance(paramters):
def make_property_instance(parameters):
"""
Make an instance of Property
"""
prop_type = paramters['type']
prop_type = parameters['type']
if prop_type == 'eos':
return EOS(paramters)
return EOS(parameters)
elif prop_type == 'elastic':
return Elastic(paramters)
return Elastic(parameters)
elif prop_type == 'vacancy':
return Vacancy(paramters)
return Vacancy(parameters)
elif prop_type == 'interstitial':
return Interstitial(paramters)
return Interstitial(parameters)
elif prop_type == 'surface':
return Surface(paramters)
return Surface(parameters)
elif prop_type == 'gamma':
return Gamma(parameters)
else:
raise RuntimeError(f'unknown property type {prop_type}')

Expand Down
13 changes: 13 additions & 0 deletions tests/auto_test/confs/hp-Mo/POSCAR
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Mo2
1.0000000000000000
3.1623672675177916 -0.0000000000000000 -0.0000000000000000
-0.0000000000000000 3.1623672675177916 -0.0000000000000000
0.0000000000000000 0.0000000000000000 3.1623672675177916
Mo
2
Direct
0.0000000000000000 0.0000000000000000 0.0000000000000000
0.5000000000000000 0.5000000000000000 0.5000000000000000

0.00000000E+00 0.00000000E+00 0.00000000E+00
0.00000000E+00 0.00000000E+00 0.00000000E+00
10 changes: 10 additions & 0 deletions tests/auto_test/equi/vasp/CONTCAR_Mo_bcc
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Mo2
1.0
3.1617699325125632e+00 0.0000000000000000e+00 0.0000000000000000e+00
-2.9607253805968378e-17 3.1617699325125632e+00 0.0000000000000000e+00
-6.1517551630255350e-18 -4.3742379676789617e-17 3.1617699325125632e+00
Mo
2
Cartesian
0.0000000000 0.0000000000 0.0000000000
1.5808849663 1.5808849663 1.5808849663
1 change: 1 addition & 0 deletions tests/auto_test/output/gamma_00/POSCAR
38 changes: 38 additions & 0 deletions tests/auto_test/output/gamma_00/in.lammps
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
clear
units metal
dimension 3
boundary p p p
atom_style atomic
box tilt large
read_data conf.lmp
mass 1 95.940
neigh_modify every 1 delay 0 check no
pair_style deepmd frozen_model.pb
pair_coeff * *
compute mype all pe
thermo 100
thermo_style custom step pe pxx pyy pzz pxy pxz pyz lx ly lz vol c_mype
dump 1 all custom 100 dump.relax id type xs ys zs fx fy fz
min_style cg
fix 1 all setforce 0 0 NULL
minimize 0.000000e+00 1.000000e-10 5000 500000
variable N equal count(all)
variable V equal vol
variable E equal "c_mype"
variable tmplx equal lx
variable tmply equal ly
variable Pxx equal pxx
variable Pyy equal pyy
variable Pzz equal pzz
variable Pxy equal pxy
variable Pxz equal pxz
variable Pyz equal pyz
variable Epa equal ${E}/${N}
variable Vpa equal ${V}/${N}
variable AA equal (${tmplx}*${tmply})
print "All done"
print "Total number of atoms = ${N}"
print "Final energy per atoms = ${Epa}"
print "Final volume per atoms = ${Vpa}"
print "Final Base area = ${AA}"
print "Final Stress (xx yy zz xy xz yz) = ${Pxx} ${Pyy} ${Pzz} ${Pxy} ${Pxz} ${Pyz}"
Loading

0 comments on commit a78f8a5

Please sign in to comment.