C2x: A tool for visualisation and input preparation for Castep and other electronic structure codes
收藏资源简介:
The c2x code fills two distinct roles. Its first role is in acting as a converter between the binary format .check files from the widely-used Castep electronic structure code and various visualisation programs. Its second role is to manipulate and analyse the input and output files from a variety of electronic structure codes, including Castep, Onetep and Vasp, as well as the widely-used ‘Gaussian cube’ file format. Analysis includes symmetry analysis, and manipulation arbitrary cell transformations. It continues to be under development, with growing functionality, and is written in a form which would make it easy to extend it to working directly with files from other electronic structure codes. Data which c2x is capable of extracting from Castep’s binary checkpoint files include charge densities, spin densities, wavefunctions, relaxed atomic positions, forces, the Fermi level, the total energy, and symmetry operations. It can recreate .cell input files from checkpoint files. Volumetric data can be output in formats useable by many common visualisation programs, and c2x will itself calculate integrals, expand data into supercells, and interpolate data via combinations of Fourier and trilinear interpolation. It can extract data along arbitrary lines (such as lines between atoms) as 1D output. C2x is able to convert between several common formats for describing molecules and crystals, including the .cell format of Castep. It can construct supercells, reduce cells to their primitive form, and add specified k-point meshes. It uses the spglib library to report symmetry information, which it can add to .cell files. C2x is a command-line utility, so is readily included in scripts. It is available under the GPL and can be obtained from http://www.c2x.org.uk. It is believed to be the only open-source code which can read Castep’s .check files, so it will have utility in other projects.
c2x工具具备两项截然不同的功能。其一,作为格式转换工具,可实现广泛使用的CASTEP电子结构计算程序生成的二进制.check格式文件与各类可视化程序间的格式转换。其二,可处理并分析多款电子结构计算程序的输入与输出文件,涵盖CASTEP、Onetep、Vasp,以及广泛使用的“Gaussian cube”文件格式。其分析功能包括对称性分析,以及对晶胞的任意变换操作。该工具仍在持续开发中,功能不断丰富,其代码架构设计便于拓展以直接适配其他电子结构计算程序的文件格式。 c2x可从CASTEP的二进制.check文件中提取多种数据,包括电荷密度、自旋密度、波函数、弛豫后的原子位置、受力情况、费米能级、总能量以及对称操作。它还可从.check文件中重建.cell格式的输入文件。体数据可输出为多款常用可视化程序兼容的格式;此外,c2x自身支持积分计算、将数据拓展至超胞,以及通过傅里叶与三线性插值组合的方式实现数据插值。它还可沿任意路径(如原子间连线)提取数据并输出为一维格式。 c2x可实现多款用于描述分子与晶体的常用格式间的转换,其中包括CASTEP的.cell格式。它支持构建超胞、将晶胞简化为原胞,以及添加指定的k点网格。该工具借助spglib库获取对称性信息,并可将此类信息写入.cell文件中。 c2x为命令行工具,可轻松集成至脚本中。该工具基于GPL协议开源,可从http://www.c2x.org.uk获取。据了解,它是目前唯一一款可读取CASTEP的.check文件的开源代码,因此可在其他项目中发挥实用价值。




