[toc]
GROMACS 入门
GROMACS 安装
安装:
1
2
3
4
5
6
7
8wget https://ftp.gromacs.org/gromacs/gromacs-2023.tar.gz
tar -zxvf gromacs-2023.tar.gz
cd gromacs-2023
mkdir build
cd build
export CMAKE_PREFIX_PATH=~/fftw # fftw 路径
cmake .. -DCMAKE_INSTALL_PREFIX=~/softwares/gromacs # gromacs安装路径
make install -j8最新快速安装:
1
2
3
4
5
6
7
8
9tar xfz gromacs-2023.2.tar.gz
cd gromacs-2023.2
mkdir build
cd build
# 这里自动build一个fftw
cmake .. -DGMX_BUILD_OWN_FFTW=ON -DREGRESSIONTEST_DOWNLOAD=ON -DCMAKE_INSTALL_PREFIX=~/softwares/gromacs
make
make check
sudo make install如果使用的是 Ubuntu 操作系统,只需在终端执行以下命令即可:
1
sudo apt-get install gromacs
环境变量设置:
1
2
3
4
5
6
7
8cd ~/softwares/gromacs/bin
pwd # 查看路径,并复制
sudo vim ~/.bashrc
export PATH="~/softwares/gromacs/bin:$PATH"
# esc
# :
# wq
source ~/.bashrc测试:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28gmx -version
# output:
# Executable: ~/softwares/gromacs/bin/gmx
# Data prefix: ~/softwares/gromacs
# Working dir: ~/softwares/gromacs
# Command line:
# gmx -version
#
# GROMACS version: 2023-dev
# Precision: mixed
# Memory model: 64 bit
# MPI library: thread_mpi
# OpenMP support: enabled (GMX_OPENMP_MAX_THREADS = 128)
# GPU support: disabled
# SIMD instructions: AVX2_256
# CPU FFT library: fftw-3.3.10
# GPU FFT library: none
# Multi-GPU FFT: none
# RDTSCP usage: enabled
# TNG support: enabled
# Hwloc support: disabled
# Tracing support: disabled
# C compiler: /usr/bin/cc GNU 9.4.0
# C compiler flags: -Wno-array-bounds -fexcess-precision=fast -funroll-all-loops -mavx2 -mfma -Wall -Wno-unused -Wunused-value -Wunused-parameter -Wextra -Wno-sign-compare -Wpointer-arith -Wundef -Werror=stringop-truncation -Wno-missing-field-initializers -O3 -DNDEBUG
# C++ compiler: /usr/bin/c++ GNU 9.4.0
# C++ compiler flags: -Wno-array-bounds -fexcess-precision=fast -funroll-all-loops -mavx2 -mfma -Wall -Wextra -Wpointer-arith -Wmissing-declarations -Wundef -Wstringop-truncation -Wno-missing-field-initializers -Wno-cast-function-type-strict -fopenmp -O3 -DNDEBUG
# BLAS library: External - detected on the system
# LAPACK library: External - detected on the system参考:
运行GROMACS
运行GROMACS 所需文件
- 初始构型文件:
x.gro x.pdb
- 参数控制文件:
x.mdp
- 力场文件:
x.top x.itp
- 索引文件:
x.ndx
相关力场:
Martini粗粒化力场
AMBER、CHARMM、OPLS-AA、GROMOS
力场文件相关工具:
- pdb2gmx、AMBER Tool、tppmktop、x2top、martini.py、ATB/PRODRG……
后处理工具:
- gmx msd
- gmx rdf
- gmx totcf (旋转自相关函数)
- gmx potential (静电势)
- gmx helix ($\alpha$螺旋结构的基本性质)
- MD_Analysis、VMD
- 自编程