text stringlengths 1.3k 3.62M |
|---|
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* File: NRules.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Cons_Counter_Model.
Require Export NSound.
Inductive nsearch_spec_result_aux (goal : Int) (work : nf_list)
(ds : disjs) (ni : nested_imps) (ai : atomic_imps)
(a : atoms) (context : flist) : Set :=
| NDerivable :
Derivable cont... |
(* File: Cons_Counter_Model.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Disjunct.
Require Export NDeco_Sound.
Fixpoint n2forest (n : nested_imps) : Forest atoms :=
match n with
| nil => Nil_Forest atoms
| Undecorated _ :: n => n2forest n
| Decorated _ k :: n => Cons_Forest atoms k (n2fo... |
(* File: Search.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Rules.
Require Export Weight.
Definition vlist := list (list Int * form).
Fixpoint vlist2list (gamma : vlist) : flist :=
match gamma with
| nil => fnil
| (l, a) :: gamma => vimp l a :: vlist2list gamma
end.
Fixpoint vlist2hli... |
(* File: In_NGamma.v (last edited on 27/10/2000) (c) Klaus Weich *)
(*******************************************************************)
(* The left hand side Gamma of a sequent consists of *)
(* work : a list of (arbitray) normalforms *)
(* (to be inserted in the fo... |
(* File: Forces_NGamma.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Le_Ks.
Definition forces_ngamma (work : nf_list) (ds : disjs)
(ni : nested_imps) (ai : atomic_imps) (a : atoms)
(k : kripke_tree) :=
forall c : normal_form,
in_ngamma work ds ni ai a c -> forces_t k (nf2form c).
(**... |
(* File: Sound.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export NSound.
Require Export In_Gamma.
Definition sound (Gamma : flist) (work : nf_list) (context : flist) :=
forall a : form, in_gamma Gamma work a -> Derivable context a.
Lemma sound_cons_gamma :
forall (gamma : flist) (work : nf_list) ... |
(* File: AvlTrees.v (last edited on 25/10/2000) (c) Klaus Weich *)
Require Import ML_Int.
Require Import My_Arith.
Require Import List.
Global Set Asymmetric Patterns.
Section avl_trees.
Variable B : Set.
(*********************************************************)
(* Definition bal and avl_tree *)
Inducti... |
(* File: Le_Ks.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Rev_App.
(*****************************************************************)
Inductive le_ni : nested_imps -> nested_imps -> Prop :=
| Le_NI_Nil : le_ni NNil NNil
| Le_NI_Cons_NN :
forall (x : nimp) (ni1 ni2 : nested_imp... |
(* File: NSearch.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Disjunct.
Require Export NWeight.
Require Export Lt_Ks.
Require Export NRules.
Definition nsearch_invariant (n : nat) :=
forall (goal : Int) (work : nf_list) (ds : disjs)
(ni : nested_imps) (ai : atomic_imps) (a : atoms)
... |
(* File: Rules.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Minimal.
Require Export Sound.
Require Export NSearch.
Inductive search_spec_aux (goal : form) (gamma : flist)
(work : nf_list) (context : flist) : Set :=
| derivable :
Derivable context goal -> search_spec_aux goal gamma work... |
(* File: In_Gamma.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export In_NGamma.
Inductive in_gamma (gamma : flist) (work : nf_list) : form -> Set :=
| In_Gamma :
forall (n : nat) (a : form),
my_nth form n gamma a -> in_gamma gamma work a
| In_Work1 :
forall (n : nat) (a : normal_f... |
(* File: Normal_Form.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Forms.
(******* Normal forms ***********************************************)
Inductive normal_form : Set :=
| NFalsum : normal_form
| NAtom : Int -> normal_form
| NDisj : Int -> Int -> normal_form
| AImp : Int -> no... |
(* File: Forces_Gamma.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export In_Gamma.
Require Export Forces_NGamma.
Definition forces_gamma (gamma : flist) (work : nf_list)
(k : kripke_tree) := forall a : form, in_gamma gamma work a -> forces_t k a.
Lemma forces_gamma_cons_gamma :
forall (gamma : ... |
(* File: NSound.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Le_Ks.
Require Export Derivable_Tools.
Definition nsound (work : nf_list) (ds : disjs) (ni : nested_imps)
(ai : atomic_imps) (a : atoms) (context : flist) :=
forall c : normal_form,
in_ngamma work ds ni ai a c -> Derivable context... |
(* File: Kripke_Trees.v (last edited on 25/10/2000) (c) Klaus Weich *)
Require Export AvlTrees.
Require Export Trees.
Require Export Derivations.
(******* Kripke_Model ****************************************)
Inductive Kripke_Model (A : Set) (World : A -> Type)
(le : A -> A -> Type) (forces0 : A -> Int ->... |
(* File: Disjunct.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export In_NGamma.
Definition a_ai_disj (a : atoms) (ai : atomic_imps) :=
forall i : Int,
LOOKUP unit i a tt -> forall bs : nf_list, LOOKUP nf_list i ai bs -> False.
Definition a_goal_disj (a : atoms) (goal : Int) :=
LOOKUP unit goal... |
(* File: My_Nth.v (last edited on 25/10/2000) (c) Klaus Weich *)
Require Export List.
Require Export Plus.
Section My_Nth.
Variable B : Set.
Inductive my_nth : nat -> list B -> B -> Prop :=
| My_NthO : forall (l : list B) (a : B), my_nth 0 (a :: l) a
| My_NthS :
forall (n : nat) (l : list B) (b : B),
... |
(* File: Rev_App.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export In_NGamma.
(*******************************************************************)
(* Decorated nested implications are pairs of a nested implication *)
(* and a counter-model of the premisses. *)
Definition d... |
(* File: niMinimal.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Forces_NGamma.
Require Export Derivable_Tools.
Definition nminimal (work : nf_list) (ds : disjs) (ni : nested_imps)
(ai : atomic_imps) (a : atoms) (context : flist) :=
forall (c : form) (k : kripke_tree),
Is_Monotone_kripke_tr... |
(* File: Minimal.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Forces_Gamma.
Require Export Derivable_Tools.
Definition minimal (gamma : flist) (work : nf_list)
(context : flist) :=
forall (a : form) (k : kripke_tree),
Is_Monotone_kripke_tree k ->
forces_gamma gamma work k -> In a context... |
(* File: Trees.v (last edited on 25/10/2000) (c) Klaus Weich *)
Require Export My_Arith.
Require Import Le.
(****** Tree stuff ********************************************)
Section Trees.
Variable A : Set.
Inductive Tree : Set :=
node : A -> Forest -> Tree
with Forest : Set :=
| Nil_Forest : Forest
... |
(* File: NWeight.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Lt.
Require Export Le.
Require Export Regular_Avl.
Require Export Le_Ks.
(*********************************************************************)
Fixpoint nweight (a : form) : nat :=
match a with
| Atom _ => 0
| Falsum => 0
|... |
(* File: Regular_Avl.v (last edited on 27/10/2000) (c) Klaus Weich *)
(* An AVL tree of lists is called regular iff, for each entry l, *)
(* we have l\not= nil *)
Require Import List.
Require Import ML_Int.
Require Import AvlTrees.
Section Regular_Avl.
Variable A : Se... |
(* File: Forms.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export ML_Int.
Require Export My_Nth.
(******* forms ***********************************************)
Inductive form : Set :=
| Falsum : form
| Atom : Int -> form
| AndF : form -> form -> form
| OrF : form -> form -> form
| Imp ... |
(* File: Lt_Ks.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export Le.
Require Export Lt.
Require Export Le_Ks.
Fixpoint count_undecs (n : nested_imps) : nat :=
match n with
| nil => 0
| Undecorated _ :: n => S (count_undecs n)
| Decorated _ _ :: n => count_undecs n
end.
Inductive Lt_Ks (ni... |
(* File: ML_int.v (last edited on 25/10/2000 (c) Klaus Weich *)
(* Axiomisation of the ML type "int" *)
Axiom Int : Set.
Axiom Less : Int -> Int -> Prop.
Axiom Equal : Int -> Int -> Prop.
Axiom int_succ : forall x : Int, {y : Int | Less x y}.
Axiom int_null : Int.
Axiom equal_dec : forall x y : Int, {Equal x y}... |
(* File: Weight.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Import Rules.
Fixpoint weight (a : form) : nat :=
match a with
| Falsum => 1
| Atom _ => 1
| AndF a b => S (weight a + weight b)
| OrF Falsum b => S (weight b)
| OrF (Atom _) b => S (weight b)
| OrF a b => S (S (weight b + weig... |
(* File: Derivations.v (last edited on 1/11/2000) (c) Klaus Weich *)
Require Export Forms.
(******* Derivations *****************************************)
Inductive proof_term : Set :=
| Var : nat -> proof_term
| Efq : proof_term -> form -> proof_term
| Abs : form -> proof_term -> proof_term
| App :... |
(* File: Derivable.v (last edited on 1/1/2000) (c) Klaus Weich *)
Require Export Derivable_Def.
Lemma derivable_eq :
forall (context context' : flist) (a a' : form),
context = context' -> a = a' -> Derivable context a -> Derivable context' a'.
(* Goal: forall (context context' : flist) (a a' : form) (_ : @eq fl... |
(* File: NDeco_Sound.v (last edited on 27/10/2000) (c) Klaus Weich *)
Require Export NMinimal.
(*****************************************************************)
Inductive k_deco_sound (k : kripke_tree) (i0 i1 : Int)
(work : nf_list) (ds : disjs) (ni : nested_imps) (ai : atomic_imps)
(a : atoms) : Prop :=
k... |
(* File: My_Arith.v (last edited on 25/10/2000) (c) Klaus Weich *)
Require Import Le.
Require Import Lt.
Require Import List.
Require Import Plus.
(******* List stuff ***********************************************)
Lemma fold_right_perm :
forall (A B : Set) (f : B -> A -> A) (o : A) (l0 l1 : list B) (x : B),
(... |
Require Import InfSeqExt.infseq.
Require Import InfSeqExt.exteq.
(* map *)
Section sec_map.
Variable A B: Type.
CoFixpoint map (f: A->B) (s: infseq A): infseq B :=
match s with
| Cons x s => Cons (f x) (map f s)
end.
Lemma map_Cons: forall (f:A->B) x s, map f (Cons x s) = Cons (f x) (map f s).
Proof using.
... |
Require Import InfSeqExt.infseq.
Require Import Classical.
Section sec_classical.
Variable T : Type.
Lemma weak_until_until_or_always :
forall (J P : infseq T -> Prop) (s : infseq T),
weak_until J P s -> until J P s \/ always J s.
Proof using.
(* Goal: forall (J P : forall _ : infseq T, Prop) (s : infseq T) (_... |
(* ------------------------------------------------------------------------- *)
(* General tactics *)
Ltac genclear H := generalize H; clear H.
Ltac clearall :=
repeat
match goal with [H : _ |- _ ] => clear H end
|| match goal with [H : _ |- _ ] => genclear H end.
(* --------------------------------... |
Require Import InfSeqExt.infseq.
Require Import InfSeqExt.exteq.
(* --------------------------------------------------------------------------- *)
(* Infinite subsequences *)
Section sec_subseq.
Variable T: Type.
(* suff s s' means s is a suffix of s' *)
Inductive suff (s : infseq T) : infseq T -> Prop :=
| sp_... |
Require Import InfSeqExt.infseq.
(* ------------------------------------------------------------------------- *)
(* Extensional equality on infinite sequences *)
Section sec_exteq.
Variable T: Type.
CoInductive exteq : infseq T -> infseq T -> Prop :=
exteq_intro :
forall x s1 s2, exteq s1 s2 -> exteq (Cons x ... |
Require Import StructTact.StructTactics.
Set Implicit Arguments.
Lemma or_false :
forall P : Prop, P -> (P \/ False).
Proof.
(* Goal: forall (P : Prop) (_ : P), or P False *)
firstorder.
Qed.
Lemma if_sum_bool_fun_comm :
forall A B C D (b : {A}+{B}) (c1 c2 : C) (f : C -> D),
f (if b then c1 else c2) = if b... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListTactics.
Require Import StructTact.ListUtil.
Set Implicit Arguments.
Section dedup.
Variable A : Type.
Hypothesis A_eq_dec : forall x y : A, {x = y} + {x <> y}.
Fixpoint dedup (xs : list A) : list ... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Set Implicit Arguments.
Fixpoint before {A: Type} (x : A) y l : Prop :=
match l with
| [] => False
| a :: l' =>
a = x \/
(a <> y /\ before x y l')
end.
Section before.
Variable A : Type.
Lemma before_In :... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Set Implicit Arguments.
Fixpoint Prefix {A} (l1 : list A) l2 : Prop :=
match l1, l2 with
| a :: l1', b :: l2' => a = b /\ Prefix l1' l2'
| [], _ => True
| _, _ => False
end.
Section prefix.
Variable A : Type.
Lem... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListUtil.
Require Import StructTact.ListTactics.
Require Import StructTact.Before.
Set Implicit Arguments.
Section remove_all.
Variable A : Type.
Hypothesis A_eq_dec : forall x y : A, {x = y} + {x <> y}.
... |
Require Import Arith.
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Set Implicit Arguments.
Lemma leb_false_lt : forall m n, leb m n = false -> n < m.
Proof.
(* Goal: forall (m n : nat) (_ : @eq bool (Nat.leb m n) true), le m n *)
induction m; intros.
- discriminate.
- simp... |
Require Import StructTact.StructTactics.
Require Import FunctionalExtensionality.
Definition update {A B : Type} (A_eq_dec : forall x y : A, {x = y} + {x <> y}) st h (v : B) :=
fun nm => if A_eq_dec nm h then v else st nm.
Section update.
Variables A B : Type.
Hypothesis A_eq_dec : forall x y : A, {x = y} + {x... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListTactics.
Require Import StructTact.ListUtil.
Require Import StructTact.RemoveAll.
Require Import StructTact.PropUtil.
Require Import FunctionalExtensionality.
Require Import Sumbool.
Require Import Sorting.... |
Require Import Omega.
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListTactics.
Require Import StructTact.FilterMap.
Require Import StructTact.RemoveAll.
Set Implicit Arguments.
Fixpoint subseq {A} (xs ys : list A) : Prop :=
match xs, ys with
| []... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListTactics.
Set Implicit Arguments.
Fixpoint filterMap {A B} (f : A -> option B) (l : list A) : list B :=
match l with
| [] => []
| x :: xs => match f x with
| None => filterMap ... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Set Implicit Arguments.
Inductive Nth {A : Type} : list A -> nat -> A -> Prop :=
| Nth_0 : forall x l, Nth (x :: l) 0 x
| Nth_S : forall l x n y, Nth l n x -> Nth (y :: l) (S n) x.
Section nth.
Variable A : Type.
Lemma nth_error... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.Before.
Require Import StructTact.Prefix.
Set Implicit Arguments.
Fixpoint before_func {A: Type} (f : A -> bool) (g : A -> bool) (l : list A) : Prop :=
match l with
| [] => False
| a :: l' =>
f a = ... |
Require Import String.
Require Import Ascii.
Require Import Arith.
Require Import OrderedType.
Require Import OrderedTypeEx.
Require Import StructTact.StructTactics.
Inductive lex_lt: string -> string -> Prop :=
| lex_lt_lt : forall (c1 c2 : ascii) (s1 s2 : string),
nat_of_ascii c1 < nat_of_ascii c2 ->
lex_lt... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListUtil.
Require Import OrderedType.
Require Import OrderedTypeEx.
Set Implicit Arguments.
Fixpoint fin (n : nat) : Type :=
match n with
| 0 => False
| S n' => option (fin n')
end.
Fixpoint fin_... |
Require Import Arith.
Require Import Omega.
Require Import List.
Import ListNotations.
Require Import Sorting.Permutation.
Require Import StructTact.StructTactics.
Require Import StructTact.ListTactics.
Set Implicit Arguments.
Notation member := (in_dec eq_nat_dec).
Lemma seq_range :
forall n a x,
In x (seq a ... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Set Implicit Arguments.
Section assoc.
Variable K V : Type.
Variable K_eq_dec : forall k k' : K, {k = k'} + {k <> k'}.
Fixpoint assoc (l : list (K * V)) (k : K) : option V :=
match l with
| [] => None
| (k', v) ... |
Require Import List.
Import ListNotations.
Require Import StructTact.StructTactics.
Require Import StructTact.ListTactics.
Fixpoint before_all {A : Type} (x : A) y l : Prop :=
match l with
| [] => True
| a :: l' =>
~ In x l' \/
(y <> a /\ before_all x y l')
end.
Section before_all.
Variabl... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
From mathcomp Require Import all_ssreflect all_algebra all_field.
Set Implicit Arguments.
Unset Strict Implicit.
Unset Printing Implicit Defensive.
Import GRing.Theory Num.Theory UnityRootTheory.
Open Scope ring_scope.
(** Starting from cyril exercise *)
Section PreliminaryLemmas.
(**
* Preliminaries
Let's extend t... |
From mathcomp Require Import all_ssreflect all_algebra all_field.
Require Import gauss_int.
Set Implicit Arguments.
Unset Strict Implicit.
Unset Printing Implicit Defensive.
Import GRing.Theory Num.Theory UnityRootTheory.
Open Scope nat_scope.
Definition sum_of_two_square :=
[qualify a x |
[exists a : 'I_... |
(** * Coq codes *)
(** ** Dependencies *)
Require Export RegExp.Utility.
Require Export RegExp.Definitions.
(** ** [Empty] *)
(** [Empty] corresponds to 0 in Kleene algebra. *)
Lemma Empty_false : forall s, Empty ~!= s.
Proof.
(* Goal: forall (s : string) (r : RegExp), @eq bool (matches (Or Empty r) s) (matches r s)... |
(** * Coq codes *)
(** ** Dependencies *)
Require Export Ascii.
Require Export String.
Require Export List.
Require Export Relation_Definitions.
(** ** Equality and equivalence *)
Definition bool_eq (a a':bool) : Prop := a = a'.
Lemma bool_eq_equiv : equiv bool bool_eq.
Proof.
(* Goal: equiv string string_eq *)
u... |
(** * Coq codes *)
(** ** Dependencies *)
Require Export RegExp.Utility.
Require Export RegExp.Definitions.
Require Export RegExp.Boolean.
Require Export RegExp.Concat.
Unset Standard Proposition Elimination Names.
(** ** [Char] *)
Lemma Char_true : forall c, (Char c) ~== (String c ""%string).
Proof.
(* Goal: foral... |
(** * Coq codes *)
(** ** Dependencies *)
Require Import Recdef.
Require Import Arith.Wf_nat.
Require Import Omega.
Require Export RegExp.Utility.
Require Export RegExp.Definitions.
Require Export RegExp.Boolean.
Require Export RegExp.Concat.
Unset Standard Proposition Elimination Names.
(** ** Lemmas for Star *)
L... |
(** * Definitions *)
(** [RegExp], a type for regular expressions, consists of following constructors:
- [Empty] : matches no strings,
- [Eps] : matches an empty string $(\epsilon)$,
- [Char c] : matches a single charater [c],
- [Cat r1 r2] : [r1 ++ r2] matches [s1 ++ s2] iff [r1, r2] match [s1, s2], respectively,
... |
(** * Coq codes *)
(** ** Dependencies *)
Require Export RegExp.Utility.
Require Export RegExp.Definitions.
Require Export RegExp.Boolean.
(** ** [Cat] is morphism *)
Lemma Cat_morphism_s : forall s r0 r1 r0' r1',
r0 =R= r1 -> r0' =R= r1' -> (r0 ++ r0') ~= s = (r1 ++ r1') ~= s.
Proof.
(* Goal: forall (s : string... |
(** * Coq codes *)
(** ** Dependencies *)
Require Import Recdef.
Require Import Arith.Wf_nat.
Require Import Omega.
Require Export RegExp.Utility.
Require Export RegExp.Definitions.
Require Export RegExp.Boolean.
Require Export RegExp.Concat.
Require Export RegExp.Star.
(** ** Define [includes] *)
Definition include... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* This program is free software; you can redistribute it and/or *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1 *)
(* of the License, or (at your option) any later version. *)
(* ... |
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *)
(* Distributed under the terms of CeCILL-B. *)
Require Import mathcomp.ssreflect.ssreflect.
From mathcomp
Require Import ssrfun ssrbool eqtype ssrnat seq choice fintype.
(***********************************... |
(* Contribution to the Coq Library V6.3 (July 1999) *)
(****************************************************************************)
(* The Calculus of Inductive Constructions *)
(* *)
(* ... |
(* Contribution to the Coq Library V6.3 (July 1999) *)
(****************************************************************************)
(* The Calculus of Inductive Constructions *)
(* *)
(* ... |
(* Contribution to the Coq Library V6.3 (July 1999) *)
(****************************************************************************)
(* The Calculus of Inductive Constructions *)
(* *)
(* ... |
(* Contribution to the Coq Library V6.3 (July 1999) *)
(****************************************************************************)
(* The Calculus of Inductive Constructions *)
(* *)
(* ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.