動径分布関数(radial distribution function; RDF)と角度分布関数(angular distribution function; ADF)の計算およびプロットについて.

RDF

次のコマンドでRDFを取得できる.

python ~/src/nap/nappy/rdf.py --fortran -d 0.05 --gsmear=1 --skip=50 --specorder=Si,O traj.extxyz

上の例では,Si-Oの系であり,元素の順番を指定している.traj.extxyz内に複数の構造データ(MD trajectoryなど)が入っていれば,その平均としてのRDFが出力される.

-hをつけて実行すればオプションを見ることができる.

Options:
  -h, --help  Show this help message and exit.
  --format FORMAT
              Input file format. [default: extxyz]
  -d DR       Width of the bin. [default: 0.1]
  -r,--rmax RMAX
              Cutoff radius of radial distribution. [default: 5.0]
  --rmin RMIN
              Minimum radius to be considered. [default: 0.0]
  --gsmear=SIGMA
              Width of Gaussian smearing, zero means no smearing. [default: 0]
  --nnmax=NNMAX
              Max num of neighbors when counting neighbors. [default: 100]
  -o OUT      Name of file to be written in addition to out.rdf if specified.
              [default: None]
  --specorder=SPECORDER
              Order of species separated by comma, like, --specorder=W,H.
              [default: None]
  --out4fp    Flag to write out in general fp.py format. [default: False]
  --pairs PAIRS
              Pairs to be extracted, available only if out4fp is specified.
              hyphen-connected, comma separated, e.g.) Li-O,P-O [default: None]
  --skip=NSKIP
              Skip first NSKIP steps from the statistics. [default: 0]
  --no-pairwise
              Not to take averaging by pairwise.
  --plot      Plot figures. [default: False]
  --SQ        Calc and output S(Q) converted from RDF to out.sq
  --qmax QMAX    Cutoff wavenumber. [default: 20.0]
  --qmin QMIN    Shortest wavenumber. [default: 0.7]
  --scatter-length LENGTHS
              Scattering lengths of corresponding species in Angstrom.
              [default: None]
  --fortran   Try using fortran function for computing RDF.
  --progress  Show progress. [default: False]
  • もし nappy/pmd/pmd_wrapper のコンパイルがされていれば,--fortranオプションで近接原子探索を大幅に高速化することができる.
  • --gsmear=SIGMA:RDFのgaussian smearingを行う.引数 SIGMA は gaussian sigma としてデータ点の何点分とするかという値.

image


ADF

rdf.pyとほぼ同じ形式だが,下記のように --triplets で計算する3つの元素の組(i,j,k)を指定する.このとき, j-i-k の間の角を指定していることになる.

python ~/src/nap/nappy/adf.py --fortran --gsmear=1 --triplets=Si-O-O,O-Si-Si --skip=50 --progress traj.extxyz

image