]> matita.cs.unibo.it Git - helm.git/commitdiff
Complete management of inductive types.
authorAndrea Asperti <andrea.asperti@unibo.it>
Tue, 3 Apr 2001 07:56:41 +0000 (07:56 +0000)
committerAndrea Asperti <andrea.asperti@unibo.it>
Tue, 3 Apr 2001 07:56:41 +0000 (07:56 +0000)
or_ind revisited (full_or_in).
(only for html: mml_extension must be upadated!!!).

-- andrea

helm/style/content_to_html.xsl
helm/style/proofs.xsl
helm/style/rootcontent.xsl
helm/style/set.xsl

index 9de7d48962cfe82ab3522e65dfd56f9db15cd66b..028f65504cfa970ec95bd0e6dfa5f299ad62c784 100644 (file)
@@ -55,7 +55,7 @@
        media-type="text/html"
        doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" />
 
-<xsl:variable name="framewidth" select="36"/>
+<xsl:variable name="framewidth" select="45"/>
 
 <xsl:template match="/">
  <xsl:param name="current_indent" select="0"/>
        <FONT color="red">&#x00a0;proves&#x00a0;</FONT>
        <xsl:apply-templates mode="inline" select="*[position()=3]"/>
     </xsl:when>
+    <!-- false_ind -->
+    <xsl:when test="$name='false_ind'">
+    <xsl:apply-templates mode="inline" select="*[3]"/>
+    <FONT color="red">Contradiction.</FONT>
+    </xsl:when>
     <!-- and_ind -->
     <xsl:when test="$name='and_ind'">
      <FONT color="red">From&#x00a0;</FONT>
          <xsl:apply-templates select="*[2]"/>
         </xsl:otherwise>
        </xsl:choose>
+       <xsl:variable name="charlength_first">
+        <xsl:apply-templates select="*[3]" mode="charcount"/>
+       </xsl:variable>
+       <xsl:variable name="charlength_second">
+        <xsl:apply-templates select="*[4]" mode="charcount"/>
+       </xsl:variable>
+       <xsl:variable name="charlength_side_proof">
+        <xsl:apply-templates select="*[5]" mode="charcount"/>
+       </xsl:variable>
+       <xsl:variable name="split1"
+          select="$charlength_first + $charlength_second > $framewidth"/>
+       <xsl:variable name="split2"
+          select="$charlength_second + $charlength_side_proof > $framewidth"/>
+     <!-- <xsl:value-of select="$current_indent"/> -->
+     <!-- <xsl:value-of select="$charlength"/> -->
        <br/>
        <xsl:call-template name="make_indent">
         <xsl:with-param name="current_indent" select="$current_indent"/> 
        </xsl:call-template>
        <FONT color="red">Rewrite&#x00a0;</FONT>
-       <xsl:apply-templates select="*[3]"/>
-       <FONT color="red">&#x00a0;with&#x00a0;</FONT>
-       <xsl:apply-templates select="*[4]"/>
-       <FONT color="red">&#x00a0;by&#x00a0;</FONT>
-       <xsl:apply-templates select="*[5]"/>
+       <xsl:apply-templates mode="inline" select="*[3]"/>
+       <xsl:text>&#x00a0;</xsl:text>
+       <xsl:if test="$split1">
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       </xsl:if>
+       <FONT color="red">with&#x00a0;</FONT>
+       <xsl:apply-templates mode="inline" select="*[4]"/>
+       <xsl:text>&#x00a0;</xsl:text>
+       <xsl:if test="$split2">
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       </xsl:if>
+       <FONT color="red">by&#x00a0;</FONT>
+       <xsl:apply-templates select="*[5]">
+        <xsl:with-param name="current_indent" select="$current_indent+5"/>
+       </xsl:apply-templates>
       </xsl:when>
       <!-- rewrite and apply -->
       <xsl:when test="$name='rewrite_and_apply'">
        <FONT color="red">Then apply it to&#x00a0;</FONT>
        <xsl:apply-templates select="*[position()>2]"/>
       </xsl:when>
+      <!-- by_induction -->
+      <xsl:when test="$name='by_induction'">
+       <FONT color="red">We prove&#x00a0;</FONT>
+       <xsl:apply-templates select="../*[3]">
+        <xsl:with-param name="current_indent" select="$current_indent+18"/>
+       </xsl:apply-templates>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <FONT color="red">by induction on&#x00a0;</FONT>
+       <xsl:apply-templates select="*[position()=last()]/*[position()=last()]">
+        <xsl:with-param name="current_indent" select="$current_indent+30"/>
+       </xsl:apply-templates>
+       <!-- 
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <xsl:text>The induction property is</xsl:text>
+       <br/> 
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <xsl:apply-templates select="*[3]">
+        <xsl:with-param name="current_indent" select="$current_indent"/>
+       </xsl:apply-templates>
+       -->
+       <xsl:apply-templates 
+            select="*[position()>3 and not(position()=last())]">
+        <xsl:with-param name="current_indent" select="$current_indent+4"/>
+       </xsl:apply-templates>
+       <!-- <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <xsl:text>End induction</xsl:text> -->
+      </xsl:when>
+      <!-- inductive_case -->
+      <xsl:when test="$name='inductive_case'">
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <FONT color="red">Case&#x00a0;</FONT>
+       <xsl:apply-templates select="*[2]">
+        <xsl:with-param name="current_indent" select="$current_indent +10"/>
+       </xsl:apply-templates>
+       <xsl:if test="*[3]/*[position()>1]">
+        <br/>
+        <xsl:call-template name="make_indent">
+         <xsl:with-param name="current_indent" select="$current_indent+4"/> 
+        </xsl:call-template>
+        <FONT color="red">By induction hypothesis, we have:</FONT>
+        <xsl:for-each select="*[3]/*[position()>1]">
+         <br/>
+         <xsl:call-template name="make_indent">
+          <xsl:with-param name="current_indent" select="$current_indent + 4"/> 
+         </xsl:call-template>
+         <xsl:text>(</xsl:text>
+         <xsl:apply-templates select="m:ci"/>
+         <xsl:text>)&#x00a0;</xsl:text>
+         <xsl:apply-templates select="m:type">
+          <xsl:with-param name="current_indent" select="$current_indent + 8"/>
+         </xsl:apply-templates>
+        </xsl:for-each>
+       </xsl:if>
+       <br/>
+        <xsl:call-template name="make_indent">
+         <xsl:with-param name="current_indent" select="$current_indent + 4"/> 
+        </xsl:call-template>
+       <xsl:apply-templates select="*[4]">
+        <xsl:with-param name="current_indent" select="$current_indent +4"/>
+       </xsl:apply-templates>
+       <!-- <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <xsl:text>End Case</xsl:text> -->
+      </xsl:when>
+      <!-- case_lhs  -->
+      <xsl:when test="$name='case_lhs'">
+       <xsl:choose>
+        <xsl:when test="count(*)=2">
+         <xsl:apply-templates mode="inline" select="*[2]"/>
+        </xsl:when>
+        <xsl:otherwise>
+         <xsl:text>(</xsl:text>
+         <xsl:apply-templates mode="inline" select="*[2]"/>
+         <xsl:for-each select="m:bvar">
+          <xsl:text>&#x00a0;</xsl:text>
+          <xsl:apply-templates mode="inline" select="*[1]"/>
+          <xsl:text>:</xsl:text>
+          <xsl:apply-templates mode="inline" select="m:type/*[1]"/>
+         </xsl:for-each>
+         <xsl:text>)</xsl:text>
+        </xsl:otherwise>
+       </xsl:choose>
+      </xsl:when>
+      <!-- nat_ind -->
+      <xsl:when test="$name='nat_ind_complete'">
+       <FONT color="red">By induction on&#x00a0;</FONT>
+       <xsl:apply-templates select="*[2]"/>:
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <xsl:text>0&#x00a0;</xsl:text>
+       <FONT FACE="Symbol" mathcolor="green">&#222;</FONT>
+       <xsl:apply-templates select="*[3]">
+        <xsl:with-param name="current_indent" select="$current_indent + 8"/>
+       </xsl:apply-templates>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <xsl:text>S(</xsl:text>
+       <xsl:apply-templates select="*[4]"/>
+       <xsl:text>)&#x00a0;</xsl:text>
+       <FONT FACE="Symbol" mathcolor="green">&#222;</FONT>
+       <FONT color="red">Assume by induction</FONT>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent +10"/> 
+       </xsl:call-template>
+       <xsl:text>(</xsl:text>
+       <xsl:apply-templates select="*[5]"/>
+       <xsl:text>)</xsl:text>
+       <xsl:apply-templates select="*[6]">
+        <xsl:with-param name="current_indent" select="$current_indent + 14"/>
+       </xsl:apply-templates>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent +10"/> 
+       </xsl:call-template>
+       <xsl:apply-templates select="*[7]">
+        <xsl:with-param name="current_indent" select="$current_indent + 10"/>
+       </xsl:apply-templates>
+      </xsl:when>
+      <!-- false_ind -->
+      <xsl:when test="$name='false_ind'">
+       <xsl:apply-templates select="*[3]">
+        <xsl:with-param name="current_indent" select="$current_indent"/>
+       </xsl:apply-templates> 
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template> 
+       <FONT color="red">Contradiction.</FONT>
+      </xsl:when>
       <!-- and_ind -->
       <xsl:when test="$name='and_ind'">
        <xsl:choose>
         <xsl:with-param name="current_indent" select="$current_indent"/> 
        </xsl:apply-templates>
       </xsl:when>
+      <!-- full_or_ind -->
+      <xsl:when test="$name='full_or_ind'">
+       <xsl:choose>
+        <xsl:when test="name(*[2])='m:apply'">
+         <xsl:apply-templates select="*[2]">
+          <xsl:with-param name="current_indent" select="$current_indent"/> 
+         </xsl:apply-templates>
+        </xsl:when>
+        <xsl:otherwise>
+         <FONT color="red">Consider&#x00a0;</FONT>
+         <xsl:apply-templates select="*[2]"/>
+        </xsl:otherwise>
+       </xsl:choose>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent"/> 
+       </xsl:call-template>
+       <FONT color="red">We proceed by cases to prove&#x00a0;</FONT>
+       <xsl:apply-templates select="*[3]"/>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent+4"/> 
+       </xsl:call-template>
+       <FONT color="red">Left: suppose&#x00a0;</FONT>
+       <xsl:text>(</xsl:text>
+       <xsl:value-of select="*[4]/m:bvar/m:ci"/>
+       <xsl:text>)&#x00a0;</xsl:text>
+       <xsl:apply-templates 
+            select="*[4]/m:bvar/m:type/*[1]"/>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent+15"/> 
+       </xsl:call-template>
+       <xsl:apply-templates 
+            select="*[4]/*[3]">
+        <xsl:with-param name="current_indent" select="$current_indent+15"/>
+       </xsl:apply-templates>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent+4"/> 
+       </xsl:call-template>
+       <FONT color="red">Right: suppose&#x00a0;</FONT>
+       <xsl:text>(</xsl:text>
+       <xsl:value-of select="*[5]/m:bvar/m:ci"/>
+       <xsl:text>)&#x00a0;</xsl:text>
+       <xsl:apply-templates 
+            select="*[5]/m:bvar/m:type/*[1]"/>
+       <br/>
+       <xsl:call-template name="make_indent">
+        <xsl:with-param name="current_indent" select="$current_indent+16"/> 
+       </xsl:call-template>
+       <xsl:apply-templates 
+            select="*[5]/*[3]">
+        <xsl:with-param name="current_indent" select="$current_indent+16"/>
+       </xsl:apply-templates>
+      </xsl:when>
       <!-- or_ind -->
       <xsl:when test="$name='or_ind'">
        <xsl:choose>
index c40a42ce865ac34e19b3b9af7daf04975fb72835..306b48fbc3d7821bdbae9f5f851a95f7c846e796 100644 (file)
@@ -55,6 +55,7 @@
    <m:apply helm:xref="{@id}">
     <m:csymbol>proof</m:csymbol>
     <xsl:apply-templates mode="proof_transform" select="."/>
+    <!-- <xsl:apply-templates mode="try_inductive" select="."/> -->
     <xsl:apply-templates mode="pure" select="$InnerTypes/InnerTypes/TYPE[@of=$id]/*"/>
    </m:apply>
   </xsl:when>
@@ -72,6 +73,7 @@
    <m:apply helm:xref="{@id}">
     <m:csymbol>proof</m:csymbol>
     <xsl:apply-templates mode="proof_transform" select="."/>
+    <!-- <xsl:apply-templates mode="try_inductive" select="."/> -->
     <xsl:apply-templates mode="pure" select="$InnerTypes/InnerTypes/TYPE[@of=$id]/*"/>
    </m:apply>
   </xsl:when>
  </xsl:choose>
 </xsl:template>
 
+<xsl:template mode="try_inductive" match="APPLY">
+   <xsl:variable name="id" select="@id"/>
+   <xsl:choose>
+    <xsl:when test="CONST[1]">
+     <xsl:variable name="uri" select="CONST[1]/@uri"/>
+     <xsl:choose>
+      <xsl:when test="contains($uri,'_ind.con')">
+       <xsl:variable name="ind_name">
+        <xsl:call-template name="get_name">
+         <xsl:with-param name="uri" select="$uri"/>
+        </xsl:call-template>
+       </xsl:variable>
+       <xsl:variable name="ind_uri" 
+         select="concat(substring-before($uri,'_ind.con'),'.ind')"/>
+       <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="$uri"/>
+        </xsl:call-template>
+       </xsl:variable>
+       <xsl:apply-templates mode="inductive" select=".">
+        <xsl:with-param name="inductive_def_uri" 
+         select="$ind_uri"/>
+        <xsl:with-param name="section_params" select="$no_params"/>
+        <xsl:with-param name="inductive_def_index" select="1"/>
+        <xsl:with-param name="inductive_def_name" select="$ind_name"/>
+       </xsl:apply-templates>
+      </xsl:when>
+      <xsl:otherwise>
+       <xsl:apply-templates mode="letin" select="."/>
+      </xsl:otherwise>
+     </xsl:choose>
+    </xsl:when>
+    <xsl:otherwise>
+     <xsl:apply-templates mode="letin" select="."/>
+    </xsl:otherwise>
+   </xsl:choose>
+</xsl:template>
+
+
 <xsl:template mode="proof_transform" match="*">
    <xsl:variable name="id" select="@id"/>
    <xsl:choose>
       <xsl:apply-templates mode="noannot" select="*[4]"/>
      </m:apply>
     </xsl:when>
-    <!-- NATIND 4 parametri -->
+    <!-- NATIND 4 parametri (nuova versione) -->
+    <!-- 
     <xsl:when test="name()='APPLY' and CONST[
- attribute::uri='cic:/Coq/Init/Datatypes/nat_ind.con'] and count(child::*) = 5">
+ attribute::uri='cic:/Coq/Init/Datatypes/nat_ind.con'] 
+ and count(child::*) = 5
+ and name(*[4])='LAMBDA' 
+ and name(*[4]/target/*[1])='LAMBDA'"> 
      <m:apply>
-      <m:csymbol>nat_ind</m:csymbol>
+      <m:csymbol>nat_ind_complete</m:csymbol>
+      <xsl:apply-templates mode="noannot" select="*[5]"/>
       <xsl:apply-templates mode="noannot" select="*[3]"/>
-      <xsl:apply-templates mode="noannot" select="*[4]"/>
+      <m:ci><xsl:value-of select="*[4]/target/@binder"/></m:ci>
+      <m:ci><xsl:value-of select="*[4]/target/*[1]/target/@binder"/></m:ci>
+      <xsl:apply-templates mode="noannot" select="*[4]/target/*[1]/source/*"/>
+      <xsl:apply-templates mode="noannot" select="*[4]/target/*[1]/target/*"/>
      </m:apply>
-    </xsl:when>
+    </xsl:when> 
+    -->
     <!-- EQUALITY -->
     <xsl:when test="name()= 'APPLY' and CONST[
  attribute::uri='cic:/Coq/Init/Logic/Equality/eq_ind.con' or
+ attribute::uri='cic:/Coq/Init/Logic/Logic_lemmas/eq_ind_r.con' or
  attribute::uri='cic:/Coq/Init/Logic_Type/eqT_ind.con' or
+ attribute::uri='cic:/Coq/Init/Logic_Type/eqT_ind_r.con' or
  attribute::uri='cic:/Coq/Zarith/auxiliary/eqT_ind_r.con'] and count(child::*) = 7">
       <m:apply>
        <m:csymbol>rw_step</m:csymbol>
     <!-- EQUALITY with extra-parameters -->
     <xsl:when test="name()= 'APPLY' and CONST[
  attribute::uri='cic:/Coq/Init/Logic/Equality/eq_ind.con' or
+ attribute::uri='cic:/Coq/Init/Logic/Logic_lemmas/eq_ind_r.con' or
  attribute::uri='cic:/Coq/Init/Logic_Type/eqT_ind.con' or
+ attribute::uri='cic:/Coq/Init/Logic_Type/eqT_ind_r.con' or
  attribute::uri='cic:/Coq/Zarith/auxiliary/eqT_ind_r.con'] and count(child::*) > 7">
       <xsl:variable name="no_extraproofs" select="count(*[position()>7 and @sort='Prop' and (name(.)='LAMBDA' or name(.)='LETIN' or name(.)='APPLY' or name(.)='MUTCASE' or name(.)='FIX' or name(.)='COFIX')])"/>      
       <xsl:choose>
        </xsl:otherwise>
       </xsl:choose>
     </xsl:when>
+    <!-- False_ind -->
+    <xsl:when test="name()= 'APPLY' and CONST[
+     attribute::uri='cic:/Coq/Init/Logic/False_ind.con'] and 
+     count(child::*) = 3">
+     <m:apply helm:xref="{@id}">
+       <m:csymbol>false_ind</m:csymbol>
+       <m:ci>cic:/Coq/Init/Logic/False_ind.con</m:ci>
+       <xsl:apply-templates mode="noannot" select="*[3]"/>
+     </m:apply>
+    </xsl:when>
     <!-- gestire meglio il caso di and_ind quando la prova 
          non e' della forma \x.\y.M -->
     <xsl:when test="name()= 'APPLY' and CONST[
     <xsl:when test="name()= 'APPLY' and CONST[
  attribute::uri='cic:/Coq/Init/Logic/Disjunction/or_ind.con'] 
  and count(child::*) = 7">
-     <m:apply helm:xref="{@id}">
-      <m:csymbol>or_ind</m:csymbol>
-      <xsl:apply-templates mode="noannot" select="*[7]"/>
-      <xsl:apply-templates mode="pure" select="$InnerTypes/InnerTypes/TYPE[@of=$id]/*"/>
-      <xsl:apply-templates mode="pure" select="*[5]"/>
-      <xsl:apply-templates mode="pure" select="*[6]"/>
-     </m:apply>
+      <xsl:choose>
+       <xsl:when test="name(*[5])='LAMBDA' 
+                 and name(*[6])='LAMBDA'">
+        <xsl:variable name="definition_url" 
+            select="'cic:/Coq/Init/Logic/Disjunction/or.ind'"/>
+        <m:apply helm:xref="{@id}">
+         <m:csymbol>full_or_ind</m:csymbol>
+         <xsl:apply-templates mode="noannot" select="*[7]"/>
+         <xsl:apply-templates mode="pure" 
+              select="$InnerTypes/InnerTypes/TYPE[@of=$id]/*"/>
+         <m:apply>
+          <m:csymbol>left_case</m:csymbol>
+          <m:bvar>
+           <m:ci>
+            <xsl:value-of select="*[5]/target/@binder"/>
+           </m:ci>
+           <m:type>
+            <xsl:apply-templates mode="pure" select="*[5]/source/*[1]"/>
+           </m:type>
+          </m:bvar>
+          <xsl:apply-templates mode="noannot" select="*[5]/target/*[1]"/>
+         </m:apply>
+         <m:apply>
+          <m:csymbol>right_case</m:csymbol>
+          <m:bvar>
+           <m:ci>
+            <xsl:apply-templates mode="pure" select="*[6]/target/@binder"/>
+           </m:ci>
+           <m:type>
+            <xsl:apply-templates mode="pure" select="*[6]/source/*[1]"/>
+           </m:type>
+          </m:bvar>
+          <xsl:apply-templates mode="noannot" select="*[6]/target/*[1]"/>
+         </m:apply>
+        </m:apply>
+       </xsl:when>
+       <xsl:otherwise>
+        <m:apply helm:xref="{@id}">
+         <m:csymbol>or_ind</m:csymbol>
+         <xsl:apply-templates mode="noannot" select="*[7]"/>
+         <xsl:apply-templates mode="pure" 
+              select="$InnerTypes/InnerTypes/TYPE[@of=$id]/*"/>
+         <xsl:apply-templates mode="pure" select="*[5]"/>
+         <xsl:apply-templates mode="pure" select="*[6]"/>
+        </m:apply>
+       </xsl:otherwise>
+      </xsl:choose>
     </xsl:when>
     <!-- ex_ind, exT_ind -->
       <xsl:when test="name()= 'APPLY' 
        <xsl:apply-templates mode="proof_transform" select="*[5]/target/LAMBDA/target/*"/>
       </m:apply>
     </xsl:when>
+    <xsl:when test="(name()='APPLY') and (name(*[1])='CONST')">
+     <xsl:apply-templates mode="try_inductive" select="."/>
+    </xsl:when>
     <xsl:otherwise>
       <xsl:choose>
        <xsl:when test="name()='APPLY'">
  </xsl:choose>
 </xsl:template>
 
+<!-- Auxiliary functions -->
+<xsl:template name="get_name">
+ <xsl:param name="uri" select="''"/>
+ <xsl:variable name="sub_after" select="substring-after($uri,'/')"/>
+ <xsl:choose>
+  <xsl:when test="contains($sub_after,'/')">
+   <xsl:call-template name="get_name">
+    <xsl:with-param name="uri" select="$sub_after"/>
+   </xsl:call-template>
+  </xsl:when>
+  <xsl:otherwise>
+   <xsl:value-of select="substring-before($sub_after,'_ind.con')"/>
+  </xsl:otherwise>
+ </xsl:choose>
+</xsl:template>
 
 <!-- <xsl:template match="APPLY[CONST[
  attribute::uri='cic:/Coq/Init/Logic/Conjunction/and_ind.con']]" mode="appflat">
index 9e0c82ab38f942e574811e9f215c6fd6adeef596..8f34bae075c00bfbbc734fc58c4aa4b59de8a453 100644 (file)
@@ -58,6 +58,7 @@
 <xsl:import href="annotatedcont.xsl"/>
 <xsl:include href="headercontent.xsl"/>
 <xsl:include href="proofs.xsl"/>
+<xsl:include href="inductive.xsl"/>
 
 <xsl:variable name="showproof" select="0"/>
 
index 849365f3f6f155b1bda2ae33150525752dd6e99b..5ff4fce0b94642e447563375f7cf38dbb0d9dabf 100644 (file)
@@ -68,7 +68,7 @@
 <xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/In.con']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -94,7 +94,7 @@
 and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/In.con']]]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="APPLY/CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -118,7 +118,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/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="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -146,7 +146,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Singleton.ind']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -176,7 +176,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Couple.ind']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -208,7 +208,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/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="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -242,7 +242,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Intersection.ind']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -277,7 +277,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Union.ind']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -311,7 +311,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Included.con']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -334,7 +334,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/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="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -357,7 +357,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Setminus.con']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -391,7 +391,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Add.con']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -429,7 +429,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensembles/Ensembles/Subtract.con']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="CONST/@uri"/>
      </xsl:call-template>
     </xsl:variable>
@@ -467,7 +467,7 @@ and (count(child::*) = 2) and APPLY[CONST[attribute::uri='cic:/Coq/Sets/Ensemble
 <xsl:template match="APPLY[MUTIND[attribute::uri='cic:/Coq/Sets/Finite_sets/Ensembles_finis/cardinal.ind']]" mode="pure">
     <xsl:variable name="no_params">
      <xsl:call-template name="get_no_params">
-      <xsl:with-param name="first_uri" select="/cicxml/@uri"/>
+      <xsl:with-param name="first_uri" select="$CICURI"/>
       <xsl:with-param name="second_uri" select="MUTIND/@uri"/>
      </xsl:call-template>
     </xsl:variable>