Skip to content

l716.thermochemistry.mass ​

Implementation level ​

TypeStatus
CML extraction template
HTML5 representation

Template attributes ​

AttributeValue
sourceGaussian log
idl716.thermochemistry.mass
repeat*
pattern\s* Atom.*has atomic number.*and mass.*
endPattern\s*Molecular mass.*
endOffset1
xml:basel716/thermochemistry/l716.thermochemistry.mass.xml

Input ​

 Atom  1 has atomic number  6 and mass  12.00000
 Atom  2 has atomic number  6 and mass  12.00000
 Atom 13 has atomic number 17 and mass  34.96885
 Molecular mass:   146.97683 amu.

Output text ​

xml
<comment class="example.output" id="l716.thermochemistry.mass">
    <module cmlx:templateRef="l716.thermochemistry.mass">
      <list cmlx:lineCount="3" cmlx:templateRef="mass">
        <array dataType="xsd:integer" dictRef="cc:serial" size="3">1 2 13</array>
        <array dataType="xsd:integer" dictRef="x:elementType" size="3">6 6 17</array>
        <array dataType="xsd:double" dictRef="cc:atomicmass" size="3">12.0 12.0 34.96885</array>
      </list>
      <scalar dataType="xsd:double" dictRef="cc:molmass" cmlx:templateRef="molmass">146.97683</scalar>
    </module>
  </comment>

Template definition ​

xml
<record id="mass" repeat="*" makeArray="true">\s* Atom&#123;I,cc:serial&#125;has atomic number&#123;I,x:elementType&#125; and mass&#123;F,cc:atomicmass&#125;\s*</record>
<record id="molmass">\s*Molecular mass:&#123;F,cc:molmass&#125;amu\.\s*</record>
<transform process="pullupSingleton" xpath="./cml:list[@cmlx:templateRef='molmass']" />