l101.zmat
Type |
Status |
---|---|
CML extraction template |
|
HTML5 representation |
Attribute |
Value |
---|---|
source |
Gaussian log |
id |
l101.zmat |
repeat |
* |
pattern |
.*Symbolic Z\-matrix.*$\s*Charge.*Multiplicity.*$\s*\S+\s+\S+\s+\S+\s+\S+\s* |
endPattern |
\s* |
xml:base |
l101/l101.zmat.xml |
Input
Symbolic Z-matrix:
Charge = 0 Multiplicity = 1
H 2.67317 -0.69436 1.17604
C 1.98961 -0.3388 0.40746
H 0.63164 1.77722 -0.58197
Input
Symbolic Z-matrix:
Charge = 0 Multiplicity = 1
1 -4.02766 0.28369 0.
1 -4.62766 0.28369 0.
Output text
1<comment class="example.output" id="l1.zmat">
2 <module cmlx:templateRef="l101.zmat">
3 <molecule id="zmat" formalCharge="0" spinMultiplicity="1" cmlx:templateRef="mol">
4 <atomArray>
5 <atom id="a1" elementType="H" x3="2.67317" y3="-0.69436" z3="1.17604">
6 <scalar dataType="xsd:integer" dictRef="cc:atomicNumber">1</scalar>
7 </atom>
8 <atom id="a2" elementType="C" x3="1.98961" y3="-0.3388" z3="0.40746">
9 <scalar dataType="xsd:integer" dictRef="cc:atomicNumber">6</scalar>
10 </atom>
11 <atom id="a3" elementType="H" x3="0.63164" y3="1.77722" z3="-0.58197">
12 <scalar dataType="xsd:integer" dictRef="cc:atomicNumber">1</scalar>
13 </atom>
14 </atomArray>
15 <formula formalCharge="0" concise="C 1 H 2">
16 <atomArray elementType="C H" count="1.0 2.0" />
17 </formula>
18 <bondArray>
19 <bond atomRefs2="a1 a2" id="a1_a2" order="S" />
20 </bondArray>
21 <property dictRef="cml:molmass">
22 <scalar dataType="xsd:double" units="unit:dalton">13.01864</scalar>
23 </property>
24 </molecule>
25 </module>
26 </comment>
Output text
1<comment class="example.output" id="l101.zmat2">
2 <module cmlx:templateRef="l101.zmat">
3 <molecule cmlx:templateRef="mol" formalCharge="0" id="zmat" spinMultiplicity="1">
4 <atomArray>
5 <atom elementType="H" id="a1" x3="-4.02766" y3="0.28369" z3="0.0000" />
6 <atom elementType="H" id="a2" x3="-4.62766" y3="0.28369" z3="0.0000" />
7 </atomArray>
8 <bondArray />
9 <formula concise="H2" />
10 <property dictRef="cml:molmass">
11 <scalar units="unit:dalton">0.0</scalar>
12 </property>
13 <list cmlx:templateRef="charge">
14 <list>
15 <scalar dataType="xsd:integer" dictRef="g:charge">0</scalar>
16 <scalar dataType="xsd:integer" dictRef="g:mult">1</scalar>
17 </list>
18 </list>
19 </molecule>
20 </module>
21 </comment>
Template definition
1<record />
2<record id="charge">.*Charge ={I,g:charge} Multiplicity ={I,g:mult}</record>
3<record id="mol" repeat="*" makeArray="true">{I,gau:elementType} {F,gau:x3,unit:angstrom} {F,gau:y3,unit:angstrom} {F,gau:z3,unit:angstrom}</record>
4<record id="mol" repeat="*" makeArray="true">{A,gau:elementType} {F,gau:x3,unit:angstrom} {F,gau:y3,unit:angstrom} {F,gau:z3,unit:angstrom}</record>
5<transform process="createMolecule" id="zmat" xpath=".//cml:array" />
6<transform process="move" to=".//cml:molecule" xpath="./cml:list[@cmlx:templateRef='charge']" />
7<transform process="addAttribute" xpath=".//cml:molecule[@id='zmat']" name="formalCharge" value="$string(.//cml:scalar[@dictRef='g:charge'])" />
8<transform process="addAttribute" xpath=".//cml:molecule[@id='zmat']" name="spinMultiplicity" value="$string(.//cml:scalar[@dictRef='g:mult'])" />
9<transform process="delete" xpath="./cml:list[@cmlx:templateRef='charge']" />
10<transform process="pullupSingleton" xpath="./cml:list" />