Leonardo de Moura
1cd44e894b
feat(library/tactic/class_instance_synth): conservative class-instance resolution: expand only definitions marked as reducible
...
closes #442
2015-02-24 16:12:35 -08:00
Leonardo de Moura
a35cce38b3
feat(frontends/lean): new semantics for "protected" declarations
...
closes #426
2015-02-11 14:09:25 -08:00
Jeremy Avigad
5ef510f290
feat(library/logic/axioms/prop_complete): add by_cases, by_contradiction
2015-02-01 11:17:45 -08:00
Jeremy Avigad
003a2c1e2c
refactor(library/logic/axioms): rename files, import logic.axioms.classical now imports all classical axioms
2015-02-01 11:17:45 -08:00
Jeremy Avigad
ba15da8d83
refactor(library/init/reserved_notation): increase binding strength of ^-1 to max+10
2015-01-26 20:38:21 -05:00
Leonardo de Moura
8246feff67
refactor(library/logic/eq): cleanup proof
2015-01-13 17:12:21 -08:00
Leonardo de Moura
2e4a2451e6
refactor(library/reducible): simplify reducible/irreducible semantics
2015-01-08 18:52:18 -08:00
Jeremy Avigad
6ad091d7bf
refactor(library): clean up headers and markdown files
2014-12-22 15:33:42 -05:00
Jeremy Avigad
fe424add26
refactor(library/logic/axioms): rename theorems
2014-12-22 15:33:42 -05:00
Leonardo de Moura
abe129aa4f
refactor(library): rename theorems "iff.flip_sign -> not_iff_not_of_iff" and "decidable_iff_equiv -> decidable_of_decidable_of_iff"
2014-12-15 19:17:51 -08:00
Leonardo de Moura
5cf8064269
refactor(library): rename exists_elim and exists_intro to exists.elim
...
and exists.intro
2014-12-15 19:07:38 -08:00
Jeremy Avigad
da719e6ee4
refactor(library/logic): rename theorems
2014-12-15 16:13:04 -05:00
Jeremy Avigad
3e9a484851
refactor(library/logic/connectives): rename theorems
2014-12-15 15:05:44 -05:00
Leonardo de Moura
7c8ab81cc6
feat(library/logic/quantifiers): add decidable_forall_eq and decidable_exists_eq theorems
2014-12-13 15:48:04 -08:00
Leonardo de Moura
477d79ae47
refactor(library/init): move more theorems to logic
2014-12-12 13:50:53 -08:00
Leonardo de Moura
d6c8e23b03
refactor(library/init/logic): move theorems to library/logic
2014-12-12 13:24:17 -08:00
Leonardo de Moura
d50b7a8ba1
refactor(library/init/logic): move theorems to logic/cast
2014-12-12 12:39:16 -08:00
Leonardo de Moura
5d4b6a3de2
chore(library/logic/logic.md): adjust documentation
2014-11-30 21:19:56 -08:00
Leonardo de Moura
697d4359e3
refactor(library): add 'init' folder
2014-11-30 20:34:12 -08:00
Leonardo de Moura
dad94eafbe
refactor(data/nat/decl): use new naming convention at data/nat/decl.lean
2014-11-30 15:07:09 -08:00
Leonardo de Moura
f24eed50af
refactor(library/logic/heq): minor change
2014-11-30 13:52:34 -08:00
Leonardo de Moura
d7042c4618
fix(library/logic/heq): heq.to_eq must be transparent because it is needed in the 'inversion' tactic used by definitional package
2014-11-28 23:49:17 -08:00
Jeremy Avigad
bb8d436e75
refactor(library/algebra/relation, library/logic/instances): revise equivalence relations and congruences to use structure command
2014-11-28 22:54:15 -08:00
Leonardo de Moura
faf736a9d2
feat(library/logic/default): add wf_k
2014-11-22 13:25:46 -08:00
Leonardo de Moura
a3daff702a
fix(library/logic/wf): typo
2014-11-22 13:25:46 -08:00
Leonardo de Moura
47b6cfb28d
feat(library/logic/if): add dependent if-then-else: dite
2014-11-22 09:56:32 -08:00
Leonardo de Moura
29a0d3109b
refactor(library/logic/connectives): mark theorems used to prove 'decidable' theorems as transparent
...
if we don't this, then 'if-then-else' expressions depending on theorems
such as 'and_decidable', 'or_decidable' will not compute inside the kernel
2014-11-22 09:32:43 -08:00
Leonardo de Moura
7c54dbce10
refactor(library/logic/if): mark basic theorem transparent
2014-11-22 00:19:05 -08:00
Leonardo de Moura
acf1c501ad
refactor(library/logic/prop): allow 'absurd' to generate Type
2014-11-22 00:19:05 -08:00
Leonardo de Moura
2e121182de
refactor(library/logic/decidable): rename decidable_rel -> decidable_pred, and decidable_rel2 -> decidable_rel
2014-11-21 11:49:31 -08:00
Leonardo de Moura
47e3f0e770
fix(library/logic/wf_k): missing file
2014-11-21 10:03:20 -08:00
Leonardo de Moura
e77cd59368
refactor(library/logic): add basic definitions for relations at logic/relation.lean
...
We need them for wf and definitional package
2014-11-18 17:32:22 -08:00
Leonardo de Moura
bf5f48730c
refactor(library/data/subtype): define subtype using 'structure' command
2014-11-16 15:01:14 -08:00
Leonardo de Moura
627c7cb531
chore(library/logic/wf): remove unnecessary :max
2014-11-14 17:37:05 -08:00
Leonardo de Moura
edd04881ee
fix(library/logic): import prod and unit declarations in logic
...
Reason: we need them for automatically generating constructions needed
by the definitional package
2014-11-12 16:54:50 -08:00
Leonardo de Moura
9c93816211
chore(library/logic/wf): cleanup
2014-11-10 21:19:38 -08:00
Leonardo de Moura
4ebd3e2c27
feat(library/logic/wf): transitive closure of a well-founded relation is well-founded
2014-11-10 21:07:28 -08:00
Leonardo de Moura
22b7a0615f
fix(frontends/lean): coercion affects other modules
2014-11-10 20:14:19 -08:00
Leonardo de Moura
64043094f4
feat(library/logic/wf): some basic definitions for constructing well_founded relations
2014-11-10 17:57:55 -08:00
Floris van Doorn
bf27a17dec
style(library): add some comments
2014-11-08 19:12:54 -08:00
Floris van Doorn
8c7fdd3708
style(library): rename set_category to discrete_category
2014-11-08 19:12:54 -08:00
Leonardo de Moura
ad2ecfb7a8
refactor(library/logic/cast): move heq declaration to a separate module
...
heq is be needed for some automatically generated constructions.
So, we want it available with the least number of dependencies.
2014-11-08 10:19:29 -08:00
Leonardo de Moura
92b0a538c5
refactor(library/logic/wf): add well_founded class, and cleanup file
2014-11-07 10:18:24 -08:00
Leonardo de Moura
781f709bb4
feat(library/logic): import wf.lean in logic/default.lean
...
We will use well-founded recursion in the definitional package
2014-11-06 15:03:13 -08:00
Leonardo de Moura
194247f75b
refactor(library/logic/wf): minimize dependencies
2014-11-06 14:59:03 -08:00
Leonardo de Moura
b177c84b06
feat(library/logic): add well-founded recursion
...
It also removes the old well-founded induction theorem based on
classical principles
2014-11-06 14:49:53 -08:00
Leonardo de Moura
d306c42a1f
refactor(library/logic): cleanup some of the proofs in cast.lean, remove piext axiom
...
Remark: the main motivation for piext was Lean 0.1 simplifier.
We are using a different approach in Lean 0.2.
The axiom is not needed anymore.
It is also not used in any part of the standard library
2014-11-05 16:43:31 -08:00
Floris van Doorn
d8a616fa70
refactor(library): major changes in the library
...
I made some major changes in the library. I wanted to wait with pushing
until I had finished the formalization of the slice functor, but for
some reason that is very hard to formalize, requiring a lot of casts and
manipulation of casts. So I've not finished that yet.
Changes:
- in multiple files make more use of variables
- move dependent congr_arg theorems to logic.cast and proof them using heq (which doesn't involve nested inductions and fewer casts).
- prove some more theorems involving heq, e.g. hcongr_arg3 (which do not
require piext)
- in theorems where casts are used in the statement use eq.rec_on
instead of eq.drec_on
- in category split basic into basic, functor and natural_transformation
- change the definition of functor to use fully bundled
categories. @avigad: this means that the file semisimplicial.lean will
also need changes (but I'm quite sure nothing major). You want to
define the fully bundled category Delta, and use only fully bundled
categories (type and ᵒᵖ are notations for the fully bundled
Type_category and Opposite if you open namespace category.ops). If you
want I can make the changes.
- lots of minor changes
2014-11-03 18:45:12 -08:00
Leonardo de Moura
591e566472
feat(frontends/lean): try to inject symmetry (if needed) in calc proofs, add calc_symm command for configuring the symmetry theorem for a given operator
...
This is part of #268
2014-10-30 23:24:09 -07:00
Leonardo de Moura
777aa63660
fix(kernel/inductive): relax eliminator generation rules for empty types
...
This commit also removes the workaround false.rec_type. It is not needed anymore
2014-10-28 10:31:00 -07:00
Leonardo de Moura
c7f6a6b94e
feat(library/definitional/cases_on): automatically add 'cases_on'
2014-10-25 17:22:02 -07:00
Leonardo de Moura
cdcde661ef
feat(library/definitional/induction_on): automatically add 'induction_on'
2014-10-25 13:37:04 -07:00
Leonardo de Moura
a7a06ab0f8
feat(library/definitional/rec_on): automatically generate rec_on function for inductive datatypes
2014-10-25 13:08:59 -07:00
Leonardo de Moura
6c7e23ecaa
refactor(library): use 'reserve' notation in the standard library
2014-10-21 15:39:47 -07:00
Leonardo de Moura
40fb66bf07
feat(frontends/lean): change default precedence to 1
2014-10-20 18:40:55 -07:00
Leonardo de Moura
9edf780a00
feat(frontends/lean): elaborate inductive datatypes and introduction rules as a single elaboration problem
2014-10-13 18:35:11 -07:00
Leonardo de Moura
a26618e0f2
feat(frontends/lean): add '[]' notation for marking arguments where class-instance resolution should be applied
2014-10-12 13:06:00 -07:00
Floris van Doorn
c630b5ddb2
feat(library/algebra/category): use variables instead of parameters
2014-10-11 16:40:18 -07:00
Leonardo de Moura
d6d0593afb
refactor(library): remove some unnecessary sections
2014-10-10 16:33:58 -07:00
Leonardo de Moura
a41850227a
refactor(library/logic): use new K-like reduction to simplify some proofs
2014-10-10 14:52:21 -07:00
Leonardo de Moura
8f1b6178a7
chore(*): minimize the use of parameters
2014-10-09 07:13:06 -07:00
Floris van Doorn
ae3419f82f
feat(library): add definition of subsingleton and some other minor changes
2014-10-08 23:14:44 -07:00
Floris van Doorn
abee75c5e9
feat(quantifiers.lean): change exists_unique to a constructively stronger formulation
...
the previous formulation was constructively probably to weak to be useful
2014-10-08 23:14:44 -07:00
Leonardo de Moura
744cee8dd8
feat(frontends/lean): force 'classes' to be declared before instances are declared, closes #228
2014-10-07 18:02:15 -07:00
Leonardo de Moura
e91a64fb38
chore(library/logic): fix comments
2014-10-05 11:11:48 -07:00
Leonardo de Moura
73aa024c31
refactor(library/logic): remove 'core' subdirectory
2014-10-05 10:50:13 -07:00
Leonardo de Moura
0f90d10a13
refactor(logic/core/eq): use sections
2014-10-05 10:19:50 -07:00
Leonardo de Moura
5a927b6db4
refactor(library/logic/cast): define heq using inductive datatypes
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-10-03 21:40:51 -07:00
Leonardo de Moura
a52b21c92d
refactor(library): using section variables
2014-10-02 18:25:00 -07:00
Leonardo de Moura
d5cad765a0
feat(frontends/lean): enforce new semantics for section 'variables'
...
The library file logic/core/connectives uses the new feature.
2014-10-02 17:55:34 -07:00
Leonardo de Moura
f78d831de3
refactor(frontends/lean): remove hardcoded Type', and define it using notation
2014-10-02 14:29:51 -07:00
Leonardo de Moura
716cd4d651
refactor(library): rename namespace eq_ops to eq.ops
2014-10-01 17:51:17 -07:00
Leonardo de Moura
3ca1264f61
refactor(library): mark 'decidable' theorems as definitions
...
If we don't do that, then any 'if' term that uses one of these theorems
will get "stuck". That is, the kernel will not be able to reduce them
because theorems are always opaque
2014-09-30 09:02:37 -07:00
Floris van Doorn
3a95734fae
feat(library): changes in eq.lean sigma.lean and category.lean
...
in eq.lean, make rec_on depend on the proof, and add congruence theorems for n-ary functions with n between 2 and 5
in sigma.lean, finish proving equality of triples
in category.lean, define the functor category, and make the proofs of the arrow and slice categories easier for the elaborator
2014-09-26 19:45:23 -04:00
Floris van Doorn
5396e422d2
feat(library): add constructions of categories, some changes in eq, sigma and path
...
in eq, add theorem for proof irrelevance and congruence for binary functions
in sigma, add some support for triplets
in path, comment out two unneccesary definitions
in category, add Cat, slice, coslice, product and arrow categories, also add fully bundled approach
2014-09-26 19:45:23 -04:00
Leonardo de Moura
4e2377ddfc
refactor(frontends/lean): replace '[protected]' modifier with 'protected definition' and 'protected theorem', '[protected]' is not a hint.
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-19 15:54:32 -07:00
Leonardo de Moura
5d8c7fbdf1
refactor(frontends/lean): replace '[private]' modifier with 'private
...
definition' and 'private theorem', '[private]' is not a hint.
2014-09-19 15:54:32 -07:00
Leonardo de Moura
97b1998def
refactor(frontends/lean): replace '[opaque]' modifier with 'opaque
...
definition', '[opaque]' is not a hint, but a kind of definition
2014-09-19 15:54:32 -07:00
Leonardo de Moura
08ccd58eb6
feat(frontends/lean): add 'reducible' modifier for controlling which
...
definitions are unfolded during elaboration
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-19 15:54:32 -07:00
Leonardo de Moura
baf4c01de8
feat(frontends/lean): definitions are opaque by default
2014-09-19 15:54:32 -07:00
Leonardo de Moura
e3e2370a38
feat(frontends/lean): split 'opaque_hint' command into 'opaque' and 'transparent'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-16 18:03:40 -07:00
Jeremy Avigad
74cb289d48
refactor(library): rename algebra directory to struc, move categories.lean to algebra
2014-09-16 13:13:01 -07:00
Jeremy Avigad
9988914189
refactor(library/logic): move files in classes directory to core
2014-09-16 13:13:01 -07:00
Leonardo de Moura
9ac5f28b03
refactor(library/logic/core/eq): cleanup
2014-09-09 19:15:11 -07:00
Leonardo de Moura
b4d765ff2e
refactor(library/logic/core/cast): cleanup
2014-09-09 19:11:03 -07:00
Leonardo de Moura
9b9adf8831
refactor(library): replace decidable_eq with abbreviation
2014-09-09 16:09:05 -07:00
Leonardo de Moura
bd1bc336fb
feat(library/coercion): add simple trick for defining coercions to function-class in a convenient way, closes #31
2014-09-09 14:36:36 -07:00
Leonardo de Moura
5087f03889
refactor(library/logic/classes/decidable): rename 'decidable_eq_to_decidable' theorem to 'of_decidable_eq'
2014-09-09 09:27:26 -07:00
Leonardo de Moura
b4793df653
feat(frontends/lean): rename '[fact]' to '[visible]'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-08 07:47:42 -07:00
Leonardo de Moura
35e68fea76
feat(library/logic/classes/decidable): generalize 'by_cases' theorem
2014-09-08 00:16:20 -07:00
Leonardo de Moura
559dd586f2
feat(library): add 'decidable_eq' class
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-07 22:23:36 -07:00
Leonardo de Moura
48e5a2b6ad
feat(library/classes/inhabited): add dfun_inhabited theorem
2014-09-07 19:08:31 -07:00
Leonardo de Moura
fea516af24
feat(frontends/lean/elaborator): allow Pi/forall local instances
2014-09-07 18:16:33 -07:00
Leonardo de Moura
28f025c6d7
refactor(library/logic/core): use subscripts
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 22:43:30 -07:00
Leonardo de Moura
6632a50015
refactor(library): add namespaces 'or', 'and' and 'iff'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 21:25:21 -07:00
Leonardo de Moura
68d9bef860
refactor(library): add 'eq' and 'ne' namespaces
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 18:41:06 -07:00
Leonardo de Moura
2bc6f92d33
refactor(library): add 'and' namespace
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 17:44:53 -07:00
Leonardo de Moura
364bba2129
feat(frontends/lean/inductive_cmd): prefix introduction rules with the name of the inductive datatype
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 17:26:36 -07:00
Leonardo de Moura
8743394627
refactor(kernel/inductive): replace recursor name, use '.rec' instead of '_rec'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 15:04:57 -07:00
Leonardo de Moura
e51c4ad2e9
feat(frontends/lean): rename 'using' command to 'open'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-03 16:00:38 -07:00