Skip to content

Commit

Permalink
Merge pull request #15 from sandipde/master
Browse files Browse the repository at this point in the history
update the code so that it can take 'vdw_corr' as input parameter
  • Loading branch information
lmmentel committed Feb 22, 2021
2 parents 91e7dc7 + c04c116 commit 77dc18c
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions espresso/espresso.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# ****************************************************************************
# Original work Copyright (C) 2013-2015 SUNCAT
# Modified work Copyright 2015-2017 Lukasz Mentel
#
# Minor Modification by Sandip De Copyleft 2021
# This file is distributed under the terms of the
# GNU General Public License. See the file 'COPYING'
# in the root directory of the present distribution,
Expand Down Expand Up @@ -502,6 +502,7 @@ def __init__(self,
w_2=None,
wmass=None,
press_conv_thr=None,
vdw_corr=None,
site=None,
):

Expand Down Expand Up @@ -674,7 +675,7 @@ def __init__(self,
self.w_2 = w_2
self.wmass = wmass
self.press_conv_thr = press_conv_thr

self.vdw_corr=vdw_corr
# internal attributes

self._initialized = False
Expand Down Expand Up @@ -1516,11 +1517,11 @@ def write_input(self, inputname='pw.inp', calculation=None,
if value is not None:
print(' {0:s}={1:s},'.format(attr, num2str(value)), file=finp)

sys_str_attrs = ['exxdiv_treatment']
sys_str_attrs = ['exxdiv_treatment','vdw_corr']
for attr in sys_str_attrs:
value = getattr(self, attr)
if value is not None:
print(' {0:s}={1:s},'.format(attr, value), file=finp)
print(" {0:s}='{1:s}',".format(attr, value), file=finp)

sys_bool_attrs = ['nosym', 'noinv', 'nosym_evc', 'no_t_rev', 'force_symmorphic',
'use_all_frac', 'one_atom_occupations', 'starting_spin_angle',
Expand Down

0 comments on commit 77dc18c

Please sign in to comment.