...
 
Commits (2)
# UtilXlib UnitTesting
build:cudampiomp:
tags: [galileo]
......@@ -70,7 +69,7 @@ build:intel:
tags: [galileo]
script:
- module purge
- module load intel/pe-xe-2017--binary intelmpi/2017--binary mkl/2017--binary
- module load intel/pe-xe-2018--binary intelmpi/2018--binary mkl/2018--binary
- module list
- ./configure --enable-openmp
- make pw cp
......
......@@ -46,7 +46,7 @@
<tr><th style="margin: 3 3 3 10; background: #005789; background: linear-gradient(rgba(0,87,137,1),rgba(0,119,189,1)); color: #ffffee; ">
<h1 style="margin: 10 10 10 15; text-align: left;"> Input File Description </h1>
<h2 style="margin: 10 10 10 15; text-align: left;"> Program:
cp.x / CP / Quantum Espresso<span style="font-weight: normal;"> (version: svn)</span>
cp.x / CP / Quantum Espresso<span style="font-weight: normal;"> (version: 6.4)</span>
</h2>
</th></tr>
<tr><td style="padding: 10 3 3 3; background: #ffffff; color: #222222; ">
......@@ -586,7 +586,8 @@ See also etot_conv_thr - both criteria must be satisfied.
</td>
</tr>
<tr><td align="left" valign="top" colspan="2"><blockquote><pre style="margin-bottom: -1em;">
'small': memory-saving tricks are implemented. Currently:
'small': NO LONGER IMPLEMENTED SINCE v.6.3
memory-saving tricks are implemented. Currently:
- the G-vectors are sorted only locally, not globally
- they are not collected and written to file
For large systems, the memory and time gain is sizable
......@@ -3938,7 +3939,7 @@ ENDRULES
</td></tr>
</table>
<small>
This file has been created by helpdoc utility on Tue Oct 23 15:42:16 CEST 2018.
This file has been created by helpdoc utility on Fri Mar 01 17:56:47 CET 2019.
</small>
</body>
</html>
......@@ -3,7 +3,7 @@
------------------------------------------------------------------------
INPUT FILE DESCRIPTION
Program: cp.x / CP / Quantum Espresso (version: svn)
Program: cp.x / CP / Quantum Espresso (version: 6.4)
------------------------------------------------------------------------
......@@ -311,7 +311,8 @@ NAMELIST: &CONTROL
Type: CHARACTER
Default: 'default'
Description: 'small': memory-saving tricks are implemented. Currently:
Description: 'small': NO LONGER IMPLEMENTED SINCE v.6.3
memory-saving tricks are implemented. Currently:
- the G-vectors are sorted only locally, not globally
- they are not collected and written to file
For large systems, the memory and time gain is sizable
......@@ -2490,4 +2491,4 @@ CARD: AUTOPILOT
===END OF CARD==========================================================
This file has been created by helpdoc utility on Tue Oct 23 15:42:16 CEST 2018
This file has been created by helpdoc utility on Fri Mar 01 17:56:47 CET 2019
......@@ -46,7 +46,7 @@
<tr><th style="margin: 3 3 3 10; background: #005789; background: linear-gradient(rgba(0,87,137,1),rgba(0,119,189,1)); color: #ffffee; ">
<h1 style="margin: 10 10 10 15; text-align: left;"> Input File Description </h1>
<h2 style="margin: 10 10 10 15; text-align: left;"> Program:
cppp.x / CP / Quantum Espresso<span style="font-weight: normal;"> (version: svn)</span>
cppp.x / CP / Quantum Espresso<span style="font-weight: normal;"> (version: 6.4)</span>
</h2>
</th></tr>
<tr><td style="padding: 10 3 3 3; background: #ffffff; color: #222222; ">
......@@ -406,7 +406,7 @@ to be read and plotted
</td></tr>
</table>
<small>
This file has been created by helpdoc utility on Fri Jun 22 17:11:00 CEST 2018.
This file has been created by helpdoc utility on Fri Mar 01 17:56:48 CET 2019.
</small>
</body>
</html>
......@@ -3,7 +3,7 @@
------------------------------------------------------------------------
INPUT FILE DESCRIPTION
Program: cppp.x / CP / Quantum Espresso (version: svn)
Program: cppp.x / CP / Quantum Espresso (version: 6.4)
------------------------------------------------------------------------
......@@ -225,4 +225,4 @@ NAMELIST: &INPUTPP
===END OF NAMELIST======================================================
This file has been created by helpdoc utility on Fri Jun 22 17:10:59 CEST 2018
This file has been created by helpdoc utility on Fri Mar 01 17:56:48 CET 2019
VERSION = svn
VERSION = git
HELPDOC = ../../dev-tools/helpdoc -version $(VERSION)
LATEX = pdflatex
LATEX2HTML = latex2html
......
No preview for this file type
\documentclass[12pt,a4paper]{article}
\def\version{6.3}
\def\version{6.4}
\def\qe{{\sc Quantum ESPRESSO}}
\usepackage{html}
......@@ -124,16 +124,18 @@ Symlinks to executable programs will be placed in the \texttt{bin/} subdirectory
As a final check that compilation was successful,
you may want to run some or all of the tests
and examples. Please see the general User's Guide for their setup. Automated tests for \cpx\ are in directory
\texttt{tests/} and can be run via the
script \texttt{check\_cp.x.j}
and examples.
Automated tests for \cpx\ are in directory
\texttt{test-suite/} and can be run via the
\texttt{Makefile} found there.
Please see the general User's Guide for their setup.
You may take the tests and examples distributed
with \CP\ as templates for writing your own input
files. Input files for tests are contained
in \texttt{tests/} subdirectory with file type
\texttt{*.in1}, \texttt{*.in2}, ... . Input file for examples
are produced if you run the examples in the
files. Input files for tests are contained in
subdirectories \texttt{test-suite/cp\_*} with file type
\texttt{*.in1}, \texttt{*.in2}, ... . Input files for examples
are produced, if you run the examples, in the
\texttt{results/} subdirectories, with names ending
with \texttt{.in}.
......
This example shows how to use cp.x together with pw.x
to perform an electronic minimization at Gamma for SiO2.
Note that "prefix" for pw.x = "prefix"_"ndr" or "prefix_ndw" for cp.x
Note that
- it works only for Gamma point, of course
- it is no longer needed to set "wf_collect" to .t.
- the number of bands should be the same for CP and PW
- "prefix" for pw.x = "prefix"_"ndr" or "prefix_ndw" for cp.x
......@@ -145,7 +145,6 @@ cat > sio2.pw.restart.in << EOF
prefix = 'cp_91'
pseudo_dir='$PSEUDO_DIR/',
outdir='$TMP_DIR/',
wf_collect = .true.
/
&system
ibrav=8, celldm(1)=9.28990, celldm(2)=1.73206, celldm(3)=1.09955,
......
......@@ -109,7 +109,7 @@ cat > sio2.cp.start.in << EOF
ATOMIC_SPECIES
O 16.00 O.pz-rrkjus.UPF
Si 28.00 Si.pz-vbc.UPF
ATOMIC_POSITIONS
ATOMIC_POSITIONS bohr
O 3.18829368 14.83237039 1.22882961
O 7.83231469 6.78704039 1.22882961
O 2.07443467 5.99537992 4.73758250
......@@ -163,7 +163,7 @@ cat > sio2.cp.restart.in << EOF
ATOMIC_SPECIES
O 16.00 O.pz-rrkjus.UPF
Si 28.00 Si.pz-vbc.UPF
ATOMIC_POSITIONS
ATOMIC_POSITIONS bohr
O 3.18829368 14.83237039 1.22882961
O 7.83231469 6.78704039 1.22882961
O 2.07443467 5.99537992 4.73758250
......@@ -222,7 +222,7 @@ cat > sio2.vc-cp.in << EOF
ATOMIC_SPECIES
O 16.00 O.pz-rrkjus.UPF
Si 28.00 Si.pz-vbc.UPF
ATOMIC_POSITIONS
ATOMIC_POSITIONS bohr
O 3.18829368 14.83237039 1.22882961
O 7.83231469 6.78704039 1.22882961
O 2.07443467 5.99537992 4.73758250
......@@ -281,7 +281,7 @@ cat > sio2.vc-cp.restart.in << EOF
ATOMIC_SPECIES
O 16.00 O.pz-rrkjus.UPF
Si 28.00 Si.pz-vbc.UPF
ATOMIC_POSITIONS
ATOMIC_POSITIONS bohr
O 3.18829368 14.83237039 1.22882961
O 7.83231469 6.78704039 1.22882961
O 2.07443467 5.99537992 4.73758250
......
This diff is collapsed.
#!/bin/sh
# run from directory where this script is
cd `echo $0 | sed 's/\(.*\)\/.*/\1/'` # extract pathname
EXAMPLE_DIR=`pwd`
# check whether echo has the -e option
if test "`echo -e`" = "-e" ; then ECHO=echo ; else ECHO="echo -e" ; fi
$ECHO
$ECHO "$EXAMPLE_DIR : starting"
$ECHO
$ECHO "This example shows how to use cp.x to calculate Wannier functions and"
$ECHO "to perform dynamics with an external electric field."
# set the needed environment variables
. ../../../../environment_variables
# required executables and pseudopotentials
BIN_LIST="cp.x"
PSEUDO_LIST="H_US.van O_US.van"
$ECHO
$ECHO " executables directory: $BIN_DIR"
$ECHO " pseudo directory: $PSEUDO_DIR"
$ECHO " temporary directory: $TMP_DIR"
$ECHO
$ECHO " checking that needed directories and files exist...\c"
# check for directories
for DIR in "$BIN_DIR" "$PSEUDO_DIR" ; do
if test ! -d $DIR ; then
$ECHO
$ECHO "ERROR: $DIR not existent or not a directory"
$ECHO "Aborting"
exit 1
fi
done
for DIR in "$TMP_DIR" "$EXAMPLE_DIR/results" ; do
if test ! -d $DIR ; then
mkdir $DIR
fi
done
cd $EXAMPLE_DIR/results
# check for executables
for FILE in $BIN_LIST ; do
if test ! -x $BIN_DIR/$FILE ; then
$ECHO
$ECHO "ERROR: $BIN_DIR/$FILE not existent or not executable"
$ECHO "Aborting"
exit 1
fi
done
# check for pseudopotentials
for FILE in $PSEUDO_LIST ; do
if test ! -r $PSEUDO_DIR/$FILE ; then
$ECHO
$ECHO "Downloading $FILE to $PSEUDO_DIR...\c"
$WGET $PSEUDO_DIR/$FILE \
http://www.quantum-espresso.org/pseudo/1.3/UPF/$FILE 2> /dev/null
fi
if test $? != 0; then
$ECHO
$ECHO "ERROR: $PSEUDO_DIR/$FILE not existent or not readable"
$ECHO "Aborting"
exit 1
fi
done
$ECHO " done"
# how to run executables
CP_COMMAND="$PARA_PREFIX $BIN_DIR/cp.x $PARA_POSTFIX"
$ECHO
$ECHO " running cp.x as: $CP_COMMAND"
$ECHO
# clean TMP_DIR
$ECHO " cleaning $TMP_DIR...\c"
rm -rf $TMP_DIR/*
$ECHO " done"
cat > h2o.wannier.xml << EOF
<?xml version="1.0" encoding="UTF-8"?>
<input calculation="cp-wf" prefix="h2o_mol">
<cell type="qecell">
<qecell ibrav="1" alat="20.0">
<real rank="1" n1="5">
0.0 0.0 0.0 0.0 0.0
</real>
</qecell>
</cell>
<atomic_species ntyp="2">
<specie name="O">
<property name="mass">
<real>16.D0</real>
</property>
<property name="pseudofile">
<string>O_US.van</string>
</property>
</specie>
<specie name="H">
<property name="mass">
<real>2.D0</real>
</property>
<property name="pseudofile">
<string>H_US.van</string>
</property>
</specie>
</atomic_species>
<atomic_list units="bohr" nat="3" >
<atom name="O">
<position>
<real rank="1" n1="3">
10.0000 10.0000 10.000
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
11.7325 9.6757 10.000
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
9.6757 11.7325 10.000
</real>
</position>
</atom>
</atomic_list>
<field name="InputOutput">
<parameter name="pseudo_dir">
<string>
$PSEUDO_DIR/
</string>
</parameter>
<parameter name="outdir">
<string>
$TMP_DIR/
</string>
</parameter>
<parameter name="restart_mode">
<string>
from_scratch
</string>
</parameter>
<parameter name="iprint">
<integer>
100
</integer>
</parameter>
</field>
<field name="Numerics">
<parameter name="ecutwfc">
<real>
25.D0
</real>
</parameter>
<parameter name="etot_conv_thr">
<real>
1.D-16
</real>
</parameter>
</field>
<field name="CP">
<!--nstep, dt e ion_dynamics esistono anche nel PW ma nn sapevo in che field metterli -->
<parameter name="nstep">
<integer>
100
</integer>
</parameter>
<parameter name="dt">
<real>
4.D0
</real>
</parameter>
<parameter name="ion_dynamics">
<string>
none
</string>
</parameter>
<!-- Da qui in poi esistono solo in CP-->
<parameter name="isave">
<integer>
100
</integer>
</parameter>
<parameter name="nr1b">
<integer>
10
</integer>
</parameter>
<parameter name="nr2b">
<integer>
10
</integer>
</parameter>
<parameter name="nr3b">
<integer>
10
</integer>
</parameter>
<parameter name="electron_dynamics">
<string>
damp
</string>
</parameter>
<parameter name="electron_damping">
<real>
0.15
</real>
</parameter>
<parameter name="emass">
<real>
350.D0
</real>
</parameter>
<parameter name="emass_cutoff">
<real>
3.D0
</real>
</parameter>
<parameter name="ortho_eps">
<real>
5.D-8
</real>
</parameter>
<parameter name="ortho_max">
<integer>
250
</integer>
</parameter>
<parameter name="ekin_conv_thr">
<real>
1.D-16
</real>
</parameter>
<parameter name="adapt">
<logical>
TRUE
</logical>
</parameter>
<parameter name="nsteps">
<integer>
10
</integer>
</parameter>
</field>
</input>
EOF
$ECHO " running the Wannier functions calculation...\c"
$CP_COMMAND < h2o.wannier.xml > h2o.wannier.out
check_failure $?
$ECHO " Wannier functions spreads...\c">> h2o.wannier.out
$ECHO "">> h2o.wannier.out
tail -4 $TMP_DIR/h2o_mol.spr >> h2o.wannier.out
$ECHO " Wannier functions centers...\c">> h2o.wannier.out
$ECHO "">> h2o.wannier.out
tail -4 $TMP_DIR/h2o_mol.wfc >> h2o.wannier.out
$ECHO " done"
# calculation with an electric field
cat > h2o.efield.xml << EOF
<?xml version="1.0" encoding="UTF-8"?>
<input calculation="cp-wf" prefix="h2o_mol">
<cell type="qecell">
<qecell ibrav="1" alat="20.0">
<real rank="1" n1="5">
0.0 0.0 0.0 0.0 0.0
</real>
</qecell>
</cell>
<atomic_species ntyp="2">
<specie name="O">
<property name="mass">
<real>16.D0</real>
</property>
<property name="pseudofile">
<string>O_US.van</string>
</property>
</specie>
<specie name="H">
<property name="mass">
<real>2.D0</real>
</property>
<property name="pseudofile">
<string>H_US.van</string>
</property>
</specie>
</atomic_species>
<atomic_list units="bohr" nat="3" >
<atom name="O">
<position>
<real rank="1" n1="3">
10.0000 10.0000 10.000
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
11.7325 9.6757 10.000
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
9.6757 11.7325 10.000
</real>
</position>
</atom>
</atomic_list>
<field name="InputOutput">
<parameter name="pseudo_dir">
<string>
$PSEUDO_DIR/
</string>
</parameter>
<parameter name="outdir">
<string>
$TMP_DIR/
</string>
</parameter>
<parameter name="restart_mode">
<string>
reset_counters
</string>
</parameter>
<parameter name="iprint">
<integer>
100
</integer>
</parameter>
</field>
<field name="Numerics">
<parameter name="ecutwfc">
<real>
25.D0
</real>
</parameter>
</field>
<field name="CP">
<!--nstep, dt e ion_dynamics esistono anche nel PW ma nn sapevo in che field metterli -->
<parameter name="nstep">
<integer>
200
</integer>
</parameter>
<parameter name="dt">
<real>
6.D0
</real>
</parameter>
<parameter name="ion_dynamics">
<string>
verlet
</string>
</parameter>
<!-- Da qui in poi esistono solo in CP-->
<parameter name="isave">
<integer>
100
</integer>
</parameter>
<parameter name="nr1b">
<integer>
10
</integer>
</parameter>
<parameter name="nr2b">
<integer>
10
</integer>
</parameter>
<parameter name="nr3b">
<integer>
10
</integer>
</parameter>
<parameter name="electron_dynamics">
<string>
verlet
</string>
</parameter>
<parameter name="emass">
<real>
350.D0
</real>
</parameter>
<parameter name="emass_cutoff">
<real>
3.D0
</real>
</parameter>
<parameter name="ndw">
<integer>
51
</integer>
</parameter>
<parameter name="ortho_eps">
<real>
5.D-8
</real>
</parameter>
<parameter name="ortho_max">
<integer>
250
</integer>
</parameter>
<parameter name="wf_efield">
<logical>
TRUE
</logical>
</parameter>
<parameter name="wf_switch">
<logical>
TRUE
</logical>
</parameter>
<parameter name="sw_len">
<integer>
100
</integer>
</parameter>
<parameter name="efz1">
<real>
0.5D-2
</real>
</parameter>
</field>
</input>
EOF
$ECHO " running the calculation with electric field...\c"
$CP_COMMAND < h2o.efield.xml > h2o.efield.out
check_failure $?
$ECHO
$ECHO "$EXAMPLE_DIR: done"
This diff is collapsed.
#!/bin/sh
# run from directory where this script is
cd `echo $0 | sed 's/\(.*\)\/.*/\1/'` # extract pathname
EXAMPLE_DIR=`pwd`
# check whether echo has the -e option
if test "`echo -e`" = "-e" ; then ECHO=echo ; else ECHO="echo -e" ; fi
$ECHO
$ECHO "$EXAMPLE_DIR : starting"
$ECHO
$ECHO "This example shows how to use cp.x to perform SCF"
$ECHO "simulation of C4H6 with TPSS metaGGA Exc."
# set the needed environment variables
. ../../../environment_variables
# required executables and pseudopotentials
BIN_LIST="cp.x "
PSEUDO_LIST="C.tpss-mt.UPF H.tpss-mt.UPF"
$ECHO
$ECHO " executables directory: $BIN_DIR"
$ECHO " pseudo directory: $PSEUDO_DIR"
$ECHO " temporary directory: $TMP_DIR"
$ECHO " checking that needed directories and files exist...\c"
# check for directories
for DIR in "$BIN_DIR" "$PSEUDO_DIR" ; do
if test ! -d $DIR ; then
$ECHO
$ECHO "ERROR: $DIR not existent or not a directory"
$ECHO "Aborting"
exit 1
fi
done
for DIR in "$TMP_DIR" "$EXAMPLE_DIR/results" ; do
if test ! -d $DIR ; then
mkdir $DIR
fi
done
cd $EXAMPLE_DIR/results
# check for executables
for FILE in $BIN_LIST ; do
if test ! -x $BIN_DIR/$FILE ; then
$ECHO
$ECHO "ERROR: $BIN_DIR/$FILE not existent or not executable"
$ECHO "Aborting"
exit 1
fi
done
# check for pseudopotentials
for FILE in $PSEUDO_LIST ; do
if test ! -r $PSEUDO_DIR/$FILE ; then
$ECHO
$ECHO "Downloading $FILE to $PSEUDO_DIR...\c"
$WGET $PSEUDO_DIR/$FILE \
http://www.quantum-espresso.org/pseudo/1.3/UPF/$FILE 2> /dev/null
fi
if test $? != 0; then
$ECHO
$ECHO "ERROR: $PSEUDO_DIR/$FILE not existent or not readable"
$ECHO "Aborting"
exit 1
fi
done
$ECHO " done"
# how to run executables
CP_COMMAND="$PARA_PREFIX $BIN_DIR/cp.x $PARA_POSTFIX"
$ECHO
$ECHO " running cp.x as: $CP_COMMAND"
$ECHO
# clean TMP_DIR
$ECHO " cleaning $TMP_DIR...\c"
rm -rf $TMP_DIR/*
$ECHO " done"
# molecular dynamics calculation
cat > c4h6.cp.metaGGA.xml << EOF
<?xml version="1.0" encoding="UTF-8"?>
<input calculation="scf">
<cell type="qecell">
<qecell ibrav="1" alat="8.00">
<real rank="1" n1="5">
0.0 0.0 0.0 0.0 0.0
</real>
</qecell>
</cell>
<atomic_species ntyp="2">
<specie name="H">
<property name="mass">
<real>1.007825035</real>
</property>
<property name="pseudofile">
<string>H.tpss-mt.UPF</string>
</property>
</specie>
<specie name="C">
<property name="mass">
<real>12.00</real>
</property>
<property name="pseudofile">
<string>C.tpss-mt.UPF</string>
</property>
</specie>
</atomic_species>
<atomic_list units="bohr" nat="10" >
<atom name="H">
<position>
<real rank="1" n1="3">
-0.271695E+01 -0.245822E+01 0.236174E+01
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
-0.291292E+01 0.249129E+01 0.952936E+00
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
0.203629E+01 -0.270414E+01 -0.104887E+01
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
0.310911E+01 -0.162987E+01 0.189331E+01
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
0.244815E+01 0.263846E+01 0.332670E+00
</real>
</position>
</atom>
<atom name="H">
<position>
<real rank="1" n1="3">
0.940835E+00 0.160187E+01 -0.258377E+01
</real>
</position>
</atom>
<atom name="C">
<position>
<real rank="1" n1="3">
-0.121505E+01 -0.130902E+01 0.131661E+01
</real>
</position>
</atom>
<atom name="C">
<position>
<real rank="1" n1="3">
-0.136126E+01 0.116614E+01 0.825189E+00
</real>
</position>
</atom>
<atom name="C">
<position>
<real rank="1" n1="3">
0.154872E+01 -0.143358E+01 0.510627E+00
</real>
</position>
</atom>
<atom name="C">
<position>
<real rank="1" n1="3">
0.109484E+01 0.137081E+01 -0.496954E+00
</real>
</position>
</atom>
</atomic_list>
<field name="InputOutput">
<parameter name="pseudo_dir">
<string>
$PSEUDO_DIR/
</string>
</parameter>
<parameter name="outdir">
<string>
$TMP_DIR/
</string>
</parameter>
<parameter name="restart_mode">
<string>
from_scratch
</string>
</parameter>
<parameter name="iprint">
<integer>
100
</integer>
</parameter>
<parameter name="tprnfor">
<logical>
TRUE
</logical>
</parameter>
<parameter name="tstress">
<logical>
TRUE
</logical>
</parameter>
</field>
<field name="Numerics">
<parameter name="ecutwfc">
<real>
30.0
</real>
</parameter>
</field>
<field name="Options">
<parameter name="nbnd">
<integer>
11
</integer>
</parameter>
</field>
<field name="CP">
<!--nstep e dt esistono anche nel PW ma nn sapevo in che field metterli -->
<parameter name="nstep">
<integer>
500
</integer>
</parameter>
<parameter name="dt">
<real>
4.0
</real>
</parameter>
<!-- Da qui in poi esistono solo in CP-->
<parameter name="isave">
<integer>
500
</integer>
</parameter>
<parameter name="nr1b">
<integer>
10
</integer>
</parameter>
<parameter name="nr2b">
<integer>
10
</integer>
</parameter>
<parameter name="nr3b">
<integer>
10
</integer>
</parameter>
<parameter name="electron_dynamics">
<string>
damp
</string>
</parameter>
<parameter name="electron_damping">
<real>
0.15D0
</real>
</parameter>
<parameter name="emass">
<real>
350.D0
</real>
</parameter>
<parameter name="emass_cutoff">
<real>
2.5D0
</real>
</parameter>
</field>
</input>
EOF
$ECHO " running the cp.x SCF calculation...\c"
$CP_COMMAND < c4h6.cp.metaGGA.xml > c4h6.cp.metaGGA.out
check_failure $?
$ECHO " done"
$ECHO
$ECHO "$EXAMPLE_DIR : done"
#!/bin/sh
# run from directory where this script is
cd `echo $0 | sed 's/\(.*\)\/.*/\1/'` # extract pathname
EXAMPLE_DIR=`pwd`
# check whether echo has the -e option
if test "`echo -e`" = "-e" ; then ECHO=echo ; else ECHO="echo -e" ; fi
$ECHO
$ECHO "$EXAMPLE_DIR : starting"
$ECHO
$ECHO "This example shows how to use cp.x to perform"
$ECHO "Born-Oppenheimer molecular dynamics using the"
$ECHO "conjugate gradient minimization of the electronic"
$ECHO "states. It shows also the use of ensemble-DFT"
$ECHO "for metallic systems."
$ECHO "The example shows a Si dimer"
# set the needed environment variables
. ../../../environment_variables
# required executables and pseudopotentials
BIN_LIST="cp.x"
PSEUDO_LIST="Si.pbe-rrkj.UPF"
$ECHO
$ECHO " executables directory: $BIN_DIR"
$ECHO " pseudo directory: $PSEUDO_DIR"
$ECHO " temporary directory: $TMP_DIR"
$ECHO " checking that needed directories and files exist...\c"
# check for directories
for DIR in "$BIN_DIR" "$PSEUDO_DIR" ; do
if test ! -d $DIR ; then
$ECHO
$ECHO "ERROR: $DIR not existent or not a directory"
$ECHO "Aborting"
exit 1
fi
done
for DIR in "$TMP_DIR" "$EXAMPLE_DIR/results" ; do
if test ! -d $DIR ; then
mkdir $DIR
fi
done
cd $EXAMPLE_DIR/results
# check for executables
for FILE in $BIN_LIST ; do
if test ! -x $BIN_DIR/$FILE ; then
$ECHO
$ECHO "ERROR: $BIN_DIR/$FILE not existent or not executable"
$ECHO "Aborting"
exit 1
fi
done
# check for pseudopotentials
for FILE in $PSEUDO_LIST ; do
if test ! -r $PSEUDO_DIR/$FILE ; then
$ECHO
$ECHO "Downloading $FILE to $PSEUDO_DIR...\c"
$WGET $PSEUDO_DIR/$FILE \
http://www.quantum-espresso.org/pseudo/1.3/UPF/$FILE 2> /dev/null
fi
if test $? != 0; then
$ECHO
$ECHO "ERROR: $PSEUDO_DIR/$FILE not existent or not readable"
$ECHO "Aborting"
exit 1
fi
done
$ECHO " done"
# how to run executables
CP_COMMAND="$PARA_PREFIX $BIN_DIR/cp.x $PARA_POSTFIX"
$ECHO
$ECHO " running cp.x as: $CP_COMMAND"
$ECHO
# clean TMP_DIR
$ECHO " cleaning $TMP_DIR...\c"
rm -rf $TMP_DIR/*
$ECHO " done"
# molecular dynamics calculation
cat > si2.ensemble-dyn.xml << EOF
<?xml version="1.0" encoding="UTF-8"?>
<input calculation="cp" prefix="Si_dimer">
<cell type="qecell">
<qecell ibrav="8" alat="10.0">
<real rank="1" n1="5">
1.0 1.5 0.0 0.0 0.0
</real>
</qecell>
</cell>
<atomic_species ntyp="1">
<specie name="Si">
<property name="mass">
<real>28.086</real>
</property>
<property name="pseudofile">
<string>Si.pbe-rrkj.UPF</string>
</property>
<property name="ion_radius">
<real>0.8d0</real>
</property>
</specie>
</atomic_species>
<atomic_list units="bohr" nat="2" >
<atom name="Si">
<position ifx="1" ify="1" ifz="1">
<real rank="1" n1="3">
0.0 0.0 0.0
</real>
</position>
</atom>
<atom name="Si">
<position ifx="1" ify="1" ifz="1">
<real rank="1" n1="3">
0.0 0.0 5.5
</real>
</position>
</atom>
</atomic_list>
<field name="InputOutput">
<parameter name="pseudo_dir">
<string>
$PSEUDO_DIR/
</string>
</parameter>
<parameter name="outdir">
<string>
$TMP_DIR/
</string>
</parameter>
<parameter name="restart_mode">
<string>
from_scratch
</string>
</parameter>
<parameter name="iprint">
<integer>
10
</integer>
</parameter>
<parameter name="tstress">
<logical>
TRUE
</logical>
</parameter>
<parameter name="tprnfor">
<logical>
TRUE
</logical>
</parameter>
<parameter name="startingwfc">
<string>
random
</string>
</parameter>
<parameter name="ion_positions">
<string>
from_input
</string>
</parameter>
</field>
<field name="Numerics">
<parameter name="ecutwfc">
<real>
15.0
</real>
</parameter>
<parameter name="ecutrho">
<real>
60.0
</real>
</parameter>
<parameter name="conv_thr">
</