castep.cell

Implementation level

Type

Status

CML extraction template

image1

HTML5 representation

image2

Template attributes

Attribute

Value

source

CASTEP cell

id

castep.cell

name

CASTEP cell

xml:base

topTemplate.xml

Input

%BLOCK LATTICE_CART
       5.430530000000000       0.000000000000000       0.000000000000000
       0.000000000000000       5.430530000000000       0.000000000000000
       0.000000000000000       0.000000000000000       5.430530000000000
%ENDBLOCK LATTICE_CART

%BLOCK POSITIONS_FRAC
 Si   0.0000000000000000    0.0000000000000000    0.0000000000000000
 Si   0.0000000000000000    0.4999999999999999    0.4999999999999999
 Si   0.4999999999999999    0.0000000000000000    0.4999999999999999
 Si   0.4999999999999999    0.4999999999999999    0.0000000000000000
 Si   0.7499999999999999    0.2500000000000000    0.7499999999999999
 Si   0.2500000000000000    0.2500000000000000    0.2500000000000000
 Si   0.2500000000000000    0.7499999999999999    0.7499999999999999
 Si   0.7499999999999999    0.7499999999999999    0.2500000000000000
%ENDBLOCK POSITIONS_FRAC

%BLOCK KPOINTS_LIST
   0.3750000000000000    0.3750000000000000    0.3750000000000000       0.125000000000000
   0.3750000000000000    0.3750000000000000    0.1250000000000000       0.375000000000000
   0.3750000000000000    0.1250000000000000    0.1250000000000000       0.375000000000000
   0.1250000000000000    0.1250000000000000    0.1250000000000000       0.125000000000000
%ENDBLOCK KPOINTS_LIST

%BLOCK SYMMETRY_OPS
       1.000000000000000       0.000000000000000       0.000000000000000
       0.000000000000000       1.000000000000000       0.000000000000000
       0.000000000000000       0.000000000000000       1.000000000000000
       0.000000000000000        0.000000000000000        0.000000000000000
       1.000000000000000       0.000000000000000       0.000000000000000
       ...

       1.000000000000000       0.000000000000000       0.000000000000000
       0.500000000000000        0.500000000000000        0.000000000000000
%ENDBLOCK SYMMETRY_OPS

#SpaceGroup : 227
%BLOCK CELL_CONSTRAINTS
       1       1       1
       0       0       0
%ENDBLOCK CELL_CONSTRAINTS

FIX_COM : false
%BLOCK IONIC_CONSTRAINTS
%ENDBLOCK IONIC_CONSTRAINTS

%BLOCK EXTERNAL_EFIELD
    0.0000000000     0.0000000000     0.0000000000
%ENDBLOCK EXTERNAL_EFIELD

%BLOCK EXTERNAL_PRESSURE
    0.0000000000    0.0000000000    0.0000000000
                    0.0000000000    0.0000000000
                                    0.0000000000
%ENDBLOCK EXTERNAL_PRESSURE

%BLOCK SPECIES_MASS
      Si     28.0849990845
%ENDBLOCK SPECIES_MASS

%BLOCK SPECIES_POT
      Si  3|1.8|3.6|5|7|30UU:31UU:32UU[]
%ENDBLOCK SPECIES_POT

%BLOCK SPECIES_LCAO_STATES
      Si         2
%ENDBLOCK SPECIES_LCAO_STATES

Output text

 1<comment class="example.output" id="castep.cell">
 2        <module id="castep.cell">
 3           <module cmlx:templateRef="lattice">
 4              <list dictRef="ca:axis" id="axis">
 5                 <array dataType="xsd:double" dictRef="cc:latticeA" size="3">5.430530000000000 0.000000000000000 0.000000000000000</array>
 6                 <array dataType="xsd:double" dictRef="cc:latticeB" size="3">0.000000000000000 5.430530000000000 0.000000000000000</array>
 7                 <array dataType="xsd:double" dictRef="cc:latticeC" size="3">0.000000000000000 0.000000000000000 5.430530000000000</array>
 8              </list>
 9           </module>
10           <module cmlx:templateRef="atoms">
11              <list cmlx:templateRef="atom">
12                 <list>
13                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
14                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.0000000000000000</scalar>
15                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.0000000000000000</scalar>
16                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.0000000000000000</scalar>
17                 </list>
18                 <list>
19                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
20                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.0000000000000000</scalar>
21                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.4999999999999999</scalar>
22                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.4999999999999999</scalar>
23                 </list>
24                 <list>
25                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
26                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.4999999999999999</scalar>
27                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.0000000000000000</scalar>
28                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.4999999999999999</scalar>
29                 </list>
30                 <list>
31                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
32                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.4999999999999999</scalar>
33                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.4999999999999999</scalar>
34                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.0000000000000000</scalar>
35                 </list>
36                 <list>
37                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
38                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.7499999999999999</scalar>
39                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.2500000000000000</scalar>
40                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.7499999999999999</scalar>
41                 </list>
42                 <list>
43                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
44                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.2500000000000000</scalar>
45                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.2500000000000000</scalar>
46                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.2500000000000000</scalar>
47                 </list>
48                 <list>
49                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
50                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.2500000000000000</scalar>
51                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.7499999999999999</scalar>
52                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.7499999999999999</scalar>
53                 </list>
54                 <list>
55                    <scalar dataType="xsd:string" dictRef="cc:elementType">Si</scalar>
56                    <scalar dataType="xsd:double" dictRef="cc:xFract">0.7499999999999999</scalar>
57                    <scalar dataType="xsd:double" dictRef="cc:yFract">0.7499999999999999</scalar>
58                    <scalar dataType="xsd:double" dictRef="cc:zFract">0.2500000000000000</scalar>
59                 </list>
60              </list>
61           </module>
62           <module cmlx:templateRef="kpoints">
63              <matrix cols="4" dataType="xsd:double" dictRef="ca:kpoints" rows="4">0.3750000000000000 0.3750000000000000 0.3750000000000000 0.125000000000000 0.3750000000000000 0.3750000000000000 0.1250000000000000 0.375000000000000 0.3750000000000000 0.1250000000000000 0.1250000000000000 0.375000000000000 0.1250000000000000 0.1250000000000000 0.1250000000000000 0.125000000000000</matrix>
64           </module>
65           <molecule id="coordinates">
66              <crystal>
67                 <scalar id="sc1" title="a" units="nonsi:angstrom">5.43053</scalar>
68                 <scalar id="sc2" title="b" units="nonsi:angstrom">5.43053</scalar>
69                 <scalar id="sc3" title="c" units="nonsi:angstrom">5.43053</scalar>
70                 <scalar id="sc4" title="alpha" units="nonsi:degree">90.0</scalar>
71                 <scalar id="sc5" title="beta" units="nonsi:degree">90.0</scalar>
72                 <scalar id="sc6" title="gamma" units="nonsi:degree">90.0</scalar>
73              </crystal>
74              <atomArray>
75                 <atom elementType="Si" id="a1" x3="0.0000" xFract="0.0000" y3="0.0000" yFract="0.0000" z3="0.0000" zFract="0.0000" />
76                 <atom elementType="Si" id="a2" x3="0.0000" xFract="0.0000" y3="2.715265" yFract="0.5000" z3="2.715265" zFract="0.5000" />
77                 <atom elementType="Si" id="a3" x3="2.715265" xFract="0.5000" y3="0.0000" yFract="0.0000" z3="2.715265" zFract="0.5000" />
78                 <atom elementType="Si" id="a4" x3="2.715265" xFract="0.5000" y3="2.715265" yFract="0.5000" z3="0.0000" zFract="0.0000" />
79                 <atom elementType="Si" id="a5" x3="4.0728975" xFract="0.7500" y3="1.3576325" yFract="0.2500" z3="4.0728975" zFract="0.7500" />
80                 <atom elementType="Si" id="a6" x3="1.3576325" xFract="0.2500" y3="1.3576325" yFract="0.2500" z3="1.3576325" zFract="0.2500" />
81                 <atom elementType="Si" id="a7" x3="1.3576325" xFract="0.2500" y3="4.0728975" yFract="0.7500" z3="4.0728975" zFract="0.7500" />
82                 <atom elementType="Si" id="a8" x3="4.0728975" xFract="0.7500" y3="4.0728975" yFract="0.7500" z3="1.3576325" zFract="0.2500" />
83              </atomArray>
84              <bondArray />
85              <formula concise="Si8">
86                 <atomArray count="8" elementType="Si" />
87              </formula>
88              <property dictRef="cml:molmass">
89                 <scalar units="unit:dalton">224.684</scalar>
90              </property>
91           </molecule>
92        </module>
93    </comment>

Template definition

 1<templateList>  <template id="lattice" pattern="\s*\%BLOCK\sLATTICE_CART.*" endPattern="\s*\%ENDBLOCK\sLATTICE_CART.*">    <record repeat="1" />    <record>{3F,cc:latticeA}.*</record>    <record>{3F,cc:latticeB}.*</record>    <record>{3F,cc:latticeC}.*</record>    <transform process="addChild" xpath="." elementName="cml:list" id="axis" />    <transform process="addAttribute" xpath=".//cml:list[@id='axis']" name="dictRef" value="ca:axis" />    <transform process="move" xpath=".//cml:array[@dictRef='cc:latticeA' or @dictRef='cc:latticeB' or @dictRef='cc:latticeC' ]" to=".//cml:list[@id='axis']" />
 2        </template>  <template id="atoms" pattern="\s*\%BLOCK\sPOSITIONS_FRAC.*" endPattern="\s*\%ENDBLOCK\sPOSITIONS_FRAC.*">    <record repeat="1" />    <record repeat="*" id="atom">\s*{A,cc:elementType}{F,cc:xFract}{F,cc:yFract}{F,cc:zFract}.*</record>    <transform process="addChild" xpath=".//cml:list[@cmlx:templateRef='atom']/cml:list" elementName="cml:atom" id="atom" />    <transform process="addAttribute" xpath=".//cml:atom" name="id" value="$string(concat('a', count(preceding::cml:atom)+1))" />    <transform process="addAttribute" xpath=".//cml:atom" name="elementType" value="$string(preceding-sibling::cml:scalar[@dictRef='cc:elementType']/text())" />    <transform process="addAttribute" xpath=".//cml:atom" name="xFract" value="$string(preceding-sibling::cml:scalar[@dictRef='cc:xFract']/text())" />    <transform process="addAttribute" xpath=".//cml:atom" name="yFract" value="$string(preceding-sibling::cml:scalar[@dictRef='cc:yFract']/text())" />    <transform process="addAttribute" xpath=".//cml:atom" name="zFract" value="$string(preceding-sibling::cml:scalar[@dictRef='cc:zFract']/text())" />    <transform process="setValue" xpath=".//cml:atom" value="$string(preceding-sibling::cml:scalar[@dictRef='cc:elementType']/text())" />    <transform process="addChild" xpath="." elementName="cml:atomArray" />    <transform process="move" xpath=".//cml:atom" to="./cml:atomArray" />
 3        </template>  <template id="kpoints" pattern="\s*\%BLOCK\sKPOINTS_LIST.*" endPattern="\s*\%ENDBLOCK\sKPOINTS_LIST">    <record repeat="1" />    <record repeat="*">{4F,ca:kpoint}</record>    <transform process="createMatrix" xpath="." from=".//cml:array[@dictRef='ca:kpoint']" dictRef="ca:kpoints" />    <transform process="pullup" xpath=".//cml:matrix" />
 4        </template>
 5    </templateList>
 6<transform process="createCrystal" xpath=".//cml:atomArray" lattice=".//cml:list[@dictRef='ca:axis']" id="coordinates" connect="no" />
 7<transform process="delete" xpath=".//cml:module[@cmlx:templateRef='atoms']/cml:atomArray" />
 8<transform process="move" xpath="//cml:molecule" to="." />
 9<transform process="delete" xpath=".//cml:list[count(*)=0]" />
10<transform process="delete" xpath=".//cml:list[count(*)=0]" />