OQMath example document

<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<!DOCTYPE omdoc SYSTEM "../dtd/activemath.dtd" [  
]>
<omdoc id='topDiff_intro_omdoc'>

  <?QMath Context:"Mathematics/Arithmetic" ?>
  <?QMath Context:"Mathematics/Logic" ?>
  <?QMath Context:"Mathematics/Set_theory"?>
  <?QMath Context:"Mathematics/OMDoc"?>
  <?QMath Context:"Mathematics/ActiveMath"?>
  <?QMath Context:"Mathematics/OpenMath/set1"?>
  
  <?QMath Symbol: apply OP_EXP "ai_elementary:map_application" ?>

  <!--||  the set of n-uples of real numbers  -->
  <?QMath Symbol:   Rn    SYMBOL    "topDiff_prerequisites:Rn" ?>
  <!--||   Rn = { (x1, ..., xn) | xi in R }  -->
  
  <!--|| the projection (x1, ..., xn) |-> xk -->
  <?QMath Symbol:   π   APPLICATION "topDiff_prerequisites:projection" ?>
  <!--||  we should be using the |R symbol  -->
  
  <!--||  the norm function on euclidean space points  -->
  <?QMath Symbol:   norm  APPLICATION "topDiff_prerequisites:norm"   ?>
  <?QMath Symbol:   Bn    SYMBOL    "topDiff_intro:ball" ?>
  
  <!--||  this symbol would probably need a real content-dictionary but it is not  -->
  <!--||  really well defined  -->
  <!--|| also its syntax would appreciate a markup like f: A -> B -->
  <!--||  it means let f be an map from A to B  -->
  <?QMath Symbol:   named_map   APPLICATION   "topDiff_prerequesites:named_map"  ?>
  
  <!--||  same thing but with no name  -->
  <?QMath Symbol:   unnamed_map   APPLICATION   "topDiff_prerequesites:unnamed_map" ?>
  
  <!--||  the restriction of a map to a subset  -->
  <!--||  haven't found this in the openmath CDs  -->
  <?QMath Symbol:   restr     OP_PLUS     "topDiff_prerequesites:restriction" ?>

  
  <metadata>
    <Title>
      Introduction à la topologie différentielle
    </Title>
    <Contributor role='aut'>Fernand Beaudet</Contributor>
    <Date>2001-02-25</Date>
  </metadata>


  <theory id='topDiff_intro'>

    <symbol id='demi_espace'>
      <commonname xml:lang="en">Half-space of a euclidean space</commonname>
      <commonname xml:lang="fr">Demi-espace d'un espace euclidien</commonname>
    </symbol>
    <?QMath Symbol:   Hn    SYMBOL    "topDiff_intro:demi_espace" ?>
    <presentation id='demi_espace_pres' for='demi_espace'>
      <use format='TeX'>{\H}^n</use>
      <use format='HTML'>|H&lt;sup&gt;n&lt;/sup&gt;</use>
    </presentation>

    <definition id='def_demi_espace' for='demi_espace'>
      <metadata>
        <Title xml:lang="fr">Définition du demi-espace d'un espace euclidien</Title>
        <Title xml:lang="en">Definition of the half-space of a euclidean space</Title>
        <extradata>
          <depends-on>
            <ref xref="Rn"/>
          </depends-on>
        </extradata>
      </metadata>
      <CMP xml:lang="fr">
        On apelle demi-espace et l'on note $Hn$ l'ensemble des points de $Rn$
        dont la dernière composante est positive:  
          $Hn = set(x | x ∈ Rn ∧ π(n,x) &gt; 0)$
      </CMP>
      <CMP xml:lang="en">
        The set of points of $Rn$ whose last component is positive is called
        the half-space:
          $Hn = set(x | x ∈ Rn ∧ π(n,x) &gt; 0)$
      </CMP>
    </definition>


    <symbol id='bord'>
      <commonname xml:lang="fr">Bord d'une variété</commonname>
    </symbol>
    <?QMath   Symbol: bord APPLICATION  "topDiff_intro:bord" ?>
    <?QMath   Symbol: ∂ APPLICATION   "topDiff_intro:bord" ?>
    <presentation id='bord_pres' for='bord' parent='OMA' fixity='infix'>
      <use format='TeX'>\partial</use>
      <use format='HTML'>∂</use>
    </presentation>

    <symbol id='application_lisse'>
      <commonname xml:lang="fr">Application lisse</commonname>
    </symbol>
    <?QMath   Symbol: C_infty SYMBOL "topDiff_intro:application_lisse" ?>
    <presentation id='application_lisse_pres' for='application_lisse' parent='OMA' fixity='infix'>
      <use format='TeX'>C^\infinity</use>
      <use format='HTML'>C&lt;sup&gt;&amp;infty;&lt;/sup&gt;</use>
    </presentation>

    <symbol id='n_ball'>
      <commonname xml:lang="en">n-dimensional closed ball</commonname>
      </symbol>
    <?QMath Symbol: n_ball SYMBOL  "topDiff_intro:n_ball" ?>
    <presentation id='n_ball_pres' for='n_ball' parent='OMA' fixity='infix'>
      <use format='TeX'>B_n</use>
      <use format='HTML'>B&lt;sub&gt;n&lt;/sub&gt;</use>
    </presentation>
  
  
    <definition id='def_bordHn' for='bord_Hn'>
      <metadata>
        <Title xml:lang="fr">Définition du bord du demi-espace</Title>
        <Title xml:lang="en">Definition of the boundary of the half-space</Title>
      </metadata>
      <!-- no QMath declaration here... it's a compound symbol. Or should I ? -->
      <CMP xml:lang="fr">
        On appelle bord du demi-espace et l'on note $∂(Hn)$ 
         l'ensemble des points de $Rn$ dont la dernière composante est nulle:
          $∂(Hn) = set( x | x ∈ Rn ∧ π(n,x) = 0 )$
      </CMP>
      <CMP xml:lang="en">
        The set of points of $Rn$ whose last component is zero is called the
        boundary of the half space:
          $∂(Hn) = set( x | x ∈ Rn ∧ π(n,x) = 0 )$
      </CMP>
    </definition>

    <!--||  need to define the ∂ symbol  -->

    <definition id='def_application_lisse_Hn' for="application_lisse">
      <metadata>
        <Title xml:lang="fr">application lisse du demi-espace</Title>
      </metadata>
      <CMP xml:lang="fr">
        Soit $named_map(h, U, Rn)$, et $U$ un ouvert de $Hn$, on dit que 
        $h$ est de classe $C_infty$, ou lisse,  si $h$ admet un prolongement de 
        $named_map(g,V,Rn)$ à un ouvert $V$ de $Rn$, $g restr Hn = h$.
      </CMP>
    </definition>

    <?QMath Symbol: tuple   APPLICATION   "list1:list" ?>
  
    <symbol id="carte">
      <commonname xml:lang="fr">Variété</commonname>
    </symbol>

  
    <definition id='def_carte' for="carte">
      <metadata>
        <Title xml:lang="fr">carte</Title>
      </metadata>
      <CMP xml:lang="fr">
        <?QMath Symbol: U_prime VARIABLE "U_prime" ?>
        <?QMath Symbol: V_prime VARIABLE "V_prime" ?>
        Soit $X$ un espace topologique.
        On appelle carte de $X$ || typical place where one would put an italic... meaningful ?
        un couple $tuple(U,φ)$ où $U ⊂ X$ est un ouvert de $X$ et $φ$ est un homéomorphisme
        $named_map(φ, U, U_prime)$, avec $U_prime$, un ouvert de $Hn$.
        On dit qu'un point $x$ appartient à une carte $tuple(U,φ)$ s'il appartient à $U$.
        Étant donnée deux cartes $tuple(U,φ)$ et $tuple(V,ψ)$, on appelle changement de carte 
        la composition $named_map(φ compose linv(ψ), V_prime, U_prime) $, un homéomorphisme d'un ouvert de $Hn$ dans $Hn$.
      </CMP>
    </definition>


  <!-- Not too sure this should be a symbol, at least, it should be 
    a predicate and should not be presented as such (it should not be
    presented at all). -->
    <symbol id='variete'>
      <commonname xml:lang="fr">Variété</commonname>
    </symbol>
    <?QMath Symbol variete "top_diff_intro:variété" ?>
    <!-- <presentation id='variete_pres' for='variete' parent='OMA' fixity='infix'>
      <use format='TeX'>M</use>
      <use format='HTML'>M</use>
    </presentation> -->


    <definition id='def_variete' for="variété">
      <metadata>
        <Title xml:lang="fr">Variété à bord</Title>
      </metadata>
      <CMP xml:lang="fr">
        Soit $tuple(M,T,A)$ un triple <!--||  needs caligraphic letters  -->
        tel que $tuple(M,T)$ est un espace topologique est un 
        <textref xref="espace_top">espace topologique</textref> 
        <textref xref="topDiff_preReqTop/deHausdorff">de Hausdorff</textref> 
        à <textref xref="topDiff_preReqTop/baseDenombrable">base dénombrable</textref> 
        et $A$ est une famille de cartes telle que tout point de $M$ appartient à une carte.
        On appelle alors $tuple(M,T,A)$ une variété et on appelle la famille $A$, 
        un atlas de la variété. Dans les notations, on utilise souvent $M$ pour indiquer, 
        en fait, le triple.
      </CMP>
    </definition>

    <symbol id="variete_lisse">
      <commonname xml:lang="fr">variété lisse'</commonname>
    </symbol>

    <definition id='def_variete_lisse' for="variete_lisse">
      <metadata>
        <Title xml:lang="fr">Variété lisse</Title>
      </metadata>
        <CMP xml:lang="fr">
        Soit $tuple(M,T,A)$ une <textref xref="variete">variété à bord</textref>, 
        $tuple(M,T,A)$ est dite une variété lisse ou variété différentiable 
        ou $C_infty$ si tous les changements de cartes sont lisses.
      </CMP>
    </definition>
  
  
  
    <definition id='def_bord_variete' for='bord'>
      <metadata>
        <Title xml:lang="fr">Bord d'une variété</Title>
      </metadata>
      <CMP xml:lang="fr">
        <?QMath Symbol: U_x VARIABLE "U_x" ?>
        <?QMath Symbol: ψ_x VARIABLE "ψ_x" ?>
        Le bord d'une variété est l'ensemble des points $x$ de $M$ 
        pour lesquels il existe une carte $tuple(U_x,ψ_x)$ 
        telle que $ψ_x apply x ∈ ∂(Hn)$.
      </CMP>
    </definition>
  </theory>
</omdoc>