+++ /dev/null
-<?xml version="1.0"?>
-
-<!-- Copyright (C) 2000, HELM Team -->
-<!-- -->
-<!-- This file is part of HELM, an Hypertextual, Electronic -->
-<!-- Library of Mathematics, developed at the Computer Science -->
-<!-- Department, University of Bologna, Italy. -->
-<!-- -->
-<!-- HELM is free software; you can redistribute it and/or -->
-<!-- modify it under the terms of the GNU General Public License -->
-<!-- as published by the Free Software Foundation; either version 2 -->
-<!-- of the License, or (at your option) any later version. -->
-<!-- -->
-<!-- HELM is distributed in the hope that it will be useful, -->
-<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
-<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
-<!-- GNU General Public License for more details. -->
-<!-- -->
-<!-- You should have received a copy of the GNU General Public License -->
-<!-- along with HELM; if not, write to the Free Software -->
-<!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, -->
-<!-- MA 02111-1307, USA. -->
-<!-- -->
-<!-- For details, see the HELM World-Wide-Web page, -->
-<!-- http://cs.unibo.it/helm/. -->
-
-<!--******************************************************************-->
-<!-- Algebra -->
-<!-- First draft: October 2001 -->
-<!-- HELM Group: Asperti, Padovani, Sacerdoti, Schena, Guidi -->
-<!--******************************************************************-->
-
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:m="http://www.w3.org/1998/Math/MathML"
- xmlns:helm="http://www.cs.unibo.it/helm">
-
-
-<!-- ************************* ALGEBRA *********************************-->
-
-
-
-<!-- 0 and 1 -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CSemiGroups/csg_unit.con']" mode="pure">
- <m:ci definitionURL="{CONST/@uri}" helm:xref="{@id}">0</m:ci>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/cr_one.con']" mode="pure">
- <m:ci definitionURL="{CONST/@uri}" helm:xref="{@id}">1</m:ci>
-</xsl:template>
-
-<!-- Unary Operations -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CGroups/cg_inv.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CMetricFields/CMetric_Fields/cmf_abs.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'abs'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- inv (uri errata)
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/exponentiation/nexp.con']" mode="pure">
- <xsl:variable name="mbody1">
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <xsl:variable name="mbody2">
- <m:cn>1</m:cn>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- <xsl:with-param name="mbody" select="$mbody2"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'power'"/>
- <xsl:with-param name="mbody" select="$mbody1"/>
- </xsl:call-template>
-</xsl:template>
--->
-
-<!-- Binary Operations and Relations -->
-
-<!-- setoid equality -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CSetoids/cs_eq.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'eq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- apart -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CSetoids/cs_ap.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'neq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/COrdFields/leEq.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'leq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/COrdFields/cof_less.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'lt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!--
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rge.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'geq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rgt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'gt'"/>
- </xsl:call-template>
-</xsl:template>
--->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/cr_plus.con' or
-CONST/@uri='cic:/Algebra/CSemiGroups/csg_op.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'plus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/cr_minus.con' or
- CONST/@uri='cic:/Algebra/CGroups/cg_minus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/cr_mult.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'times'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CFields/cf_div.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'divide'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/Ring_constructions/nzpro.con' and count(*)='4']" mode="pure">
- <xsl:apply-templates select="*[3]" mode="pure"/>
-</xsl:template>
-
-<!--
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rbasic_fun/Rmin.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'min'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rbasic_fun/Rmax.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'max'"/>
- </xsl:call-template>
-</xsl:template>
--->
-
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/exponentiation/nexp.con']" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="$no_params"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'power'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CRings/exponentiation/nexp_op.con' or CONST/@uri='cic:/Algebra/Expon/Zexp_def/zexp.con']" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:variable name="mbody">
- <xsl:apply-templates mode="noannot" select="*[3+$no_params]"/>
- <xsl:apply-templates mode="noannot" select="*[2+$no_params]"/>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="hide" select="$no_params"/>
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'power'"/>
- <xsl:with-param name="mbody" select="$mbody"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/COrdFields/absSmall.con']" mode="pure">
- <xsl:variable name="mbody">
- <m:apply helm:xref="{@id}">
- <m:abs definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[4]" mode="noannot"/>
- </m:apply>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'lt'"/>
- <xsl:with-param name="mbody" select="$mbody"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST[
- attribute::uri='cic:/Algebra/COrdFields/OrdField_Cauchy/seqLimit.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="count(child::*) = 3+$no_params">
- <m:apply helm:xref="{@id}">
- <m:eq definitionURL="{CONST/@uri}" helm:xref="{@id}" />
- <xsl:choose>
- <xsl:when test="name(*[2+$no_params]) = 'LAMBDA'">
- <m:apply helm:xref="{CONST/@id}">
- <m:limit definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <m:bvar>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- </m:bvar>
- <m:lowlimit>
- <m:infinity/>
- </m:lowlimit>
- <xsl:apply-templates select="*[2+$no_params]/target/*[1]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{CONST/@id}">
- <m:limit definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <m:bvar>
- <m:ci>$x</m:ci>
- </m:bvar>
- <m:lowlimit>
- <m:infinity/>
- </m:lowlimit>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST[
- attribute::uri='cic:/Algebra/CSums/Sums/sum0.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="count(child::*) = 3+$no_params">
- <xsl:choose>
- <xsl:when test="name(*[3+$no_params]) = 'LAMBDA'">
- <m:apply helm:xref="{CONST/@id}">
- <m:sum definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <m:bvar>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- </m:bvar>
- <m:condition>
- <m:apply>
- <m:lt/>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- <xsl:apply-templates mode="noannot" select="*[2+$no_params]"/>
- </m:apply>
- </m:condition>
- <xsl:apply-templates select="*[3+$no_params]/target/*[1]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{CONST/@id}">
- <m:sum definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <m:bvar>
- <m:ci>$x</m:ci>
- </m:bvar>
- <m:condition>
- <m:apply>
- <m:lt/>
- <m:ci>$x</m:ci>
- <xsl:apply-templates mode="noannot" select="*[2+$no_params]"/>
- </m:apply>
- </m:condition>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- sum -->
-<xsl:template match="APPLY[CONST[
- attribute::uri='cic:/Algebra/CSums/Sums/sum.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="count(child::*) = 4+$no_params">
- <xsl:choose>
- <xsl:when test="name(*[4+$no_params]) = 'LAMBDA'">
- <m:apply helm:xref="{CONST/@id}">
- <m:sum definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <m:bvar>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- </m:bvar>
- <m:lowlimit>
- <xsl:apply-templates mode="noannot" select="*[2+$no_params]"/>
- </m:lowlimit>
- <m:uplimit>
- <xsl:apply-templates mode="noannot" select="*[3+$no_params]"/>
- </m:uplimit>
- <xsl:apply-templates select="*[4+$no_params]/target/*[1]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{CONST/@id}">
- <m:sum definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <m:bvar>
- <m:ci>$x</m:ci>
- </m:bvar>
- <m:lowlimit>
- <xsl:apply-templates mode="noannot" select="*[2+$no_params]"/>
- </m:lowlimit>
- <m:uplimit>
- <xsl:apply-templates mode="noannot" select="*[3+$no_params]"/>
- </m:uplimit>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- polynomials -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Algebra/CPolynomials/CPoly_CRing_ctd/cpoly_apply_fun.con']" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="count(child::*) = 3+$no_params">
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates mode="noannot" select="*[2+$no_params]"/>
- <xsl:apply-templates mode="noannot" select="*[3+$no_params]"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-</xsl:stylesheet>
-
-
<xsl:import href="objcontent.xsl"/>
-<xsl:key name="id" use="@id" match="LAMBDA|LETIN|PROD|CAST|REL|SORT|APPLY|VAR|META|CONST|MUTIND|MUTCONSTRUCT|MUTCASE|FIX|COFIX|ConstantType|ConstantBody|CurrentProof|InductiveDefinition|Variable"/>
+<xsl:key name="id" use="@id" match="LAMBDA|LETIN|PROD|CAST|REL|SORT|APPLY|VAR|META|CONST|MUTIND|MUTCONSTRUCT|MUTCASE|FIX|COFIX|instantiate|ConstantType|ConstantBody|CurrentProof|InductiveDefinition|Variable"/>
<xsl:template match="ConstantType|ConstantBody|CurrentProof|InductiveDefinition|Variable">
<xsl:variable name="id" select="@id"/>
</xsl:choose>
</xsl:template>
-<xsl:template match="LAMBDA|LETIN|PROD|CAST|REL|SORT|APPLY|VAR|META|CONST|MUTIND|MUTCONSTRUCT|MUTCASE|FIX|COFIX">
+<xsl:template match="LAMBDA|LETIN|PROD|CAST|REL|SORT|APPLY|VAR|META|CONST|MUTIND|MUTCONSTRUCT|MUTCASE|FIX|COFIX|instantiate">
<xsl:variable name="id" select="@id"/>
<xsl:choose>
<xsl:when test="$annotations='yes' and $CICAnnotations/Annotations/Annotation[@of=$id]">
+++ /dev/null
-<?xml version="1.0"?>
-
-<!-- Copyright (C) 2000, HELM Team -->
-<!-- -->
-<!-- This file is part of HELM, an Hypertextual, Electronic -->
-<!-- Library of Mathematics, developed at the Computer Science -->
-<!-- Department, University of Bologna, Italy. -->
-<!-- -->
-<!-- HELM is free software; you can redistribute it and/or -->
-<!-- modify it under the terms of the GNU General Public License -->
-<!-- as published by the Free Software Foundation; either version 2 -->
-<!-- of the License, or (at your option) any later version. -->
-<!-- -->
-<!-- HELM is distributed in the hope that it will be useful, -->
-<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
-<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
-<!-- GNU General Public License for more details. -->
-<!-- -->
-<!-- You should have received a copy of the GNU General Public License -->
-<!-- along with HELM; if not, write to the Free Software -->
-<!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, -->
-<!-- MA 02111-1307, USA. -->
-<!-- -->
-<!-- For details, see the HELM World-Wide-Web page, -->
-<!-- http://cs.unibo.it/helm/. -->
-
-<!--******************************************************************-->
-<!-- Arithmetics -->
-<!-- First draft: March 20 2001, Ferruccio Guidi -->
-<!-- Zarith: July 2001, Andrea Asperti -->
-<!--******************************************************************-->
-
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:m="http://www.w3.org/1998/Math/MathML"
- xmlns:helm="http://www.cs.unibo.it/helm">
-
-<!-- ************************** ARITHMETICS ****************************** -->
-
-<!-- S and O -->
-<xsl:template match="APPLY[*[position()=1 and name()='MUTCONSTRUCT' and @uri='cic:/Coq/Init/Datatypes/nat.ind' and @noConstr='2'] and count(*)=2]" mode="pure">
- <xsl:apply-templates select="*[2]" mode="succ">
- <xsl:with-param name="n" select="1"/>
- <xsl:with-param name="iden" select="@id"/>
- </xsl:apply-templates>
-</xsl:template>
-
-<xsl:template match="*" mode="succ">
- <xsl:param name="n" select="0"/>
- <xsl:param name="iden" select="''"/>
- <xsl:choose>
- <xsl:when test="name()='APPLY' and *[position()=1 and name()='MUTCONSTRUCT'
-and @uri='cic:/Coq/Init/Datatypes/nat.ind' and @noConstr='2']">
- <xsl:apply-templates select="*[2]" mode="succ">
- <xsl:with-param name="n" select="$n +1"/>
- <xsl:with-param name="iden" select="$iden"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:when test="name()='MUTCONSTRUCT' and @uri='cic:/Coq/Init/Datatypes/nat.ind' and @noConstr='1'">
- <m:cn helm:xref="{$iden}"><xsl:value-of select="$n"/></m:cn>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{$iden}">
- <m:plus/>
- <m:cn><xsl:value-of select="$n"/></m:cn>
- <xsl:apply-templates select="." mode="pure"/>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-
-<xsl:template match="APPLY[MUTIND/@uri='cic:/Coq/Init/Peano/le.ind']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="MUTIND"/>
- <xsl:with-param name="m-tag" select="'leq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Init/Peano/lt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'lt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Init/Peano/ge.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'geq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Init/Peano/gt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'gt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Init/Peano/plus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'plus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Arith/Minus/minus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Init/Peano/mult.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'times'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Arith/Min/min.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'min'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- **************************** Zarith ******************************** -->
-
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/Zle.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'leq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/Zlt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'lt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/Zge.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'geq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/Zgt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'gt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/fast_integer/Zplus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'plus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/Zminus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/fast_integer/Zopp.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/fast_integer/Zmult.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'times'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/Zmin.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'min'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/ZArith/zarith_aux/absolu.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'abs'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- POS, NEG e ZERO -->
-
-<xsl:template match="APPLY[*[position()=1 and name()='MUTCONSTRUCT' and @uri='cic:/Coq/ZArith/fast_integer/Z.ind' and @noConstr='2'] and count(*)=2]" mode="pure">
- <xsl:apply-templates select="*[2]" mode="Zpositive">
- <xsl:with-param name="base" select="0"/>
- <xsl:with-param name="exp" select="1"/>
- <xsl:with-param name="iden" select="*[2]/@id"/>
- </xsl:apply-templates>
-</xsl:template>
-
-<xsl:template match="APPLY[*[position()=1 and name()='MUTCONSTRUCT' and @uri='cic:/Coq/ZArith/fast_integer/Z.ind' and @noConstr='3'] and count(*)=2]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:minus definitionURL="{*[1]/@uri}" helm:xref="{*[1]/@id}"/>
- <xsl:apply-templates select="*[2]" mode="Zpositive">
- <xsl:with-param name="base" select="0"/>
- <xsl:with-param name="exp" select="1"/>
- <xsl:with-param name="iden" select="*[2]/@id"/>
- </xsl:apply-templates>
- </m:apply>
-</xsl:template>
-
-<xsl:template match="MUTCONSTRUCT[@uri='cic:/Coq/ZArith/fast_integer/Z.ind' and @noConstr='1']" mode="pure">
- <m:ci definitionURL="{@uri}" helm:xref="{@id}">0</m:ci>
-</xsl:template>
-
-<!-- prova di notazione per positive -->
-
-<xsl:template match="APPLY[*[position()=1 and name()='MUTCONSTRUCT' and @uri='cic:/Coq/ZArith/fast_integer/positive.ind']]" mode="pure">
- <xsl:apply-templates select="." mode="Zpositive">
- <xsl:with-param name="base" select="0"/>
- <xsl:with-param name="exp" select="1"/>
- <xsl:with-param name="iden" select="@id"/>
- </xsl:apply-templates>
-</xsl:template>
-
-<xsl:template match="MUTCONSTRUCT[@uri='cic:/Coq/ZArith/fast_integer/positive.ind' and @noConstr='3']" mode="pure">
- <m:ci definitionURL="{@uri}" helm:xref="{@id}">1</m:ci>
-</xsl:template>
-
-<xsl:template match="*" mode="Zpositive">
- <xsl:param name="base" select="0"/>
- <xsl:param name="exp" select="1"/>
- <xsl:param name="iden" select="''"/>
- <xsl:choose>
- <xsl:when test="name()='APPLY' and *[position()=1 and name()='MUTCONSTRUCT'
-and @uri='cic:/Coq/ZArith/fast_integer/positive.ind' and @noConstr='1']">
- <xsl:apply-templates select="*[2]" mode="Zpositive">
- <xsl:with-param name="base" select="$base + $exp"/>
- <xsl:with-param name="exp" select="2 * $exp"/>
- <xsl:with-param name="iden" select="$iden"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:when test="name()='APPLY' and *[position()=1 and name()='MUTCONSTRUCT'
-and @uri='cic:/Coq/ZArith/fast_integer/positive.ind' and @noConstr='2']">
- <xsl:apply-templates select="*[2]" mode="Zpositive">
- <xsl:with-param name="base" select="$base"/>
- <xsl:with-param name="exp" select="2 * $exp"/>
- <xsl:with-param name="iden" select="$iden"/>
- </xsl:apply-templates>
- </xsl:when>
- <xsl:when test="name()='MUTCONSTRUCT' and @uri='cic:/Coq/ZArith/fast_integer/positive.ind' and @noConstr='3'">
- <m:ci helm:xref="{$iden}"><xsl:value-of select="$base + $exp"/></m:ci>
- </xsl:when>
- <xsl:otherwise>
- <xsl:choose>
- <xsl:when test="$base = 0">
- <xsl:choose>
- <xsl:when test="$exp = 1">
- <xsl:apply-templates select="." mode="pure"/>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{$iden}">
- <m:times/>
- <m:ci><xsl:value-of select="$exp"/></m:ci>
- <xsl:apply-templates select="." mode="pure"/>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{$iden}">
- <m:plus/>
- <m:ci><xsl:value-of select="$base"/></m:ci>
- <xsl:choose>
- <xsl:when test="$exp = 1">
- <xsl:apply-templates select="." mode="pure"/>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{$iden}">
- <m:times/>
- <m:ci><xsl:value-of select="$exp"/></m:ci>
- <xsl:apply-templates select="." mode="pure"/>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-
-</xsl:stylesheet>
+++ /dev/null
-<?xml version="1.0"?>
-
-<!-- Copyright (C) 2000, HELM Team -->
-<!-- -->
-<!-- This file is part of HELM, an Hypertextual, Electronic -->
-<!-- Library of Mathematics, developed at the Computer Science -->
-<!-- Department, University of Bologna, Italy. -->
-<!-- -->
-<!-- HELM is free software; you can redistribute it and/or -->
-<!-- modify it under the terms of the GNU General Public License -->
-<!-- as published by the Free Software Foundation; either version 2 -->
-<!-- of the License, or (at your option) any later version. -->
-<!-- -->
-<!-- HELM is distributed in the hope that it will be useful, -->
-<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
-<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
-<!-- GNU General Public License for more details. -->
-<!-- -->
-<!-- You should have received a copy of the GNU General Public License -->
-<!-- along with HELM; if not, write to the Free Software -->
-<!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, -->
-<!-- MA 02111-1307, USA. -->
-<!-- -->
-<!-- For details, see the HELM World-Wide-Web page, -->
-<!-- http://cs.unibo.it/helm/. -->
-
-<!--******************************************************************-->
-<!-- Basic Logic -->
-<!-- First draft: April 3 2000 -->
-<!-- HELM Group: Asperti, Padovani, Sacerdoti, Schena, Guidi -->
-<!--******************************************************************-->
-
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:m="http://www.w3.org/1998/Math/MathML"
- xmlns:helm="http://www.cs.unibo.it/helm">
-
-
-<!-- ************************* LOGIC *********************************-->
-
-<!-- AND -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Logic/and.ind'] and (count(child::*) = 3)]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:and definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- </m:apply>
-</xsl:template>
-
-<!-- OR -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Logic/or.ind'] and (count(child::*) = 3)]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:or definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- </m:apply>
-</xsl:template>
-
-<!-- NOT -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Init/Logic/not.con'] and (count(child::*) = 2)]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:not definitionURL="{CONST/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- </m:apply>
-</xsl:template>
-
-<!-- IFF -->
-<!--
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Init/Logic/Equivalence/iff.ind'] and (count(child::*) = 3)]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:iff definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- </m:apply>
-</xsl:template>
--->
-
-<!-- EXISTS -->
-
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Logic/ex.ind' or attribute::uri='cic:/Coq/Init/Logic_Type/exT.ind'] and (count(child::*) = 3)]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:exists definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:choose>
- <xsl:when test="name(*[3]) = 'LAMBDA'">
- <m:bvar>
- <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="*[3]/*[1]/@binder"/></xsl:with-param></xsl:call-template></m:ci>
- </m:bvar>
- <m:condition>
- <xsl:apply-templates select="*[2]" mode="pure"/>
- </m:condition>
- <xsl:apply-templates select="LAMBDA/target" mode="noannot"/>
- </xsl:when>
- <xsl:otherwise>
- <m:bvar>
- <m:ci>$x</m:ci>
- </m:bvar>
- <m:condition>
- <xsl:apply-templates select="*[2]" mode="pure"/>
- </m:condition>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </m:apply>
-</xsl:template>
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Logic/ex2.ind' or attribute::uri='cic:/Coq/Init/Logic_Type/exT2.ind'] and (count(child::*) = 4)]" mode="pure">
- <m:apply helm:xref="{@id}">
- <m:exists definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:choose>
- <xsl:when test="name(*[3]) = 'LAMBDA'">
- <xsl:variable name="bvarname" select="*[3]/*[1]/@binder"/>
- <m:bvar>
- <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="$bvarname"/></xsl:with-param></xsl:call-template></m:ci>
- </m:bvar>
- <m:condition>
- <xsl:apply-templates select="LAMBDA[1]/target" mode="noannot"/>
- </m:condition>
- <xsl:choose>
- <xsl:when test="(name(*[4]) = 'LAMBDA') and
- ($bvarname = *[4]/*[1]/@binder)">
- <xsl:apply-templates select="LAMBDA[2]/target" mode="noannot"/>
- </xsl:when>
- <xsl:otherwise>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[4]" mode="noannot"/>
- <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="$bvarname"/></xsl:with-param></xsl:call-template></m:ci>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <xsl:choose>
- <xsl:when test="name(*[4]) = 'LAMBDA'">
- <xsl:variable name="bvarname" select="*[4]/*[1]/@binder"/>
- <m:bvar>
- <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="$bvarname"/></xsl:with-param></xsl:call-template></m:ci>
- </m:bvar>
- <m:condition>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="$bvarname"/></xsl:with-param></xsl:call-template></m:ci>
- </m:apply>
- </m:condition>
- <xsl:apply-templates select="*[4]/target" mode="noannot"/>
- </xsl:when>
- <xsl:otherwise>
- <m:bvar>
- <m:ci>x</m:ci>
- </m:bvar>
- <m:condition>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- <m:ci>x</m:ci>
- </m:apply>
- </m:condition>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[4]" mode="noannot"/>
- <m:ci>x</m:ci>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:otherwise>
- </xsl:choose>
- </m:apply>
-</xsl:template>
-
-
-<!-- EQUALITY and TYPE EQUALITY -->
-
-<xsl:template match="APPLY[MUTIND/@uri='cic:/Coq/Init/Logic/eq.ind']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="MUTIND"/>
- <xsl:with-param name="m-tag" select="'eq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[MUTIND/@uri='cic:/Coq/Init/Logic_Type/eqT.ind']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="hide" select="1"/>
- <xsl:with-param name="c-tag" select="MUTIND"/>
- <xsl:with-param name="m-tag" select="'eq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- NOT-EQ -->
-<!-- NOT and EQ have no parameters -->
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Init/Logic/not.con']
-and (count(child::*) = 2) and APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Logic/eq.ind']]]" mode="pure">
- <xsl:choose>
- <xsl:when test="count(APPLY/child::*) = 4">
- <m:apply helm:xref="{@id}">
- <m:neq/>
- <xsl:apply-templates select="*[2]/*[3]" mode="noannot"/>
- <xsl:apply-templates select="*[2]/*[4]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- NOT-EQT -->
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Init/Logic/not.con']
-and (count(child::*) = 2) and APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Logic_Type/eqT.ind']]]" mode="pure">
- <xsl:choose>
- <xsl:when test="count(APPLY/child::*) = 4">
- <m:apply helm:xref="{@id}">
- <m:neq/>
- <xsl:apply-templates select="*[2]/*[3]" mode="noannot"/>
- <xsl:apply-templates select="*[2]/*[4]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- ************************ DATATYPES ******************************* -->
-
-<!-- no datatypes in MathML content -->
-
-<!-- ************************** PEANO ********************************* -->
-
-<!-- see arith.xsl --> <!-- FG -->
-
-</xsl:stylesheet>
<xsl:when test="$name='cast'">
<xsl:text>(</xsl:text>
<xsl:apply-templates mode="inline" select="*[position()=2]"/>
- <xsl:text>:></xsl:text>
+ <xsl:text>:</xsl:text>
<xsl:apply-templates mode="inline" select="*[position()=3]"/>
<xsl:text>)</xsl:text>
</xsl:when>
select="./*[1]"/>
</xsl:for-each>
</xsl:when>
+
+ <xsl:when test="$name='inst'">
+ <xsl:apply-templates select="*[1]" mode="inline"/>
+ <FONT color="blue">{</FONT>
+ <xsl:text>trjsh</xsl:text>
+ <xsl:apply-templates select="*[2]" mode="args"/>
+ <FONT color="blue">}</FONT>
+ </xsl:when>
<!-- FIX -->
<xsl:when test="$name='fix'">
<FONT color="red">FIX</FONT>
+++ /dev/null
-<?xml version="1.0"?>
-
-<!-- Copyright (C) 2000, HELM Team -->
-<!-- -->
-<!-- This file is part of HELM, an Hypertextual, Electronic -->
-<!-- Library of Mathematics, developed at the Computer Science -->
-<!-- Department, University of Bologna, Italy. -->
-<!-- -->
-<!-- HELM is free software; you can redistribute it and/or -->
-<!-- modify it under the terms of the GNU General Public License -->
-<!-- as published by the Free Software Foundation; either version 2 -->
-<!-- of the License, or (at your option) any later version. -->
-<!-- -->
-<!-- HELM is distributed in the hope that it will be useful, -->
-<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
-<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
-<!-- GNU General Public License for more details. -->
-<!-- -->
-<!-- You should have received a copy of the GNU General Public License -->
-<!-- along with HELM; if not, write to the Free Software -->
-<!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, -->
-<!-- MA 02111-1307, USA. -->
-<!-- -->
-<!-- For details, see the HELM World-Wide-Web page, -->
-<!-- http://cs.unibo.it/helm/. -->
-
-<!--******************************************************************-->
-<!-- Reals -->
-<!-- First draft: April 3 2000 -->
-<!-- HELM Group: Asperti, Padovani, Sacerdoti, Schena, Guidi -->
-<!--******************************************************************-->
-
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:m="http://www.w3.org/1998/Math/MathML"
- xmlns:helm="http://www.cs.unibo.it/helm">
-
-
-<!-- ************************* LOGIC *********************************-->
-
-<!-- REALS -->
-
-<!--
-<xsl:template match="CONST[attribute::uri='cic:/Coq/Reals/Rdefinitions/R.con']" mode="pure">
- <m:reals/>
-</xsl:template>
--->
-
-<!-- 0 e 1 -->
-
-<xsl:template match="CONST[attribute::uri='cic:/Coq/Reals/Rdefinitions/R0.con']" mode="pure">
- <m:cn definitionURL="{@uri}" helm:xref="{@id}">0</m:cn>
-</xsl:template>
-
-<xsl:template match="CONST[attribute::uri='cic:/Coq/Reals/Rdefinitions/R1.con']" mode="pure">
- <m:cn definitionURL="{@uri}" helm:xref="{@id}">1</m:cn>
-</xsl:template>
-
-<!-- Unary Operations and power -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Ropp.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rbasic_fun/Rabsolu.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'abs'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rfunctions/fact.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'factorial'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rbase/Rsqr.con']" mode="pure">
- <xsl:variable name="mbody">
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <m:cn>2</m:cn>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'power'"/>
- <xsl:with-param name="mbody" select="$mbody"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rinv.con']" mode="pure">
- <xsl:variable name="mbody1">
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <xsl:variable name="mbody2">
- <m:cn>1</m:cn>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- <xsl:with-param name="mbody" select="$mbody2"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:call-template name="out-mml-op">
- <xsl:with-param name="arity" select="1"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'power'"/>
- <xsl:with-param name="mbody" select="$mbody1"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- Binary Operations and Relations -->
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rle.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'leq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rlt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'lt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rge.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'geq'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rgt.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'gt'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rplus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'plus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rminus.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'minus'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rmult.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'times'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rdefinitions/Rdiv.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'divide'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rbasic_fun/Rmin.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'min'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rbasic_fun/Rmax.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'max'"/>
- </xsl:call-template>
-</xsl:template>
-
-<xsl:template match="APPLY[CONST/@uri='cic:/Coq/Reals/Rfunctions/pow.con']" mode="pure">
- <xsl:call-template name="mk-mml-op-noannot">
- <xsl:with-param name="arity" select="2"/>
- <xsl:with-param name="c-tag" select="CONST"/>
- <xsl:with-param name="m-tag" select="'power'"/>
- </xsl:call-template>
-</xsl:template>
-
-<!-- LIMIT -->
-
-<xsl:template match="APPLY[CONST[
- attribute::uri='cic:/Coq/Reals/Rlimit/limit1_in.con']]" mode="pure">
- <xsl:choose>
- <xsl:when test="count(child::*) = 5">
- <m:apply>
- <m:eq/>
- <xsl:choose>
- <xsl:when test="name(*[2]) = 'LAMBDA'">
- <m:apply helm:xref="{@id}">
- <m:limit>
- <xsl:attribute name="definitionURL">
- <xsl:value-of select="CONST/@uri"/>
- </xsl:attribute>
- <xsl:attribute name="helm:xref">
- <xsl:value-of select="CONST/@id"/>
- </xsl:attribute>
- </m:limit>
- <m:bvar>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- </m:bvar>
- <m:lowlimit>
- <xsl:apply-templates select="*[5]" mode="noannot"/>
- </m:lowlimit>
- <xsl:apply-templates select="*[2]/target" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{@id}">
- <m:limit>
- <xsl:attribute name="definitionURL">
- <xsl:value-of select="CONST/@uri"/>
- </xsl:attribute>
- <xsl:attribute name="helm:xref">
- <xsl:value-of select="CONST/@id"/>
- </xsl:attribute>
- </m:limit>
- <m:bvar>
- <m:ci>$x</m:ci>
- </m:bvar>
- <m:lowlimit>
- <xsl:apply-templates select="*[5]" mode="noannot"/>
- </m:lowlimit>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:apply-templates select="*[4]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- DIFFERENTIATION -->
-
-<xsl:template match="APPLY[CONST[
- attribute::uri='cic:/Coq/Reals/Rderiv/D_in.con']]" mode="pure">
- <xsl:choose>
- <xsl:when test="count(child::*) = 4">
- <m:apply>
- <m:eq/>
- <xsl:choose>
- <xsl:when test="name(*[2]) = 'LAMBDA'">
- <m:apply helm:xref="{@id}">
- <m:diff>
- <xsl:attribute name="definitionURL">
- <xsl:value-of select="CONST/@uri"/>
- </xsl:attribute>
- <xsl:attribute name="helm:xref">
- <xsl:value-of select="CONST/@id"/>
- </xsl:attribute>
- </m:diff>
- <m:bvar>
- <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA[1]/target/@binder"/></xsl:with-param></xsl:call-template></m:ci>
- </m:bvar>
- <xsl:apply-templates select="*[2]/target" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <m:apply helm:xref="{@id}">
- <m:diff/>
- <m:bvar>
- <m:ci>$x</m:ci>
- </m:bvar>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </m:apply>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:apply-templates select="*[4]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-</xsl:stylesheet>
+++ /dev/null
-<?xml version="1.0"?>
-
-<!-- Copyright (C) 2000, HELM Team -->
-<!-- -->
-<!-- This file is part of HELM, an Hypertextual, Electronic -->
-<!-- Library of Mathematics, developed at the Computer Science -->
-<!-- Department, University of Bologna, Italy. -->
-<!-- -->
-<!-- HELM is free software; you can redistribute it and/or -->
-<!-- modify it under the terms of the GNU General Public License -->
-<!-- as published by the Free Software Foundation; either version 2 -->
-<!-- of the License, or (at your option) any later version. -->
-<!-- -->
-<!-- HELM is distributed in the hope that it will be useful, -->
-<!-- but WITHOUT ANY WARRANTY; without even the implied warranty of -->
-<!-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -->
-<!-- GNU General Public License for more details. -->
-<!-- -->
-<!-- You should have received a copy of the GNU General Public License -->
-<!-- along with HELM; if not, write to the Free Software -->
-<!-- Foundation, Inc., 59 Temple Place - Suite 330, Boston, -->
-<!-- MA 02111-1307, USA. -->
-<!-- -->
-<!-- For details, see the HELM World-Wide-Web page, -->
-<!-- http://cs.unibo.it/helm/. -->
-
-<!--******************************************************************-->
-<!-- Basic Set Theory -->
-<!-- First draft: April 3 2000 -->
-<!-- HELM Group: Asperti, Padovani, Sacerdoti, Schena -->
-<!--******************************************************************-->
-
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:m="http://www.w3.org/1998/Math/MathML"
- xmlns:helm="http://www.cs.unibo.it/helm">
-
-
-<!-- ************************* LOGIC *********************************-->
-
-
-<xsl:template match="*" mode="set">
- <xsl:choose>
- <xsl:when test="name() = 'LAMBDA'">
- <m:set>
- <m:bvar>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="*[1]/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- <m:type>
- <xsl:apply-templates select="*[1]" mode="noannot"/>
- </m:type>
- </m:bvar>
- <m:condition>
- <xsl:apply-templates select="*[2]" mode="lambda"/>
- </m:condition>
- </m:set>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates select="." mode="noannot"/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- IN -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/In.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:in definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- <!-- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/> -->
- <xsl:apply-templates select="*[2+$no_params]" mode="set" />
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-
-<!-- NOT-IN -->
-<!-- NOT ha no parameters -->
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Init/Logic/not.con']
-and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/In.con']]]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="APPLY/CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(APPLY/child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:notin/>
- <xsl:apply-templates select="*[2]/*[3+$no_params]" mode="noannot"/>
- <!-- <xsl:apply-templates select="*[2]/*[2+$no_params]" mode="noannot"/> -->
- <xsl:apply-templates select="*[2]/*[2+$no_params]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- EMPTY SET -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Empty_set.ind']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 1">
- <m:set definitionURL="{MUTIND/@uri}" helm:xref="{@id}">
- </m:set>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 2">
- <m:apply helm:xref="{@id}">
- <m:in definitionURL="cic:/Coq/Sets/Ensembles/In.con"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- <m:set definitionURL="{MUTIND/@uri}" helm:xref="{@id}">
- </m:set>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- SINGLETON -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Singleton.ind']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 2">
- <m:set definitionURL="{MUTIND/@uri}" helm:xref="{@id}">
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- </m:set>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:in definitionURL="cic:/Coq/Sets/Ensembles/In.con"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- <m:set definitionURL="{MUTIND/@uri}">
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- COUPLE -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Couple.ind']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:set definitionURL="{MUTIND/@uri}" helm:xref="{@id}">
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:set>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:apply helm:xref="{@id}">
- <m:in definitionURL="cic:/Coq/Sets/Ensembles/In.con"/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:set definitionURL="{MUTIND/@uri}">
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- TRIPLE -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Triple.ind'] and (count(child::*) = 5)]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:set definitionURL="{MUTIND/@uri}" helm:xref="{@id}">
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- </m:set>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 5">
- <m:apply helm:xref="{@id}">
- <m:in definitionURL="cic:/Coq/Sets/Ensembles/In.con"/>
- <xsl:apply-templates select="*[5+$no_params]" mode="noannot"/>
- <m:set definitionURL="{MUTIND/@uri}">
- <xsl:apply-templates select="*[2+$no_params]" mode="noannot"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- INTERSECTION -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Intersection.ind']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:intersect definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:apply helm:xref="{@id}">
- <m:in/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:apply>
- <m:intersect definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-
-<!-- UNION -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Union.ind']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:union definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:apply helm:xref="{@id}">
- <m:in/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:apply>
- <m:union definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- INCLUDED -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Included.con']]" mode="pure">
- <xsl:variable name="no_params"> <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:subset definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- STRICTLY INCLUDED -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Strict_Included.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:prsubset definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- SET-DIFF -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Setminus.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:setdiff definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:apply helm:xref="{@id}">
- <m:in/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:apply>
- <m:setdiff definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <xsl:apply-templates select="*[3+$no_params]" mode="set"/>
- </m:apply>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- ADD-ELEM -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Add.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:union definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <m:set>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:apply helm:xref="{@id}">
- <m:in/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:apply>
- <m:union definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <m:set>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- SUBTRACT-ELEM -->
-
-<xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Subtract.con']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="CONST/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:setdiff definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <m:set>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </xsl:when>
- <xsl:when test="(count(child::*) - number($no_params)) = 4">
- <m:apply helm:xref="{@id}">
- <m:in/>
- <xsl:apply-templates select="*[4+$no_params]" mode="noannot"/>
- <m:apply>
- <m:setdiff definitionURL="{CONST/@uri}" helm:xref="{CONST/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- <m:set>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:set>
- </m:apply>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- CARD -->
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Finite_sets/cardinal.ind']]" mode="pure">
- <xsl:variable name="no_params">
- <xsl:call-template name="get_no_params">
- <xsl:with-param name="first_uri" select="$CICURI"/>
- <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
- </xsl:call-template>
- </xsl:variable>
- <xsl:choose>
- <xsl:when test="(count(child::*) - number($no_params)) = 3">
- <m:apply helm:xref="{@id}">
- <m:eq/>
- <m:apply>
- <m:card definitionURL="{MUTIND/@uri}" helm:xref="{MUTIND/@id}"/>
- <xsl:apply-templates select="*[2+$no_params]" mode="set"/>
- </m:apply>
- <xsl:apply-templates select="*[3+$no_params]" mode="noannot"/>
- </m:apply>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-<!-- ******************* SIGMA TYPES **************************** -->
-
-
-<xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Init/Specif/sig.ind']]" mode="pure">
- <xsl:choose>
- <xsl:when test="count(child::*) = 3">
- <xsl:choose>
- <xsl:when test="name(*[3]) = 'LAMBDA'">
- <m:set>
- <m:bvar>
- <m:ci>
- <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="*[3]/*[1]/@binder"/></xsl:with-param></xsl:call-template>
- </m:ci>
- <m:type>
- <xsl:apply-templates select="*[3]/*[1]/*[1]" mode="noannot"/>
- </m:type>
- </m:bvar>
- <m:condition>
- <xsl:apply-templates select="*[3]/*[2]" mode="lambda"/>
- </m:condition>
- </m:set>
- </xsl:when>
- <xsl:otherwise>
- <m:set>
- <m:bvar>
- <m:ci>$x</m:ci>
- <m:type>
- <xsl:apply-templates select="*[2]" mode="noannot"/>
- </m:type>
- </m:bvar>
- <m:condition>
- <m:apply>
- <m:csymbol>app</m:csymbol>
- <xsl:apply-templates select="*[3]" mode="noannot"/>
- <m:ci>$x</m:ci>
- </m:apply>
- </m:condition>
- </m:set>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-imports/>
- </xsl:otherwise>
- </xsl:choose>
-</xsl:template>
-
-
-
-</xsl:stylesheet>
-algebra.xsl
annotatedcont.xsl
annotatedpres.xsl
-arith.xsl
-basic.xsl
content.xsl
content_to_html.xsl
contentlib.xsl
objtheorycontent.xsl
params.xsl
proofs.xsl
-reals.xsl
ricerca.xsl
ring.xsl
rootcontent.xsl
roottheory.xsl
-set.xsl
show_dc.xsl
theory_content.xsl
theory_pres.xsl