计算化学公社
标题: NWChem的编译方法 [打印本页]
作者Author: sobereva 时间: 2014-12-22 05:52
标题: NWChem的编译方法
NWChem的编译方法
Compilation method of NWChem
文/Sobereva @北京科音
First release:2014-Dec-22 Last update:2020-May-6
本文介绍编译NWChem 7.0的最简单的方法。笔者的操作系统是CentOS 7.4 64bit,用户是root。编译器用的gfortran。官方也有编译说明,见https://github.com/nwchemgit/nwchem/wiki/Compiling-NWChem,但里面的内容比较混乱。
编译OpenMPI库:
去http://www.open-mpi.org下载OpenMPI 3.1.3(实测用4.0.3版也行),解压到/sob目录下,进入其目录,运行
./configure prefix=/sob/openmpi313
make all install -j
此时OpenMPI的可执行文件、库文件、头文件等就被装到了/sob/openmpi313里面的对应目录下。然后可以把OpenMPI解压的目录删掉。
在~/.bashrc中加入
export PATH=$PATH:/sob/openmpi313/bin
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/sob/openmpi313/lib
保存后,输入bash命令使以上环境变量生效。
运行以下命令设置环境变量
export NWCHEM_TOP=/sob/nwchem7
export NWCHEM_TARGET=LINUX64
export NWCHEM_MODULES=all
export USE_MPI=y
export USE_MPIF=y
export USE_MPIF4=y
export USE_INTERNALBLAS=y
注:根据反复实测,至少对于用OpenMPI的情况,只需要设置以上内容就够了,如果设置了某些其它环境变量,反倒可能编译不成功,尤其是不建议自己设LIBMPI环境变量。
注:NWChem为了节约编译时间,许多不常用的模块默认是不编译的。如果你想编译它们,使用以下命令定义额外的环境变量,需要哪些就执行哪些
export MRCC_METHODS=y:编译多参考耦合簇代码
export CCSDTQ=y:编译TCE模块的CCSDTQ和EOM-CCSDTQ代码
export CCSDTLR=y:编译TCE模块的线性响应CCSDT、CCSDTQ代码,用于解析地算静态/动态极化率
export IPCCSD=y:编译TCE模块的IP-EOM-CCSD代码用于算电离能
export EACCSD=y:编译TCE模块的EA-EOM-CCSD代码用于算电子亲和能
把nwchem7.0压缩包解压到/sob/nwchem7,运行
cd /sob/nwchem7/src
make nwchem_config
make -j
这里用-j是为了并行编译,此时在笔者的Intel 36核机子下11分钟就编译完毕了(没有编译那些不常用的模块),不用-j的话会慢得多。但如果编译出现异常,去掉-j再试。
编译完成后可执行文件生成在了/sob/nwchem7/bin/LINUX64目录下。把下面的语句加入到~/.bashrc的末尾:
export PATH=$PATH:/sob/nwchem7/bin/LINUX64
保存后,输入bash命令使此环境变量生效。
现在进行测试。将以下内容写进test.nw:
title "Nitrogen cc-pvtz SCF geometry optimization"
geometry
n 0 0 0
n 0 0 1.08
end
basis
n library cc-pvtz
end
task scf optimize
然后运行nwchem test.nw查看输出是否正常。也运行mpirun -np 4 nwchem test.nw查看并行执行的输出是否正常,-np后面是调用的核数。
以下内容是老版本的情况,最后更新于2017-Apr-13
本文有两部分,第一部分是NWChem 6.6在Redhat Enterprise 6 Update 1 64bit下的安装,第二部分是NWChem 6.6在CentOS 7.2 64bit下的安装。后者过程更简单。编译器用的gfortran,用ifort也可以,但实测编译出的nwchem运行速度并不会更快,而且在编译耗时长得多,特别是CCSDTQ部分耗时极长,10个小时都编译不完。
编译条件:root, bash。将安装到/sob/nwchem-6.6。
本文的编译方法对nwchem 6.8经测试也完全适用,但是编译时必须能联网,因为会自动下载GlobalArray包。
===== NWChem 6.6 + Redhat Enterprise 6 Update 1 64bit ======
编译openmpi:
去http://www.open-mpi.org下载OpenMPI 1.6.5(更新的版本大抵也可以,笔者没测试),解压到/sob目录下,进入其目录,运行
./configure prefix=/sob/openmpi165
make all install -j
此时openmpi的可执行文件、库文件、头文件等就被装到了/sob/openmpi165里面的对应目录下。然后可以把OpenMPI解压的目录删掉。
在~/.bashrc中加入
export PATH=$PATH:/sob/openmpi165/bin
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/sob/openmpi165/lib
输入bash使环境变量生效。
运行以下命令设置环境变量
export NWCHEM_TOP=/sob/nwchem-6.6
export NWCHEM_TARGET=LINUX64
export NWCHEM_MODULES=all
export USE_MPI=y
export USE_MPIF=y
export USE_MPIF4=y
export USE_INTERNALBLAS=y
export MPI_LOC=/sob/openmpi165
export MPI_LIB=/sob/openmpi165/lib
export MPI_INCLUDE=/sob/openmpi165/include
export LIBMPI="-lmpi_f90 -lmpi_f77 -lmpi -ldl -Wl,--export-dynamic -lnsl -lutil"
NWChem为了节约编译时间,许多不常用的模块默认是不编译的。如果你想编译它们,使用以下命令定义额外的环境变量,需要哪些就执行哪些
export MRCC_METHODS=y:编译多参考耦合簇代码
export CCSDTQ=y:编译TCE模块的CCSDTQ和EOM-CCSDTQ代码
export CCSDTLR=y:编译TCE模块的线性响应CCSDT、CCSDTQ代码,用于解析地算静态/动态极化率
export IPCCSD=y:编译TCE模块的IP-EOM-CCSD代码用于算电离能
export EACCSD=y:编译TCE模块的EA-EOM-CCSD代码用于算电子亲和能
把nwchem6.6压缩包解压到/sob/nwchem-6.6,运行
cd /sob/nwchem-6.6/src
make nwchem_config
make
可执行文件生成在了/sob/nwchem-6.6/bin/LINUX64目录下。把下面的语句加入到~/.bashrc的末尾:
export PATH=$PATH:/sob/nwchem-6.6/bin/LINUX64
笔者在Intel i7-2630QM四核机子上花一刻钟编译完毕。如果把上述全部额外的功能都编译的话,耗时约一个小时。make时不需要写-j,而且写不写都会自动用双线程编译。
现在测试。将以下内容写进test.nw:
title "Nitrogen cc-pvtz SCF geometry optimization"
geometry
n 0 0 0
n 0 0 1.08
end
basis
n library cc-pvtz
end
task scf optimize
然后运行nwchem test.nw查看输出是否正常。也运行mpirun -np 4 nwchem test.nw查看并行执行的输出是否正常。-np后面是调用的核数。
===== NWChem 6.6 + CentOS 7.2 64bit ======
运行以下命令添加EPEL源和安装openMPI(机子需要能联外网)
yum install epel-release
yum install openmpi-devel openmpi
将以下内容复制到命令行窗口设置环境变量
export NWCHEM_TOP=/sob/nwchem-6.6
export NWCHEM_TARGET=LINUX64
export NWCHEM_MODULES=all
export USE_MPI=y
export USE_INTERNALBLAS=y
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib64/openmpi/lib/
export PATH=$PATH:/usr/lib64/openmpi/bin/
若要编译NWChem额外的功能,需要额外设定的环境变量和上文提到的一致。
把nwchem6.6压缩包解压到/sob/nwchem-6.6,运行
cd /sob/nwchem-6.6/src
make nwchem_config
make
可执行文件生成在了/sob/nwchem-6.6/bin/LINUX64目录下。
把下面的语句加入到~/.bashrc的末尾:
export PATH=$PATH:/sob/nwchem-6.6/bin/LINUX64:/usr/lib64/openmpi/bin/
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib64/openmpi/lib/
alias mpirun='mpirun --allow-run-as-root'
重新进入终端后就可以用比如mpirun -np 4 nwchem test.nw运行了。
作者Author: jiangning198511 时间: 2014-12-22 10:39
感谢提供的编译信息
不过听说NWCHEM已经停止更新了,好多当初的开发者都离开了PNNL.
作者Author: sobereva 时间: 2014-12-22 11:01
还在更新,6.5是今年9月才出的,应该会继续发展下去
作者Author: 卡开发发 时间: 2014-12-22 11:19
我自己以前按我老师写的configure.sh是这样的,记得刚学这个的时候用的是6.0的版本,用的是intel ifort 11.1.038的编译器,数学库用的是mkl,用的intel的impi不知道现在这个还能不能用,
vi configure.sh
#configure.sh内容如下:
export LARGE_FILES=TRUE
export LIB_DEFINES="-DDFLT_TOT_MEM=524111744"
export NWCHEM_TOP=/home/Admin/nwchem-6.0
export NWCHEM_TARGET=LINUX64
export NWCHEM_TARGET_CPU=x86_64
export NWCHEM_MODULES=all
export USE_MPI=y
export USE_MPIF=n
export USE_BLAS=y
export BLASOPT="-L/opt/software/compiler/intel/11.1/072/mkl/lib/em64t -lmkl_lapack -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lguide -lpthread"
export FOPTIMIZE=。。。。。 #指令集可选
# Intel MPI
export MPI_LOC=/software/intel/impi/3.2.1.009/
export MPI_LIB=$MPI_LOC/lib64
export MPI_INCLUDE=$MPI_LOC/include64
export LIBMPI="-lmpigf -lmpigi -lmpi_ilp64 -lmpi"
make realclean
make nwchem_config
make FC=ifort CC=icc
印象中编译差不多在双路的Xeon E5405差不多也要一个小时。当年在组里面测试了一下NWPW的速度,感觉不太可观,后来就放弃了。
作者Author: chrinide 时间: 2014-12-22 17:58
NWchem自从version 6.0 Open ECL 以后, 开发和更新就更快了 当初的开发者确实有一部分离开 可是新生的Team更具活力 参看NWChem官网上的On-goning Project.
作者Author: aixin 时间: 2015-1-1 21:09
本帖最后由 aixin 于 2015-1-1 21:10 编辑
我编译完成了,也执行了test的案例,是成功的。但是我有些不理解,官网上设置 .nwchemrc 环境变量和库,是什么意思? 说可以通过ln -s /usr/local/NWChem/data/default.nwchemrc $HOME/.nwchemrc 来完成。但是我按照您的编译方法,就是找不到default.nwchemrc这个文件。这是怎么回事呢?谢谢你
作者Author: excalibur 时间: 2015-1-1 23:17
自己按照官网的说明建一个default.nwchemrc文件,再建一个软链接.nwchemrc。
作者Author: aixin 时间: 2015-1-2 11:31
我怎么找不到nwchem-6.5/src/data/libraries 呢?是我安装没成功。但为什么可以测试test?
作者Author: excalibur 时间: 2015-1-2 11:53
本帖最后由 excalibur 于 2015-1-2 12:01 编辑
/usr/local/NWChem/data/libraries/ 文件夹也是需要你从安装源文件的目录里拷贝进去。
在NWChem文档里有相关说明:http://www.nwchem-sw.org/index.p ... l_site_installation
General site installation:
Set links to data files (basis sets, force fields, etc.)
cd $NWCHEM_TOP/src/basis
cp -r libraries /usr/local/NWChem/data
cd $NWCHEM_TOP/src/
cp -r data /usr/local/NWChem
cd $NWCHEM_TOP/src/nwpw
cp -r libraryps /usr/local/NWChem/data
这些操作是为了让计算平台上的所有用户都能使用NWChem而进行的相关设置,如果你安装NWChem只是为了自己使用,这些操作都是可以省略的,放在原来的安装目录就可以了。
作者Author: aixin 时间: 2015-1-2 12:03
如果我不拷贝文件,不使用general site installation。就安装sob 的安装方法(这个帖子的楼主写的) 可以么?我感觉还是要加。因为,我test一些程序的时候,提示找不到libraries。
作者Author: excalibur 时间: 2015-1-2 12:30
本帖最后由 excalibur 于 2015-1-9 20:10 编辑
如果做ab initio或者DFT计算,可以全部显式的指定基组。至少我没有遇到过找不到库文件的情况。PS:我用的都是早期版本。
如果怕麻烦不想自己编译,并且你的计算平台上用的是Debian/Ubuntu系Linux,直接可以apt-get install nwchem安装,系统会自动解决所有的库依赖关系。Ubuntu 14.04和14.10中NWChem的版本是6.3,Debian stable中是NWChem6.1, Debian testing和unstable中NWChem是6.5.
如果是ArchLinux、Gentoo Linux及其衍生版本,也可以用其对应的包管理命令pacman或者emerge从软件仓库里把nwchem拖下来,这两个发行版的软件仓库里NWChem的版本都是6.5.
RPM系的Linux应该可以从网上找到相应的rpm包。
当然从软件仓库中拖下来的一般都是用的仓库中的数学和并行库,并且用的GNU的编译器,速度比用intel编译器和MKL库编译的会差一些,差多少没有测试过。
作者Author: excalibur 时间: 2015-1-2 12:59
找不到libraries的话,你可以对应nwchemrc文件检查下这些库文件是否都安装在应有的位置,同时检查下这些库文件和文件夹的读写权限是不是设置正确了……
作者Author: aixin 时间: 2015-1-9 11:16
多谢,后来就解决了。
作者Author: lsc840927 时间: 2015-3-9 16:56
你好!我用root用户安装好NWchem6.5后,用root用户提交例子文档能正常运算。换成普通用户,并设置好环境变量,计算例子时提示以下错误,不知道是什么原因?请大家帮忙看看?
mpirun was unable to launch the specified application as it could not access or execute an executable:
Executable: /opt/nwchem6.5/bin/LINUX64/nwchem
作者Author: sobereva 时间: 2015-3-9 16:59
你看看普通用户有没有执行此文件的权限。
作者Author: lsc840927 时间: 2015-3-9 18:05
谢谢sobereva,确实是权限的问题。我把nwchem安装文件夹里的所有文件的属性全部改为了777.普通用户就能正常使用了。
作者Author: 五十八 时间: 2017-5-15 09:05
本帖最后由 五十八 于 2017-5-15 11:26 编辑
这几天试了好多次cuda版本的nwchem.... 因为老板想用集群上的K80 然后就有了下面的config:
编译环境 intel 2017|cuda 8.0|openmpi 2.x with cuda
#! /bin/bash
export NWCHEM_TOP=/opt/nwchem-6.6
export NWCHEM_TARGET=LINUX64
export LARGE_FILES=TRUE
export LIB_DEFINES="-DDFLT_TOT_MEM=16777216"
export USE_MPI=y
export MPI_LOC=/opt/omp/intel
export MPI_INCLUDE=$MPI_LOC/include
export MPI_LIB=$MPI_LOC/lib
export NWCHEM_MPIF_WRAP=$MPI_LOC/bin/mpif90
export NWCHEM_MPIC_WRAP=$MPI_LOC/bin/mpicc
export NWCHEM_MPICXX_WRAP=$MPI_LOC/bin/mpicxx
export CC=icc
export CXX=icpc
export FC=ifort
export MRCC_METHODS=y
export CCSDTQ=y
export CCSDTLR=y
export IPCCSD=y
export EACCSD=y
export USE_MPIF=y
export LIBMPI="-lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lmpi"
export ARMCI_NETWORK=MPI2
export NWCHEM_MODULES=all
export LARGE_FILES=TRUE
export USE_NOFSCHECK=TRUE
export TCE_CUDA=Y
export CUDA_LIBS="-L/usr/local/cuda/lib64 -lcudart -lcublas"
export CUDA_FLAGS="-arch sm_61"
export CUDA_INCLUDE="-I. -I/usr/local/cuda/include"
export CUDA=nvcc
export MKLLIB=$MKLROOT/lib/intel64
export MKLINC=$MKLROOT/include
export BLASOPT="-L$MKLLIB -lmkl_intel_ilp64 -lmkl_core -lmkl_sequential -lpthread -lm"
export LAPACK_LIB="-L$MKLLIB -lmkl_intel_ilp64 -lmkl_core -lmkl_sequential -lpthread -lm"
export BLAS_LIB="-L$MKLLIB -lmkl_intel_ilp64 -lmkl_core -lmkl_sequential -lpthread -lm"
export SCALAPACK="-L$MKLLIB -lmkl_scalapack_ilp64 -lmkl_intel_ilp64 -lmkl_core -lmkl_sequential -lmkl_blacs_openmpi_ilp64 -lpthread -lm"
export SCALAPACKOPT="-L$MKLLIB -lmkl_scalapack_ilp64 -lmkl_intel_ilp64 -lmkl_core -lmkl_sequential -lmkl_blacs_openmpi_ilp64 -lpthread -lm"
export SCALAPACK_LIB="-L$MKLLIB -lmkl_scalapack_ilp64 -lmkl_intel_ilp64 -lmkl_core -lmkl_sequential -lmkl_blacs_openmpi_ilp64 -lpthread -lm"
export SCALAPACK_SIZE=8
export BLAS_SIZE=8
export USE_MPIF4=y
export HAS_BLAS=yes
export USE_SCALAPACK=yes
make nwchem_config
nohup make -j 4 > make.log &
注意:
1. libmpi使用的是mpif90 -show中列出的
2. -j 4 在最后可能会有小问题,不过error后再make一下 就可以了 E5 2667V4 也就一个小时不到
3. Current version of cuda implementation is NOT supported for ARMCI_NETWORK=MPI-TS.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
顺便贴出H2O的测试结果
输入 QA/tests/tce_cuda
输出:
argument 1 = tce_cuda.nw
============================== echo of input deck ==============================
#
# Test for CCSD[T] & CCDS(T) codes in the TCE module
# Reference data obtained by an independent code are
#
# CCSD(T) -0.21632467284
# CCSD[T] -0.21640986353
#
# in units of hartree.
#
# The (T) & [T] codes and the reference data have been
# provided by Alex A. Auer (University of Waterloo)
#
start tce_ccsd_t_h2o
echo
geometry units bohr
O 0.00000000 0.00000000 0.22138519
H 0.00000000 -1.43013023 -0.88554075
H 0.00000000 1.43013023 -0.88554075
end
basis spherical
H library cc-pVDZ
O library cc-pVDZ
end
scf
thresh 1.0e-10
tol2e 1.0e-10
singlet
rhf
end
tce
ccsd(t)
io ga
cuda 1
end
task tce energy
================================================================================
Northwest Computational Chemistry Package (NWChem) 6.6
------------------------------------------------------
Environmental Molecular Sciences Laboratory
Pacific Northwest National Laboratory
Richland, WA 99352
Copyright (c) 1994-2015
Pacific Northwest National Laboratory
Battelle Memorial Institute
NWChem is an open-source computational chemistry package
distributed under the terms of the
Educational Community License (ECL) 2.0
A copy of the license is included with this distribution
in the LICENSE.TXT file
ACKNOWLEDGMENT
--------------
This software and its documentation were developed at the
EMSL at Pacific Northwest National Laboratory, a multiprogram
national laboratory, operated for the U.S. Department of Energy
by Battelle under Contract Number DE-AC05-76RL01830. Support
for this work was provided by the Department of Energy Office
of Biological and Environmental Research, Office of Basic
Energy Sciences, and the Office of Advanced Scientific Computing.
Job information
---------------
hostname = localhost.localdomain
program = nwchem
date = Mon May 15 16:50:08 2017
compiled = Mon_May_15_08:41:27_2017
source = /opt/nwchem-6.6
nwchem branch = 6.6
nwchem revision = 27746
ga revision = 10594
input = tce_cuda.nw
prefix = tce_ccsd_t_h2o.
data base = ./tce_ccsd_t_h2o.db
status = startup
nproc = 4
time left = -1s
Memory information
------------------
heap = 13107194 doubles = 100.0 Mbytes
stack = 13107199 doubles = 100.0 Mbytes
global = 26214400 doubles = 200.0 Mbytes (distinct from heap & stack)
total = 52428793 doubles = 400.0 Mbytes
verify = yes
hardfail = no
Directory information
---------------------
0 permanent = .
0 scratch = .
NWChem Input Module
-------------------
C2V symmetry detected
------
auto-z
------
Geometry "geometry" -> ""
-------------------------
Output coordinates in a.u. (scale by 1.000000000 to convert to a.u.)
No. Tag Charge X Y Z
---- ---------------- ---------- -------------- -------------- --------------
1 O 8.0000 0.00000000 0.00000000 0.22138519
2 H 1.0000 1.43013023 0.00000000 -0.88554075
3 H 1.0000 -1.43013023 0.00000000 -0.88554075
Atomic Mass
-----------
O 15.994910
H 1.007825
Effective nuclear repulsion energy (a.u.) 9.1968845623
Nuclear Dipole moment (a.u.)
----------------------------
X Y Z
---------------- ---------------- ----------------
0.0000000000 0.0000000000 0.0000000000
Symmetry information
--------------------
Group name C2v
Group number 16
Group order 4
No. of unique centers 2
Symmetry unique atoms
1 2
Z-matrix (autoz)
--------
Units are Angstrom for bonds and degrees for angles
Type Name I J K L M Value
----------- -------- ----- ----- ----- ----- ----- ----------
1 Stretch 1 2 0.95700
2 Stretch 1 3 0.95700
3 Bend 2 1 3 104.52000
XYZ format geometry
-------------------
3
geometry
O 0.00000000 0.00000000 0.11715200
H 0.75679238 0.00000000 -0.46860802
H -0.75679238 0.00000000 -0.46860802
==============================================================================
internuclear distances
------------------------------------------------------------------------------
center one | center two | atomic units | a.u.
------------------------------------------------------------------------------
2 H | 1 O | 1.80847 | 1.80847
3 H | 1 O | 1.80847 | 1.80847
------------------------------------------------------------------------------
number of included internuclear distances: 2
==============================================================================
==============================================================================
internuclear angles
------------------------------------------------------------------------------
center 1 | center 2 | center 3 | degrees
------------------------------------------------------------------------------
2 H | 1 O | 3 H | 104.52
------------------------------------------------------------------------------
number of included internuclear angles: 1
==============================================================================
Basis "ao basis" -> "" (spherical)
-----
H (Hydrogen)
------------
Exponent Coefficients
-------------- ---------------------------------------------------------
1 S 1.30100000E+01 0.019685
1 S 1.96200000E+00 0.137977
1 S 4.44600000E-01 0.478148
2 S 1.22000000E-01 1.000000
3 P 7.27000000E-01 1.000000
O (Oxygen)
----------
Exponent Coefficients
-------------- ---------------------------------------------------------
1 S 1.17200000E+04 0.000710
1 S 1.75900000E+03 0.005470
1 S 4.00800000E+02 0.027837
1 S 1.13700000E+02 0.104800
1 S 3.70300000E+01 0.283062
1 S 1.32700000E+01 0.448719
1 S 5.02500000E+00 0.270952
1 S 1.01300000E+00 0.015458
2 S 1.17200000E+04 -0.000160
2 S 1.75900000E+03 -0.001263
2 S 4.00800000E+02 -0.006267
2 S 1.13700000E+02 -0.025716
2 S 3.70300000E+01 -0.070924
2 S 1.32700000E+01 -0.165411
2 S 5.02500000E+00 -0.116955
2 S 1.01300000E+00 0.557368
3 S 3.02300000E-01 1.000000
4 P 1.77000000E+01 0.043018
4 P 3.85400000E+00 0.228913
4 P 1.04600000E+00 0.508728
5 P 2.75300000E-01 1.000000
6 D 1.18500000E+00 1.000000
Summary of "ao basis" -> "" (spherical)
------------------------------------------------------------------------------
Tag Description Shells Functions and Types
---------------- ------------------------------ ------ ---------------------
H cc-pVDZ 3 5 2s1p
O cc-pVDZ 6 14 3s2p1d
NWChem SCF Module
-----------------
ao basis = "ao basis"
functions = 24
atoms = 3
closed shells = 5
open shells = 0
charge = 0.00
wavefunction = RHF
input vectors = atomic
output vectors = ./tce_ccsd_t_h2o.movecs
use symmetry = T
symmetry adapt = T
Summary of "ao basis" -> "ao basis" (spherical)
------------------------------------------------------------------------------
Tag Description Shells Functions and Types
---------------- ------------------------------ ------ ---------------------
H cc-pVDZ 3 5 2s1p
O cc-pVDZ 6 14 3s2p1d
Symmetry analysis of basis
--------------------------
a1 11
a2 2
b1 7
b2 4
Forming initial guess at 1.0s
Superposition of Atomic Density Guess
-------------------------------------
Sum of atomic energies: -75.76222910
Non-variational initial energy
------------------------------
Total energy = -75.926598
1-e energy = -121.777341
2-e energy = 36.653859
HOMO = -0.469523
LUMO = 0.091436
Symmetry analysis of molecular orbitals - initial
-------------------------------------------------
Numbering of irreducible representations:
1 a1 2 a2 3 b1 4 b2
Orbital symmetries:
1 a1 2 a1 3 b1 4 a1 5 b2
6 a1 7 b1 8 b1 9 a1 10 a1
11 b2 12 b1 13 a1 14 a2 15 b2
Starting SCF solution at 1.2s
----------------------------------------------
Quadratically convergent ROHF
Convergence threshold : 1.000E-10
Maximum no. of iterations : 30
Final Fock-matrix accuracy: 1.000E-10
----------------------------------------------
#quartets = 1.953D+03 #integrals = 1.482D+04 #direct = 0.0% #cached =100.0%
Integral file = ./tce_ccsd_t_h2o.aoints.0
Record size in doubles = 65536 No. of integs per rec = 43688
Max. records in memory = 2 Max. records in file = 171316
No. of bits per label = 8 No. of bits per value = 64
File balance: exchanges= 0 moved= 0 time= 0.0
iter energy gnorm gmax time
----- ------------------- --------- --------- --------
1 -75.9919313493 8.32D-01 3.68D-01 1.1
2 -76.0245328051 1.73D-01 7.81D-02 1.2
3 -76.0267916567 1.46D-02 6.36D-03 1.3
4 -76.0268078570 3.41D-05 1.89D-05 1.3
5 -76.0268078571 2.09D-10 1.15D-10 1.3
6 -76.0268078571 2.82D-12 1.14D-12 1.4
Final RHF results
------------------
Total SCF energy = -76.026807857137
One-electron energy = -123.154586049208
Two-electron energy = 37.930893629772
Nuclear repulsion energy = 9.196884562299
Time for solution = 0.3s
Symmetry analysis of molecular orbitals - final
-----------------------------------------------
Numbering of irreducible representations:
1 a1 2 a2 3 b1 4 b2
Orbital symmetries:
1 a1 2 a1 3 b1 4 a1 5 b2
6 a1 7 b1 8 b1 9 a1 10 a1
11 b2 12 b1 13 a1 14 a2 15 b2
Final eigenvalues
-----------------
1
1 -20.5504
2 -1.3368
3 -0.6994
4 -0.5666
5 -0.4932
6 0.1856
7 0.2563
8 0.7895
9 0.8545
10 1.1635
11 1.2004
12 1.2533
13 1.4446
14 1.4763
15 1.6748
ROHF Final Molecular Orbital Analysis
-------------------------------------
Vector 2 Occ=2.000000D+00 E=-1.336810D+00 Symmetry=a1
MO Center= -6.1D-18, -4.2D-33, -5.4D-02, r^2= 5.0D-01
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
2 0.442847 1 O s 3 0.375524 1 O s
15 0.193713 2 H s 20 0.193713 3 H s
Vector 3 Occ=2.000000D+00 E=-6.994436D-01 Symmetry=b1
MO Center= 2.0D-17, 1.4D-34, -1.1D-01, r^2= 7.7D-01
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
4 0.490008 1 O px 15 0.328055 2 H s
20 -0.328055 3 H s 7 0.221765 1 O px
Vector 4 Occ=2.000000D+00 E=-5.666047D-01 Symmetry=a1
MO Center= 9.9D-17, 7.8D-17, 1.6D-01, r^2= 6.7D-01
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
6 0.545529 1 O pz 9 0.365329 1 O pz
3 0.349885 1 O s 15 -0.206362 2 H s
20 -0.206362 3 H s 2 0.150410 1 O s
Vector 5 Occ=2.000000D+00 E=-4.931619D-01 Symmetry=b2
MO Center= 4.0D-17, -6.0D-17, 9.3D-02, r^2= 6.0D-01
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
5 0.631158 1 O py 8 0.495642 1 O py
Vector 6 Occ=0.000000D+00 E= 1.856128D-01 Symmetry=a1
MO Center= -1.9D-16, -1.2D-17, -6.1D-01, r^2= 3.0D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
3 1.003062 1 O s 16 -0.829439 2 H s
21 -0.829439 3 H s 9 -0.336808 1 O pz
6 -0.190376 1 O pz
Vector 7 Occ=0.000000D+00 E= 2.562882D-01 Symmetry=b1
MO Center= 3.8D-16, -2.5D-19, -6.2D-01, r^2= 3.6D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
16 1.444952 2 H s 21 -1.444952 3 H s
7 -0.671020 1 O px 4 -0.283072 1 O px
Vector 8 Occ=0.000000D+00 E= 7.895205D-01 Symmetry=b1
MO Center= -7.6D-15, -1.5D-16, -2.5D-01, r^2= 1.7D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
15 0.944396 2 H s 20 -0.944396 3 H s
16 -0.685542 2 H s 21 0.685542 3 H s
7 -0.461871 1 O px 4 -0.267872 1 O px
19 -0.153045 2 H pz 24 0.153045 3 H pz
Vector 9 Occ=0.000000D+00 E= 8.545358D-01 Symmetry=a1
MO Center= 6.8D-15, -2.5D-17, -4.7D-01, r^2= 1.6D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
15 0.787221 2 H s 20 0.787221 3 H s
16 -0.547465 2 H s 21 -0.547465 3 H s
6 0.329172 1 O pz 3 0.319623 1 O s
17 0.296348 2 H px 22 -0.296348 3 H px
2 -0.255712 1 O s
Vector 10 Occ=0.000000D+00 E= 1.163485D+00 Symmetry=a1
MO Center= -5.3D-16, 6.3D-18, 1.4D-01, r^2= 1.2D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
9 1.279725 1 O pz 6 -0.754396 1 O pz
3 -0.750184 1 O s 15 0.547420 2 H s
20 0.547420 3 H s 19 0.250488 2 H pz
24 0.250488 3 H pz
Vector 11 Occ=0.000000D+00 E= 1.200389D+00 Symmetry=b2
MO Center= -6.0D-16, 1.8D-16, 1.1D-01, r^2= 1.1D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
8 -1.025479 1 O py 5 0.967820 1 O py
Vector 12 Occ=0.000000D+00 E= 1.253280D+00 Symmetry=b1
MO Center= -3.8D-17, 1.1D-31, 1.2D-01, r^2= 1.7D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
7 1.764697 1 O px 16 -0.825968 2 H s
21 0.825968 3 H s 4 -0.733899 1 O px
15 -0.379694 2 H s 20 0.379694 3 H s
17 0.302681 2 H px 22 0.302681 3 H px
19 -0.186824 2 H pz 24 0.186824 3 H pz
Vector 13 Occ=0.000000D+00 E= 1.444621D+00 Symmetry=a1
MO Center= 6.2D-16, -9.5D-17, -5.9D-02, r^2= 1.4D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
9 0.739197 1 O pz 19 -0.545980 2 H pz
24 -0.545980 3 H pz 2 -0.529408 1 O s
3 0.507964 1 O s 15 0.332938 2 H s
20 0.332938 3 H s 17 -0.328827 2 H px
22 0.328827 3 H px 16 -0.209825 2 H s
Vector 14 Occ=0.000000D+00 E= 1.476304D+00 Symmetry=a2
MO Center= -4.7D-15, 7.4D-17, -4.3D-01, r^2= 1.0D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
18 0.685632 2 H py 23 -0.685632 3 H py
Vector 15 Occ=0.000000D+00 E= 1.674768D+00 Symmetry=b2
MO Center= 6.7D-15, -2.0D-17, -2.9D-01, r^2= 1.2D+00
Bfn. Coefficient Atom+Function Bfn. Coefficient Atom+Function
----- ------------ --------------- ----- ------------ ---------------
18 0.767191 2 H py 23 0.767191 3 H py
8 -0.633433 1 O py 11 -0.160750 1 O d -1
center of mass
--------------
x = 0.00000000 y = 0.00000000 z = 0.09750368
moments of inertia (a.u.)
------------------
2.193344434586 0.000000000000 0.000000000000
0.000000000000 6.315897898335 0.000000000000
0.000000000000 0.000000000000 4.122553463750
Mulliken analysis of the total density
--------------------------------------
Atom Charge Shell Charges
----------- ------ -------------------------------------------------------
1 O 8 8.31 2.00 0.83 0.82 2.82 1.81 0.01
2 H 1 0.85 0.69 0.07 0.09
3 H 1 0.85 0.69 0.07 0.09
Multipole analysis of the density wrt the origin
------------------------------------------------
L x y z total open nuclear
- - - - ----- ---- -------
0 0 0 0 -0.000000 0.000000 10.000000
1 1 0 0 -0.000000 0.000000 0.000000
1 0 1 0 -0.000000 0.000000 0.000000
1 0 0 1 -0.808895 0.000000 0.000000
2 2 0 0 -3.064509 0.000000 4.090545
2 1 1 0 -0.000000 0.000000 0.000000
2 1 0 1 -0.000000 0.000000 0.000000
2 0 2 0 -5.228664 0.000000 0.000000
2 0 1 1 -0.000000 0.000000 0.000000
2 0 0 2 -4.376016 0.000000 1.960456
Parallel integral file used 4 records with 0 large values
NWChem Extensible Many-Electron Theory Module
---------------------------------------------
======================================================
This portion of the program was automatically
generated by a Tensor Contraction Engine (TCE).
The development of this portion of the program
and TCE was supported by US Department of Energy,
Office of Science, Office of Basic Energy Science.
TCE is a product of Battelle and PNNL.
Please cite: S.Hirata, J.Phys.Chem.A 107, 9887 (2003).
======================================================
General Information
-------------------
Number of processors : 4
Wavefunction type : Restricted Hartree-Fock
No. of electrons : 10
Alpha electrons : 5
Beta electrons : 5
No. of orbitals : 48
Alpha orbitals : 24
Beta orbitals : 24
Alpha frozen cores : 0
Beta frozen cores : 0
Alpha frozen virtuals : 0
Beta frozen virtuals : 0
Spin multiplicity : singlet
Number of AO functions : 24
Number of AO shells : 12
Use of symmetry is : on
Symmetry adaption is : on
Schwarz screening : 0.10D-09
Correlation Information
-----------------------
Calculation type : Coupled-cluster singles & doubles w/ perturbation
Perturbative correction : (T)
Max iterations : 100
Residual threshold : 0.10D-06
T(0) DIIS level shift : 0.00D+00
L(0) DIIS level shift : 0.00D+00
T(1) DIIS level shift : 0.00D+00
L(1) DIIS level shift : 0.00D+00
T(R) DIIS level shift : 0.00D+00
T(I) DIIS level shift : 0.00D+00
CC-T/L Amplitude update : 5-th order DIIS
I/O scheme : Global Array Library
L-threshold : 0.10D-06
EOM-threshold : 0.10D-06
no EOMCCSD initial starts read in
TCE RESTART OPTIONS
READ_INT: F
WRITE_INT: F
READ_TA: F
WRITE_TA: F
READ_XA: F
WRITE_XA: F
READ_IN3: F
WRITE_IN3: F
SLICE: F
D4D5: F
Memory Information
------------------
Available GA space size is 104857024 doubles
Available MA space size is 26212588 doubles
Maximum block size 24 doubles
tile_dim = 8
Block Spin Irrep Size Offset Alpha
-------------------------------------------------
1 alpha a1 3 doubles 0 1
2 alpha b1 1 doubles 3 2
3 alpha b2 1 doubles 4 3
4 beta a1 3 doubles 5 1
5 beta b1 1 doubles 8 2
6 beta b2 1 doubles 9 3
7 alpha a1 8 doubles 10 7
8 alpha a2 2 doubles 18 8
9 alpha b1 6 doubles 20 9
10 alpha b2 3 doubles 26 10
11 beta a1 8 doubles 29 7
12 beta a2 2 doubles 37 8
13 beta b1 6 doubles 39 9
14 beta b2 3 doubles 45 10
Global array virtual files algorithm will be used
Parallel file system coherency ......... OK
#quartets = 3.081D+03 #integrals = 2.434D+04 #direct = 0.0% #cached =100.0%
Integral file = ./tce_ccsd_t_h2o.aoints.0
Record size in doubles = 65536 No. of integs per rec = 43688
Max. records in memory = 2 Max. records in file = 171316
No. of bits per label = 8 No. of bits per value = 64
File balance: exchanges= 0 moved= 0 time= 0.0
Fock matrix recomputed
1-e file size = 190
1-e file name = ./tce_ccsd_t_h2o.f1
Cpu & wall time / sec 0.0 0.1
tce_ao2e: fast2e=1
half-transformed integrals in memory
2-e (intermediate) file size = 734976
2-e (intermediate) file name = ./tce_ccsd_t_h2o.v2i
Cpu & wall time / sec 0.3 0.3
tce_mo2e: fast2e=1
2-e integrals stored in memory
2-e file size = 126194
2-e file name = ./tce_ccsd_t_h2o.v2
Cpu & wall time / sec 0.1 0.1
T1-number-of-tasks 3
t1 file size = 33
t1 file name = ./tce_ccsd_t_h2o.t1
t1 file handle = -999
T2-number-of-boxes 54
t2 file size = 4006
t2 file name = ./tce_ccsd_t_h2o.t2
t2 file handle = -996
CCSD iterations
-----------------------------------------------------------------
Iter Residuum Correlation Cpu Wall V2*C2
-----------------------------------------------------------------
1 0.2443178170854 -0.2059201622919 0.1 0.1 0.0
2 0.0506627485436 -0.2068222189180 0.0 0.0 0.0
3 0.0160641191390 -0.2089330812927 0.0 0.0 0.0
4 0.0054873325632 -0.2094088878131 0.0 0.0 0.0
5 0.0021271344761 -0.2096257931197 0.0 0.0 0.0
MICROCYCLE DIIS UPDATE: 5 5
6 0.0003573519819 -0.2097603929005 0.0 0.0 0.0
7 0.0001514299158 -0.2097678021026 0.0 0.0 0.0
8 0.0000657315934 -0.2097707694945 0.0 0.0 0.0
9 0.0000361891230 -0.2097718506068 0.0 0.0 0.0
10 0.0000195433103 -0.2097725647382 0.0 0.0 0.0
MICROCYCLE DIIS UPDATE: 10 5
11 0.0000032190057 -0.2097734216249 0.0 0.0 0.0
12 0.0000012309484 -0.2097732958748 0.0 0.0 0.0
13 0.0000005740558 -0.2097732858707 0.0 0.0 0.0
14 0.0000002981996 -0.2097732772534 0.0 0.0 0.0
15 0.0000001576344 -0.2097732747195 0.0 0.0 0.0
MICROCYCLE DIIS UPDATE: 15 5
16 0.0000000250121 -0.2097732724782 0.0 0.0 0.0
-----------------------------------------------------------------
Iterations converged
CCSD correlation energy / hartree = -0.209773272478210
CCSD total energy / hartree = -76.236581129615260
Singles contributions
Doubles contributions
CCSD(T)
Using CUDA CCSD(T) code
Using 1 device per node
CCSD[T] correction energy / hartree = -0.011901110331960
CCSD[T] correlation energy / hartree = -0.221674382810170
CCSD[T] total energy / hartree = -76.248482239947222
CCSD(T) correction energy / hartree = -0.011405381264357
CCSD(T) correlation energy / hartree = -0.221178653742567
CCSD(T) total energy / hartree = -76.247986510879613
Cpu & wall time / sec 0.1 0.6
Parallel integral file used 4 records with 0 large values
Task times cpu: 2.1s wall: 2.9s
NWChem Input Module
-------------------
Summary of allocated global arrays
-----------------------------------
No active global arrays
GA Statistics for process 0
------------------------------
create destroy get put acc scatter gather read&inc
calls: 2251 2251 6.57e+04 3870 1.74e+04 0 0 2.78e+04
number of processes/call 1.06e+00 1.12e+00 1.11e+00 0.00e+00 0.00e+00
bytes total: 4.53e+07 5.17e+06 7.47e+06 0.00e+00 0.00e+00 2.22e+05
bytes remote: 2.46e+07 2.46e+06 4.34e+06 0.00e+00 0.00e+00 0.00e+00
Max memory consumed for GA by this process: 1724304 bytes
MA_summarize_allocated_blocks: starting scan ...
MA_summarize_allocated_blocks: scan completed: 0 heap blocks, 0 stack blocks
MA usage statistics:
allocation statistics:
heap stack
---- -----
current number of blocks 0 0
maximum number of blocks 18 27
current total bytes 0 0
maximum total bytes 1061744 22509656
maximum total K-bytes 1062 22510
maximum total M-bytes 2 23
CITATION
--------
Please cite the following reference when publishing
results obtained with NWChem:
M. Valiev, E.J. Bylaska, N. Govind, K. Kowalski,
T.P. Straatsma, H.J.J. van Dam, D. Wang, J. Nieplocha,
E. Apra, T.L. Windus, W.A. de Jong
"NWChem: a comprehensive and scalable open-source
solution for large scale molecular simulations"
Comput. Phys. Commun. 181, 1477 (2010)
doi:10.1016/j.cpc.2010.04.018
AUTHORS
-------
E. Apra, E. J. Bylaska, W. A. de Jong, N. Govind, K. Kowalski,
T. P. Straatsma, M. Valiev, H. J. J. van Dam, D. Wang, T. L. Windus,
J. Hammond, J. Autschbach, K. Bhaskaran-Nair, J. Brabec, K. Lopata,
S. A. Fischer, S. Krishnamoorthy, W. Ma, M. Klemm, O. Villa, Y. Chen,
V. Anisimov, F. Aquino, S. Hirata, M. T. Hackler, T. Risthaus, M. Malagoli,
A. Marenich, A. Otero-de-la-Roza, J. Mullin, P. Nichols, R. Peverati,
J. Pittner, Y. Zhao, P.-D. Fan, A. Fonari, M. Williamson, R. J. Harrison,
J. R. Rehr, M. Dupuis, D. Silverstein, D. M. A. Smith, J. Nieplocha,
V. Tipparaju, M. Krishnan, B. E. Van Kuiken, A. Vazquez-Mayagoitia,
L. Jensen, M. Swart, Q. Wu, T. Van Voorhis, A. A. Auer, M. Nooijen,
L. D. Crosby, E. Brown, G. Cisneros, G. I. Fann, H. Fruchtl, J. Garza,
K. Hirao, R. A. Kendall, J. A. Nichols, K. Tsemekhman, K. Wolinski,
J. Anchell, D. E. Bernholdt, P. Borowski, T. Clark, D. Clerc, H. Dachsel,
M. J. O. Deegan, K. Dyall, D. Elwood, E. Glendening, M. Gutowski, A. C. Hess,
J. Jaffe, B. G. Johnson, J. Ju, R. Kobayashi, R. Kutteh, Z. Lin,
R. Littlefield, X. Long, B. Meng, T. Nakajima, S. Niu, L. Pollack, M. Rosing,
K. Glaesemann, G. Sandrone, M. Stave, H. Taylor, G. Thomas, J. H. van Lenthe,
A. T. Wong, Z. Zhang.
Total times cpu: 2.7s wall: 3.5s
作者Author: linqiaosong 时间: 2019-8-12 11:09
sob老师,我的NWChem正常编译完成了,环境变量设置如下:
- export NWCHEM_TOP=/software/nwchem/nwchem-6.8.1/
- export NWCHEM_TARGET=LINUX64
- export NWCHEM_MODULES=all
- export USE_MPI=y
- export USE_INTERNALBLAS=y
- export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/software/openmpi/4.0.0_IB_gcc7.3_singularity3.0.1/lib/
- export PATH=$PATH:/software/openmpi/4.0.0_IB_gcc7.3_singularity3.0.1/bin:/software/nwchem/nwchem-6.8.1/bin/LINUX64
复制代码
但是在运行的时候就如下报错:
- Abort(1094543) on node 0 (rank 0 in comm 0): Fatal error in PMPI_Init: Other MPI error, error stack:
- MPIR_Init_thread(639)......:
- MPID_Init(860).............:
- MPIDI_NM_mpi_init_hook(689): OFI addrinfo() failed (ofi_init.h:689:MPIDI_NM_mpi_init_hook:No data available)
复制代码
是不是我的openMPI有问题?
作者Author: sobereva 时间: 2019-8-13 07:07
不好说,也许是。如果输出文件已经产生了,看输出文件里有什么提示
作者Author: sobereva 时间: 2020-5-6 20:29
更新了本文,加入了NWChem 7.0的编译说明
作者Author: naonao5205 时间: 2024-12-18 08:36
7.2.3似乎有个bug
编译下载的dftd3.tgz指向了 https://www.chemie.uni-bonn.de/g ... dftd3.tgz/dftd3.tgz
可以手动在https://www.chemie.uni-bonn.de/g ... re/dft-d3/dftd3.tgz 然后复制到 /src/nwpw/nwpwlib/nwpwxc/解决
| 欢迎光临 计算化学公社 (http://bbs.keinsci.com/) |
Powered by Discuz! X3.3 |