| 5 | 1/1 | 返回列表 |
| 查看: 1867 | 回復(fù): 4 | |||
binggan1987鐵蟲 (小有名氣)
|
[交流]
集群安裝lammps心得體會,與大家共同學(xué)習(xí) 已有2人參與
|
|
由于集群系統(tǒng)崩潰,重裝2018版的lammps,一開始裝的fftw是3.3.7版本,編譯出現(xiàn)以下報錯: 錯誤提示: fft3d.o:在函數(shù)‘fft_3d’中: /home/tree/Software/lammps/src/Obj_mpi/../fft3d.cpp:151:對‘fftwf_execute_dft’未定義的引用 /home/tree/Software/lammps/src/Obj_mpi/../fft3d.cpp:214:對‘fftwf_execute_dft’未定義的引用 /home/tree/Software/lammps/src/Obj_mpi/../fft3d.cpp:277:對‘fftwf_execute_dft’未定義的引用 /home/tree/Software/lammps/src/Obj_mpi/../fft3d.cpp:151:對‘fftwf_execute_dft’未定義的引用 /home/tree/Software/lammps/src/Obj_mpi/../fft3d.cpp:214:對‘fftwf_execute_dft’未定義的引用 fft3d.o:/home/tree/Software/lammps/src/Obj_mpi/../fft3d.cpp:277: 跟著更多未定義的參考到 fftwf_execute_dft.............. 解決辦法: 發(fā)現(xiàn)是fftw問題,我重裝了老版本3.2.2的fftw,發(fā)現(xiàn)一次編譯通過。 fftw下載地址: ftp://ftp.fftw.org/pub/fftw/ 有相同問題的,可以借鑒一下 下面是make mpi文件 # mpi = MPI with its default compiler SHELL = /bin/sh # --------------------------------------------------------------------- # compiler/linker settings # specify flags and libraries needed for your compiler CC = /public/software/mpi/openmpi/intel/2.1.2/bin/mpicxx #修改的地方 CCFLAGS = -g -O3 SHFLAGS = -fPIC DEPFLAGS = -M LINK = /public/software/mpi/openmpi/intel/2.1.2/bin/mpicxx #修改的地方 LINKFLAGS = -g -O LIB = SIZE = size ARCHIVE = ar ARFLAGS = -rc SHLIBFLAGS = -shared # --------------------------------------------------------------------- # LAMMPS-specific settings, all OPTIONAL # specify settings for LAMMPS features you will use # if you change any -D setting, do full re-compile after "make clean" # LAMMPS ifdef settings # see possible settings in Section 2.2 (step 4) of manual LMP_INC = -DLAMMPS_GZIP -DLAMMPS_MEMALIGN=64 # MPI library # see discussion in Section 2.2 (step 5) of manual # MPI wrapper compiler/linker can provide this info # can point to dummy MPI library in src/STUBS as in Makefile.serial # use -D MPICH and OMPI settings in INC to avoid C++ lib conflicts # INC = path for mpi.h, MPI compiler settings # PATH = path for MPI library # LIB = name of MPI library MPI_INC = -I/public/software/mpi/openmpi/intel/2.1.2/include -DMPICH_SKIP_MPICXX -DOMPI_SKIP_MPICXX=1 #修改的地方 MPI_PATH = -L/public/software/mpi/openmpi/intel/2.1.2/lib #修改的地方 MPI_LIB = -lmpi #修改的地方 # FFT library # see discussion in Section 2.2 (step 6) of manual # can be left blank to use provided KISS FFT library # INC = -DFFT setting, e.g. -DFFT_FFTW, FFT compiler settings # PATH = path for FFT library # LIB = name of FFT library FFT_INC = -DFFT_FFTW -I/public/software/fftw2/fftw/include #修改的地方 FFT_PATH = -L/public/software/fftw2/fftw/lib #修改的地方 FFT_LIB = -lfftw3 #修改的地方 # JPEG and/or PNG library # see discussion in Section 2.2 (step 7) of manual # only needed if -DLAMMPS_JPEG or -DLAMMPS_PNG listed with LMP_INC # INC = path(s) for jpeglib.h and/or png.h # PATH = path(s) for JPEG library and/or PNG library # LIB = name(s) of JPEG library and/or PNG library JPG_INC = JPG_PATH = JPG_LIB = # --------------------------------------------------------------------- # build rules and dependencies # do not edit this section include Makefile.package.settings include Makefile.package EXTRA_INC = $(LMP_INC) $(PKG_INC) $(MPI_INC) $(FFT_INC) $(JPG_INC) $(PKG_SYSINC) EXTRA_PATH = $(PKG_PATH) $(MPI_PATH) $(FFT_PATH) $(JPG_PATH) $(PKG_SYSPATH) EXTRA_LIB = $(PKG_LIB) $(MPI_LIB) $(FFT_LIB) $(JPG_LIB) $(PKG_SYSLIB) EXTRA_CPP_DEPENDS = $(PKG_CPP_DEPENDS) EXTRA_LINK_DEPENDS = $(PKG_LINK_DEPENDS) # Path to src files vpath %.cpp .. vpath %.h .. # Link target $(EXE): $(OBJ) $(EXTRA_LINK_DEPENDS) $(LINK) $(LINKFLAGS) $(EXTRA_PATH) $(OBJ) $(EXTRA_LIB) $(LIB) -o $(EXE) $(SIZE) $(EXE) # Library targets lib: $(OBJ) $(EXTRA_LINK_DEPENDS) $(ARCHIVE) $(ARFLAGS) $(EXE) $(OBJ) shlib: $(OBJ) $(EXTRA_LINK_DEPENDS) $(CC) $(CCFLAGS) $(SHFLAGS) $(SHLIBFLAGS) $(EXTRA_PATH) -o $(EXE) \ $(OBJ) $(EXTRA_LIB) $(LIB) # Compilation rules %.o:%.cpp $(CC) $(CCFLAGS) $(SHFLAGS) $(EXTRA_INC) -c $< # Individual dependencies depend : fastdep.exe $(SRC) @./fastdep.exe $(EXTRA_INC) -- $^ > .depend || exit 1 fastdep.exe: ../DEPEND/fastdep.c cc -O -o $@ $< sinclude .depend |
用戶注銷 (正式寫手)
鐵蟲 (小有名氣)
鐵蟲 (小有名氣)
鐵蟲 (小有名氣)
|
in文件如下,麻煩看看,謝謝! # Find minimum energy fcc configuration # Mark Tschopp, 2010 # This requires the variable latconst to be input via the command line # e.g., lmp_win_no-mpi -var latconst 4 < calc_fcc_ver1.in # ---------- Initialize Simulation --------------------- clear units metal dimension 3 boundary p p p atom_style atomic atom_modify map array # ---------- Create Atoms --------------------- lattice fcc ${latconst} region box block 0 1 0 1 0 1 units lattice create_box 1 box lattice fcc ${latconst} orient x 1 0 0 orient y 0 1 0 orient z 0 0 1 create_atoms 1 box replicate 1 1 1 # ---------- Define Interatomic Potential --------------------- pair_style eam/alloy pair_coeff * * Al99.eam.alloy Al neighbor 2.0 bin neigh_modify delay 10 check yes # ---------- Define Settings --------------------- compute eng all pe/atom compute eatoms all reduce sum c_eng # ---------- Run Minimization --------------------- reset_timestep 0 fix 1 all box/relax iso 0.0 vmax 0.001 thermo 10 thermo_style custom step pe lx ly lz press pxx pyy pzz c_eatoms min_style cg minimize 1e-25 1e-25 5000 10000 variable natoms equal "count(all)" variable teng equal "c_eatoms" variable length equal "lx" variable ecoh equal "v_teng/v_natoms" print "Total energy (eV) = ${teng};" print "Number of atoms = ${natoms};" print "Lattice constant (Angstoms) = ${length};" print "Cohesive energy (eV) = ${ecoh};" print "All done!" |
| 5 | 1/1 | 返回列表 |
| 最具人氣熱帖推薦 [查看全部] | 作者 | 回/看 | 最后發(fā)表 | |
|---|---|---|---|---|
|
[考研] 材料調(diào)劑 +5 | ws 上岸鴨 2026-03-05 | 5/250 |
|
|---|---|---|---|---|
|
[考研] 材料277分求調(diào)劑 +10 | 飯飯星球 2026-03-04 | 10/500 |
|
|
[考研] 085602 293分求調(diào)劑 +3 | SivanNano. 2026-03-05 | 3/150 |
|
|
[基金申請]
|
Doma 2026-03-01 | 10/500 |
|
|
[考研] 一志愿西交化工專碩288專業(yè)課93求調(diào)劑 +6 | 好運(yùn)好運(yùn)接接 2026-03-04 | 6/300 |
|
|
[考研] 材料與化工,291分,求調(diào)劑 +9 | 咕嚕咕嚕123123 2026-03-04 | 11/550 |
|
|
[考研] 一志愿武漢理工大學(xué)-085602-總分296分-求調(diào)劑 +7 | 紫川葡柚 2026-03-04 | 7/350 |
|
|
[考研] 307求調(diào)劑 +4 | xuyuan111 2026-03-04 | 5/250 |
|
|
[考研] 0855機(jī)械工程324求調(diào)劑 +3 | 鄭SK 2026-03-02 | 7/350 |
|
|
[考研]
|
15779376950 2026-03-01 | 8/400 |
|
|
[考研] 材料化工調(diào)劑 +15 | 今夏不夏 2026-03-01 | 18/900 |
|
|
[考研] 281求調(diào)劑 +3 | 我是小小蔥蔥 2026-03-03 | 5/250 |
|
|
[考研] 289求調(diào)劑 +7 | BrightLL 2026-03-02 | 9/450 |
|
|
[考研] 一志愿中科大能動297求調(diào)劑,本科川大 +3 | 邵11 2026-03-03 | 3/150 |
|
|
[考研] 295求調(diào)劑。一志愿報考鄭州大學(xué)化學(xué)工藝學(xué)碩,總分295分 +8 | yl1 2026-03-02 | 9/450 |
|
|
[考研] 275求調(diào)劑 +7 | 明遠(yuǎn)求學(xué) 2026-03-01 | 7/350 |
|
|
[基金申請] 此成果不能導(dǎo)入原因:元數(shù)據(jù)必填信息不完整,可 進(jìn)行補(bǔ)充。 +4 | Kittylucky 2026-03-02 | 5/250 |
|
|
[考研] 材料學(xué)調(diào)劑 +10 | 提神豆沙包 2026-02-28 | 12/600 |
|
|
[考研] 0856材料求調(diào)劑 +4 | 麻辣魷魚 2026-02-28 | 4/200 |
|
|
[考研] 311求調(diào)劑 +6 | 亭亭亭01 2026-03-01 | 6/300 |
|