Commit graph

775 commits

Author SHA1 Message Date
Rob Lewis
1f4765e30a feat(library/algebra/ordered_ring): add theorems used for rational upper bounds 2015-06-16 11:30:12 -07:00
Rob Lewis
cf7c85e5fd feat(library/data/real): fill in lots of sorrys about pnats 2015-06-16 11:30:12 -07:00
Rob Lewis
a79ec6b0d4 feat(library/data/pnat): move facts about positive nats to their own file 2015-06-16 11:30:12 -07:00
Jeremy Avigad
9249ebdaab feat(library/data/{nat,int}/div.lean): add properties of add and mod 2015-06-15 22:53:11 +10:00
Jeremy Avigad
a4a8253f50 refactor(library,hott,tests): rename succ_inj to succ.inj, add abbreviation eq_of_succ_eq_succ 2015-06-15 22:52:38 +10:00
Haitao Zhang
679bb8b862 feat(library/data/fin): add more theorems on finite ordinals
Add defintional equalities, properties of lifting and lowering functions, and definitions of madd.
2015-06-14 20:49:47 -07:00
Haitao Zhang
844d59c2ae feat(library/data/fintype/function): add theorems of all nodup lists and all injective functions 2015-06-14 20:49:47 -07:00
Haitao Zhang
ef4b4d19ce feat(library/data/list/basic): add cons related equalities 2015-06-14 16:59:56 -07:00
Haitao Zhang
798b240149 fix(library/data/list/comb): adjust dmap related names to comply with convention 2015-06-14 16:59:56 -07:00
Haitao Zhang
6105263222 feat(library/data/list/comb): add theorem on dmap and adjust names 2015-06-11 15:29:52 -07:00
Haitao Zhang
1a9521dc9c fix(library/data/fintype/function): convert line endings from crlf to lf 2015-06-11 15:29:43 -07:00
Leonardo de Moura
1b5d1136d9 refactor(library/data/finset/card): remove unnecessary xrewrite
We can use the default 'rewrite' tactic after the commits pushed today.
2015-06-10 18:46:16 -07:00
Leonardo de Moura
dc8768627c refactor(library/data/fintype/function): cleanup proof 2015-06-10 18:21:15 -07:00
Leonardo de Moura
8fbe22f263 refactor(library/data/finset/basic): cleanup proof 2015-06-10 18:19:16 -07:00
Leonardo de Moura
226a5800dd fix(library/data/rat/order): adjust file to recent changes 2015-06-10 16:56:17 -07:00
Jeremy Avigad
3c1f5f4e33 feat(library/data/{set,finset}): add more cardinality facts, rename, and add a lemma from Haitao 2015-06-10 16:39:17 -07:00
Jeremy Avigad
658c5a2c49 feat(library/rat/basic.lean): add reduce for rat, and num and denom 2015-06-10 16:39:17 -07:00
Leonardo de Moura
4b91cfccff feat(frontends/lean/builtin_exprs): make notation ( e : T ) builtin
In the previous approach, the following (definitionally equal) term was being generated

       (fun (A : Type) (a : A), a) T e
2015-06-10 14:52:59 -07:00
Rob Lewis
d287b20018 chore(library/data/real): move more lemmas to algebra 2015-06-09 16:27:55 +10:00
Rob Lewis
01f0bb827c feat(library/data/real): use new algebra lemmas in completeness proof 2015-06-09 16:14:52 +10:00
Rob Lewis
b1aea149db chore(library/data/real): update md 2015-06-09 15:43:43 +10:00
Rob Lewis
e112468f99 feat(library/data/real): prove reals are Cauchy complete 2015-06-09 15:39:51 +10:00
Rob Lewis
3749a8ad04 chore(library/data/real): update real.md 2015-06-09 15:39:51 +10:00
Leonardo de Moura
1c5c79fbc1 refactor(library/data/list/perm): use improved 'obtain' to cleanup proof 2015-06-08 11:58:21 -07:00
Haitao Zhang
6949e2d422 feat(library/data/fintype): add finite function related theories
develop kth related techniques, all_lists_of_len, all_funs, map between lists and functions, finite inverse and cardinality
remove function module from default import list for now
2015-06-08 10:48:22 -07:00
Leonardo de Moura
35eae96aa5 chore(library/data/int/gcd): remove 'TODO'
The 'TODO' was fixed by commit 496189feed
2015-06-08 10:45:05 -07:00
Jeremy Avigad
e59400b58c feat(library/data/int/{div,gcd}): add some theorems, to reduce rationals 2015-06-08 22:43:51 +10:00
Jeremy Avigad
1c93c5bbb2 feat(library/logic/{connectives.lean,quantiers.lean}): add iff congruence rules 2015-06-08 16:58:08 +10:00
Jeremy Avigad
feb385748f refactor(library/data/set/map.lean): put map into set namespace
This is needed to repair a conflict in the tutorial, but it is the right thing to do anyhow. The type "map A B" should not be a top-level identifier.
2015-06-06 18:58:33 -07:00
Leonardo de Moura
7db84c7036 refactor(library/data): replace 'fin' with Haitao's 'less_than'
The commit also fixes vector to use the new definition.
2015-06-05 10:33:19 -07:00
Jeremy Avigad
453da48dd5 feat(library/data/less_than.lean): add finite ordinals from Haitao Zhang 2015-06-05 09:32:00 -07:00
Jeremy Avigad
370860e1b0 feat(library/data/fintype,finset): add cardinality for finite types from Haitao Zhang 2015-06-05 09:32:00 -07:00
Jeremy Avigad
f475408f4c feat(library/data/list/*): add theorems from Haitao Zhang and clean up 2015-06-05 09:32:00 -07:00
Jeremy Avigad
c2aa8c6720 feat(library/data/finset/partition.lean): add theory of partitions into finsets by Haitao Zhang 2015-06-05 09:32:00 -07:00
Floris van Doorn
ff41886a32 feat(nat/bquant): give instances for quantification bounded with le
also add theorems c_iff_c to logic/connectives, where c is a connective
2015-06-04 20:14:13 -04:00
Floris van Doorn
7f5caab694 feat(nat): redefine le and lt in the standard library 2015-06-04 20:14:13 -04:00
Leonardo de Moura
63f61a35f4 feat(library/data/list/set): cleanup nodup_map proof 2015-06-04 15:21:40 -07:00
Leonardo de Moura
9a7cff0e89 feat(library/data/list/comb): add length_product theorem 2015-06-04 15:11:09 -07:00
Jeremy Avigad
df69bb4cfc feat(library/*): add theorems from Haitao on sets and functions, clean up 2015-06-04 11:55:25 -07:00
Leonardo de Moura
c841e63649 refactor(library/data/fintype): create 'fintype' subdirectory 2015-06-03 16:43:55 -07:00
Leonardo de Moura
2a6ea2c6fb feat(library/data/finset/to_set): add to_set.inj 2015-06-03 14:05:43 -07:00
Leonardo de Moura
a8c9121d2e feat(library/data/vec): add vector as list subtype 2015-06-02 22:09:23 -07:00
Leonardo de Moura
7a39d5aaa3 feat(library/data): add auxiliary definitions 2015-06-02 22:08:25 -07:00
Leonardo de Moura
228a99af7e feat(library/data/subtype): cleanup proof 2015-06-02 19:51:28 -07:00
Leonardo de Moura
50fe4ec6c0 feat(library/data/encodable): add quot.rep definition for choosing equivalence class representative for equivalence classes of encodable types 2015-06-02 11:03:24 -07:00
Rob Lewis
b1404c5943 feat(library/data/real): fill in sorrys in proof that R is l.o. field 2015-06-01 23:00:53 +10:00
Rob Lewis
9843e61583 feat(library/data/real): define inverses of reals, prove (classically) that R is a discrete linear ordered field 2015-06-01 23:00:53 +10:00
Jeremy Avigad
82142b60f0 refactor(library/data/finset/basic.lean): remove finset / finset.finset duplicate 2015-06-01 12:35:44 +10:00
Jeremy Avigad
dcae29a253 feat(library/data/int/gcd.lean): add gcd for the integers 2015-06-01 12:35:44 +10:00
Jeremy Avigad
ffa648a090 feat/refactor(library/*): various additions and improvements 2015-06-01 12:35:44 +10:00
Jeremy Avigad
cdecc309b3 fix(library/data/finset/to_set.lean): to_set does not require decidable equality 2015-06-01 12:35:44 +10:00
Jeremy Avigad
b76445df39 feat(library/data/{nat,int}/div.lean,*): improve and extend div in nat and int 2015-05-30 22:10:21 +10:00
Jeremy Avigad
c986ee305b refactor(library/data/nat/gcd.lean): move gcd to a new file 2015-05-30 22:10:21 +10:00
Jeremy Avigad
cc0a620db1 feat(library/data/{nat,int}/div.lean): add to and improve div library 2015-05-30 22:10:21 +10:00
Rob Lewis
82f85a574d feat(library/data/real): prove reals form an ordered ring 2015-05-29 14:11:51 +10:00
Rob Lewis
2273dc669e feat(library/data): fill in sorrys in int and rat orderings 2015-05-29 14:11:51 +10:00
Rob Lewis
6dfcc4610b feat(data): update orderings on int and nat to conform to new algebraic hierarchy 2015-05-29 14:11:51 +10:00
Leonardo de Moura
dc6411b903 feat(library/inductive_unifier_plugin): restrict rule that was generating non-terminating behavior
see issue #632
2015-05-27 14:41:12 -07:00
Leonardo de Moura
5da4922397 feat(library/data/list/perm): cleanup proofs
refl and symm were refering to the setoid.refl and setoid.symm.
Moreover, they were producing harder elaboration problems
2015-05-27 12:30:56 -07:00
Leonardo de Moura
47e5633498 feat(frontends/lean/calc_proof_elaborator): avoid unnecessary unfolding in the calc tactic 2015-05-27 12:07:39 -07:00
Floris van Doorn
0c7e16e017 feat(library.data.int.basic): move theorems about successor and predecessor from HoTT to standard library 2015-05-26 21:37:01 -07:00
Leonardo de Moura
7f0951b8e7 feat(library/tactic): improve assumption tactic performance 2015-05-25 20:22:37 -07:00
Rob Lewis
393cefcf97 feat(library/data/real): define real numbers, prove they form a commutative ring 2015-05-26 12:05:53 +10:00
Rob Lewis
681f431d4b feat(library/data/rat): make rat subtraction reducible, fix migration of min/max 2015-05-26 11:52:34 +10:00
Leonardo de Moura
4152ebfa23 refactor(library/data/nat): use new tactics 2015-05-25 18:14:52 -07:00
Jeremy Avigad
39129f112b refactor(library/*): do various renamings 2015-05-25 16:50:42 -07:00
Jeremy Avigad
a64c0ea845 feat/refactor(library/data/{int,rat}/*): improve casting from nat to int to rat 2015-05-25 16:50:42 -07:00
Jeremy Avigad
4ed9e46532 refactor(library/data/int/*): use better direction for of_nat theorems 2015-05-25 16:50:42 -07:00
Jeremy Avigad
fdc89cd285 refactor(library/algebra/order.lean,library/{data,algebra}/*): use better names for order theorems 2015-05-25 16:50:42 -07:00
Jeremy Avigad
81c0ef8c89 refactor(library/data/nat/*): cleanup, additions, renaming 2015-05-25 16:50:42 -07:00
Jeremy Avigad
7c92161e49 refactor(library/data/finset/basic.lean): change order of arguments to induction tactic 2015-05-25 16:50:42 -07:00
Leonardo de Moura
6db08c5519 test(library): test new tactics in the standard library 2015-05-25 16:48:33 -07:00
Leonardo de Moura
7e875c8d85 refactor(library): simplify theorems using improved tactics 2015-05-25 10:43:28 -07:00
Leonardo de Moura
88975927e6 fix(library/tactic/relation_tactics): beta-reduce goal before trying to extract head symbol 2015-05-24 18:56:35 -07:00
Leonardo de Moura
c453bb52a9 feat(library/data/stream): add notation and commonly used definitions 2015-05-24 16:53:58 -07:00
Leonardo de Moura
880027ea0e feat(library/data/stream): define stream mem predicate and prove basic theorems 2015-05-24 15:47:33 -07:00
Leonardo de Moura
607a5fbb86 feat(library/data/stream): define cycle, inits, tails for streams and prove basic theorems 2015-05-24 13:42:51 -07:00
Leonardo de Moura
3181471024 feat(library/data/list/basic): add nth_eq_some aux theorem 2015-05-24 10:10:23 -07:00
Leonardo de Moura
32a2425e02 feat(library/data/stream): prove take lemma for infinite streams 2015-05-23 23:01:54 -07:00
Leonardo de Moura
75901157a1 feat(library/data/stream): add more declarations and examples demonstrating how to use eq_of_bisim 2015-05-23 22:03:17 -07:00
Leonardo de Moura
d987d6cc84 feat(library/data/stream): simplify corecursion proofs, define interleave operation by corecursion, add one example of proof by bisimulation 2015-05-23 16:00:08 -07:00
Leonardo de Moura
8685e8ad7e feat(library/data/stream): define corec for infinite streams 2015-05-23 14:32:52 -07:00
Leonardo de Moura
dd4dd154ec feat(library/data/stream): add bisimulation for streams 2015-05-23 12:07:27 -07:00
Jeremy Avigad
8bebd104ff refactor(library/*): remove 'Module:' lines 2015-05-23 20:52:23 +10:00
Jeremy Avigad
f65a49b2c3 feat/fix(library/data/nat,int): add power to int, add trans attributes, power notation 2015-05-23 15:38:42 +10:00
Jeremy Avigad
a662f925cb refactor(library/data/quotient.lean): improve comments 2015-05-23 14:21:16 +10:00
Jeremy Avigad
4bc93b59e3 feat(library/data/rat/{basic,order}.lean): add property of of_int 2015-05-23 12:34:07 +10:00
Jeremy Avigad
59c1801921 refactor(library/data/{list,set,finset}/basic.lean): make subset reserved notation 2015-05-23 12:34:07 +10:00
Leonardo de Moura
fe32b9fa7f feat(library/data/stream): add infinite streams 2015-05-22 18:08:11 -07:00
Leonardo de Moura
1665ee39e8 feat(library/data/finset/card): test 'induction' tactic at finset 2015-05-19 15:56:51 -07:00
Leonardo de Moura
3e87f09d78 feat(library/tactic/induction_tactic): add support for user-defined recursors that contain parameters that should be synthesized by type class resolution 2015-05-19 15:33:46 -07:00
Leonardo de Moura
e1c2340db2 fix(frontends/lean): consistent behavior for protected declarations
see https://github.com/leanprover/lean/issues/604#issuecomment-103265608

closes #609
2015-05-18 22:35:18 -07:00
Floris van Doorn
2144036cdb feat(hott.circle): prove that the fundamental group of the circle is equal to the integers, as groups
Also many minor fixes at various places
2015-05-18 15:59:55 -07:00
Leonardo de Moura
19361f0196 feat(library/unifier): do not fire type class resolution as last resort when type contains metavariables
see discussion at #604
2015-05-18 15:45:23 -07:00
Jeremy Avigad
566acf4b31 feat(library/data/finset/card.lean): add card_Union_of_disjoint and other theorems 2015-05-17 19:06:10 +10:00
Jeremy Avigad
6549940c63 feat(library/data/finset/bigops.lean): add Union for finsets 2015-05-17 17:50:32 +10:00
Jeremy Avigad
783dd61083 feat(library/data/finset/basic.lean): add useful calculation rules for quantifiers 2015-05-17 17:49:02 +10:00
Jeremy Avigad
9720d84095 refactor(library/algebra/group_bigops.lean,library/data/nat/bigops.lean): add ext principle, clean up file 2015-05-17 16:00:38 +10:00
Jeremy Avigad
4764f6e8ec refactor(library/algebra/group_bigops.lean,library/data/nat/bigops.lean): simplify naming scheme for bigops 2015-05-17 15:24:37 +10:00
Jeremy Avigad
981bf93ce0 feat(library/data/default.lean): add rat and vector 2015-05-17 12:19:47 +10:00
Jeremy Avigad
ff701a9812 feat(library/data/nat/bigops.lean): add finite products and sums for nat 2015-05-16 22:26:59 +10:00
Jeremy Avigad
eae047bd31 refactor,feat(library/{data,algebra}): move bigops to algebra, define sums 2015-05-16 18:42:13 +10:00
Jeremy Avigad
63bb4b558a fix(library/data/set/{classical_inverse.lean,map.lean}): protect definitions in map, to avoid ambiguity 2015-05-16 18:24:19 +10:00
Jeremy Avigad
26ad6dde69 fix(library/data/fintype.lean): reduce imports, to avoid cyclic dependencies 2015-05-16 17:53:35 +10:00
Jeremy Avigad
81d0d4aa53 fix(library/data/{set,finset}/basic.lean: delete \{{ \}}} notation (conflicts with records) 2015-05-16 17:53:35 +10:00
Jeremy Avigad
8de6a4bb4c feat(library/algebra/group_pow.lean,library/data/nat/power.lean): add generic power operation on monoids and groups 2015-05-13 22:19:02 -07:00
Jeremy Avigad
05e28aaf19 feat(library/data/nat/{basic.lean,order.lean}): use migrate 2015-05-12 06:20:51 -07:00
Jeremy Avigad
42616f766f refactor(library/data/{nat,int,rat}/{basic.lean,order.lean}: make algebra instance declarations local 2015-05-12 06:20:47 -07:00
Leonardo de Moura
f25c301c98 fix(library/data/rat): migrate for rat 2015-05-12 04:46:34 -07:00
Leonardo de Moura
d2adf922b7 refactor(library/data/int): use "migrate" command 2015-05-12 04:24:13 -07:00
Leonardo de Moura
f59a81d744 refactor(library/data): use new 'obtain' expression 2015-05-11 09:14:48 -07:00
Jeremy Avigad
a009cf24e3 feat(library/data/finset/{basic,card,comb}.lean: add theorems, including card of an injective image 2015-05-11 09:03:57 -07:00
Jeremy Avigad
3e07716b5d feat(library/data/finset/to_set.lean): add finset/set translation theorems 2015-05-11 09:03:56 -07:00
Jeremy Avigad
efbca4c78e feat(library/data/finset/finset.md): add markdown file 2015-05-11 09:03:56 -07:00
Jeremy Avigad
9d73aa657b feat(library/data/{finset,list}/comb.lean): add 'any' for finsets 2015-05-11 09:03:56 -07:00
Leonardo de Moura
379af8a04e feat(library): avoid 'definition' hack for theorems 2015-05-09 12:15:30 -07:00
Leonardo de Moura
bd28396be0 feat(kernel): transparent theorems
closes #576
2015-05-09 11:42:29 -07:00
Leonardo de Moura
3aac370629 fix(library/data/finset/basic): type error on the finset.induction proof 2015-05-08 11:08:24 -07:00
Jeremy Avigad
624b664950 refactor(library/data/list/basic.lean): make minor renaming 2015-05-08 20:25:28 +10:00
Jeremy Avigad
75e50fd371 feat(library/data): update defaults and markdown files 2015-05-08 20:23:15 +10:00
Jeremy Avigad
b56f7a06d5 refactor(library/data/finset/bigop.lean): use inter eq empty rather than disjoint 2015-05-08 20:06:21 +10:00
Jeremy Avigad
6fce01385c feat(library/data/{finset,list}/bigop.lean: generalize bigops from group to monoid 2015-05-08 19:51:37 +10:00
Jeremy Avigad
42f2fc973a refactor(library/data/{finset,list,fintype}: rename cross_product to product 2015-05-08 19:51:37 +10:00
Jeremy Avigad
68f7afa053 feat(library/data/finset/card.lean): begin theory of cardinality 2015-05-08 19:51:37 +10:00
Jeremy Avigad
9e04d09381 feat(library/data/finset/comb.lean): add filter, diff, theorems 2015-05-08 19:51:37 +10:00
Jeremy Avigad
4db4c86d37 feat(library/data/finset/basic.lean): add lots of theorems, do minor renaming 2015-05-08 19:51:37 +10:00
Jeremy Avigad
a54a98c1ec feat(library/data/set): add distributivity, diff, uniformize with finset 2015-05-08 19:51:37 +10:00
Jeremy Avigad
9e26dddaf3 feat(library/data/list/perm): add perm_filter 2015-05-08 19:51:37 +10:00
Jeremy Avigad
86a039b6d5 feat(library/data/list/set.lean): add two theorems 2015-05-08 19:51:37 +10:00
Jeremy Avigad
ba78cc42f9 fix(library/data/set/basic.lean, function.lean): fix typos 2015-05-08 19:51:37 +10:00
Leonardo de Moura
0b57f7d00a refactor(library/tactic): refine interface between tactic and proof-term modes
Some constraints were being lost with the previous interface.
This is why we had a workaround in fintype.lean.

We can also remove some hacks we have used in the past.
2015-05-07 18:02:51 -07:00
Floris van Doorn
9893de6194 feat(hit/circle): prove partly that the fundamental group of the circle is int
Also add markdown files for nat and int
2015-05-07 16:39:04 -07:00
Floris van Doorn
7cfac38eda feat(hott): port parts of natural numbers and integers from standard library to HoTT
This also involves:
- adding definitions about logic and natural numbers existing in the standard library to init
- porting the current algebraic hierarchy
2015-05-07 16:39:03 -07:00
Leonardo de Moura
e2c1dc92a8 chore(library/data/fintype): add workaround until problem in the elaborator is fixed 2015-05-07 16:32:26 -07:00
Leonardo de Moura
5798ac43de fix(frontends/lean/structure_cmd): 'structure' command must set unfold-c attribute for auxiliary recursors
fixes #582
2015-05-07 09:09:07 -07:00
Leonardo de Moura
84deddcca9 feat(library/tactic/rewrite_tactic): apply 'reflexivity' tactic after 'rewrite' instead of hard coded solution 2015-05-05 20:23:49 -07:00
Leonardo de Moura
7aa0e466a5 test(library): test new 'obtain' expression in the standard library 2015-05-05 18:30:16 -07:00
Leonardo de Moura
616f49c2e4 feat(frontends/lean): improved 'obtains' expression 2015-05-05 18:30:16 -07:00
Jeremy Avigad
f7a610faa3 feat(library/data/set/basic,function): mark set reducible, and add theorem from Haitao Zhang 2015-05-05 08:55:58 -07:00
Leonardo de Moura
11f74363e2 refactor(library): rename 'intersection' to 'inter' in list and finset, add finset abbreviation at top level 2015-05-05 08:53:31 -07:00
Leonardo de Moura
a46abbb9ce refactor(library/data): test new tactics in the standard library 2015-05-03 21:40:33 -07:00
Leonardo de Moura
3cd8f38b8d feat(library/data/string): prove that string and char have decidable equality 2015-05-03 21:08:09 -07:00
Leonardo de Moura
4e1146a2d5 refactor(hott,library): test new tactics in the HoTT and standard libraries 2015-05-02 22:22:31 -07:00
Leonardo de Moura
cd17618f4a refactor(library): replace 'calc_trans', 'calc_symm', 'calc_refl' and 'calc_subst' commands with attributes '[symm]', '[refl]', '[trans]' and '[subst]'
These attributes are used by the calc command.
They will also be used by tactics such as 'reflexivity', 'symmetry' and
'transitivity'.

See issue #500
2015-05-02 15:15:35 -07:00
Leonardo de Moura
e8affed020 refactor(library): test new tactics in the standard library 2015-05-01 18:18:29 -07:00
Leonardo de Moura
de369a0a0a feat(library/tactic/injection_tactic): improve 'injection' tactic
see issue #500
2015-05-01 15:49:56 -07:00
Leonardo de Moura
9ba8b284a1 fix(library/tactic/apply_tactic): add eapply, and fix issue #361 2015-05-01 15:08:00 -07:00
Leonardo de Moura
e948dd239c feat(library/data/list/perm): use new 'injection' tactic 2015-05-01 13:08:36 -07:00
Leonardo de Moura
59b11c815c refactor(library/data/list/perm): remove unnessary lambda abstractions
The contradiction tactic takes care of it.
2015-04-30 14:02:19 -07:00
Leonardo de Moura
9760968b45 refactor(library,hott): use/test new 'contradiction' tactic in the standard and hott libraries 2015-04-30 13:56:12 -07:00
Leonardo de Moura
3912bc24c8 feat(frontends/lean): nicer syntax for 'intros' 'reverts' and 'clears' 2015-04-30 11:00:39 -07:00
Leonardo de Moura
018f768555 chore(library): remove some unnecessary parentheses 2015-04-29 14:39:59 -07:00
Leonardo de Moura
17c07cdb02 feat(library/data/rat/order): define abs and sign for rat before migrate 2015-04-27 12:59:02 -07:00
Jeremy Avigad
7a1064b7e8 refactor(library/algebra/order.lean): rename a field in an order structure 2015-04-27 12:03:41 -07:00
Jeremy Avigad
d8e40d90d6 feat(library/data/rat/order.lean): make rat a linear ordered field 2015-04-27 12:03:41 -07:00
Leonardo de Moura
76c773ad3d feat(library/data/examples/depchoice): add dependent choice example 2015-04-26 12:56:23 -07:00
Leonardo de Moura
072bf0b3b4 refactor(library): make sure "choose" compute inside the kernel 2015-04-25 23:10:48 -07:00
Leonardo de Moura
d455bb4c5b feat(library/data/fintype): add decidable_exists_finite 2015-04-25 21:38:03 -07:00
Leonardo de Moura
6bb6644c25 feat(library/data/squash): define squash type using quotients 2015-04-24 18:11:25 -07:00
Floris van Doorn
9d805437f0 fix(reserved_notation): lower binding power of 'iff' 2015-04-22 13:06:11 -07:00
Leonardo de Moura
670eac9d50 refactor(library): avoid 'context' command in the standard library 2015-04-21 19:13:19 -07:00
Leonardo de Moura
bf8a7eb9b4 fix(library/scoped_ext): bug in local metadata in sections
The problem is described in issue #554
2015-04-21 18:56:28 -07:00
Leonardo de Moura
306087b5d3 refactor(library/data): rename 'countable' to 'encodable', define countable in the usual way, and prove all 'encodable' type is 'countable' 2015-04-19 14:20:47 -07:00
Jeremy Avigad
f4398115b4 feat(library/data/rat/basic.lean): begin theory of rationals, show rat is a field 2015-04-18 11:39:52 -07:00
Jeremy Avigad
5eb7fef564 feat(library/algebra/order.lean, data/int/{basic,order}.lean): add theorem, correct gt_trans 2015-04-18 11:39:52 -07:00
Leonardo de Moura
cc63a40a01 feat(library): enforce name conventions on old nat declarations 2015-04-18 10:50:30 -07:00
Leonardo de Moura
3b84a63874 fix(library/algebra/function): terminology 2015-04-16 20:52:18 -07:00
Leonardo de Moura
2e675c1bdd feat(library/data/examples/notcountable): add example showing that nat -> nat is not countable 2015-04-16 14:54:34 -07:00
Leonardo de Moura
7529ee0a5c feat(library/data/countable): prove axiom of choice and skolem theorem for countable types and decidable relations 2015-04-16 12:36:27 -07:00
Leonardo de Moura
0dd7667836 feat(library/data/countable): choice function for countable types 2015-04-16 12:29:06 -07:00
Leonardo de Moura
7a4f43d6ab feat(library/data/nat/choose): choice function for natural numbers 2015-04-16 11:33:26 -07:00
Leonardo de Moura
b14d3dbeba chore(library/data/countable): add copyright notice 2015-04-16 09:24:53 -07:00
Leonardo de Moura
036900280d feat(library/data/countable): show that a type is countable by providing an injection to a type already known to be countable 2015-04-15 10:30:24 -07:00
Leonardo de Moura
039f1de524 fix(library/data/countable): typos 2015-04-14 21:26:56 -07:00
Leonardo de Moura
9534cfe92f feat(library/data/countable): prove that (list A) is countable if A is countable 2015-04-14 21:17:18 -07:00
Leonardo de Moura
a7db8a2bac theorem(library/data/countable): prove that the product of two countable types is countable 2015-04-14 20:39:58 -07:00
Leonardo de Moura
38b880b939 feat(library/data/nat/pairing): add unpair_mkpair theorem 2015-04-14 20:28:20 -07:00
Leonardo de Moura
f7a43c7997 feat(library/data/nat/sqrt): generalize sqrt_eq theorem 2015-04-14 20:10:18 -07:00
Leonardo de Moura
faca0acd26 feat(library/data/nat/sqrt): add sqrt_eq theorem 2015-04-14 15:38:54 -07:00
Leonardo de Moura
11dbcda9d2 feat(library/data/nat/pairing): add "elegant" pairing/unpairing function 2015-04-14 09:01:15 -07:00
Leonardo de Moura
2eb7538c96 fix(library/data/nat/sqrt): adjust to reflect recent changes 2015-04-14 09:01:15 -07:00
Leonardo de Moura
4180b80df6 feat(library/data/nat/power): define power and add basic theorems 2015-04-14 09:01:15 -07:00
Leonardo de Moura
ff72a520ff feat(library/data/nat/div): add mul_cancel theorems 2015-04-14 09:01:15 -07:00
Leonardo de Moura
c73c1dbb63 feat(library/data/nat/sub): add two extra theorems 2015-04-14 09:01:15 -07:00
Leonardo de Moura
11c9bb4626 feat(library/data/nat): naive square root function 2015-04-14 09:01:15 -07:00
Leonardo de Moura
2453a6ab45 feat(library/data/countable): define countable type class 2015-04-14 09:01:15 -07:00
Leonardo de Moura
82eada7d56 feat(library/data/list/basic): add find nth theorem 2015-04-14 09:01:15 -07:00
Leonardo de Moura
07e195e9f1 feat(library/data/fintype): add decidable_finite_pred instance 2015-04-12 20:07:04 -07:00
Leonardo de Moura
00d68cadc8 refactor(library/data/fintype): cleanup and mark location that exposes bug in the 'cases' tactic 2015-04-12 17:52:41 -07:00
Leonardo de Moura
f523d3a995 feat(library/data): add structure for converting a list of elements into a type, and then show the resultant type is a finite type 2015-04-12 17:33:58 -07:00
Leonardo de Moura
d9f8b0f3d7 feat(library/data/finset/comb): add cross_product to finset 2015-04-11 19:46:04 -07:00
Leonardo de Moura
4c827293a8 feat(library/data/list/perm): add perm_cross_product theorem 2015-04-11 19:13:34 -07:00
Leonardo de Moura
41ddc97e0d feat(library/data/list): define filter function for lists 2015-04-11 18:22:22 -07:00
Leonardo de Moura
c437fbe0bc feat(library/data/fintype): prove that A->B has decidable equality when A is a finite type and B has decidable equality 2015-04-11 16:45:27 -07:00
Leonardo de Moura
3edf0dffdf feat(library/data/finset): define subset for finsets 2015-04-11 15:29:12 -07:00
Leonardo de Moura
dfef4c5daf feat(library/data): define fintype type class 2015-04-11 14:55:41 -07:00
Leonardo de Moura
06d4ae971d feat(library/data/list): add nodup_cross_product theorem 2015-04-11 14:31:01 -07:00
Leonardo de Moura
54a2d9750e refactor(library/data): simplify definition of disjoint 2015-04-11 14:04:09 -07:00
Leonardo de Moura
ee895e00dd feat(library/data/list): define cross_product for lists 2015-04-11 13:52:50 -07:00
Leonardo de Moura
fefddcd0f9 fix(library/data/list/perm): broken theorem 2015-04-11 09:42:24 -07:00
Leonardo de Moura
1b34f40f36 feat(library/data/list/set): add decidable_nodup 2015-04-11 09:39:26 -07:00
Leonardo de Moura
dff05557a3 feat(library/data/finset): add all combinator theorems 2015-04-11 09:28:27 -07:00
Leonardo de Moura
5304c5afb8 feat(library/data/list/set): add 'all' theorems 2015-04-11 09:28:05 -07:00
Leonardo de Moura
32b07c4561 feat(library/data/finset): define map for finset 2015-04-10 17:14:10 -07:00
Leonardo de Moura
a24c0bf1db feat(library/data/finset): define intersection for finsets 2015-04-10 16:45:25 -07:00
Leonardo de Moura
49d6d43926 feat(library/data/list): define intersection for lists 2015-04-10 16:31:44 -07:00
Leonardo de Moura
d59c671054 feat(library/data/list/comb): define upto list generator 2015-04-10 15:32:44 -07:00
Leonardo de Moura
9d8b5aa347 feat(library/data/list/comb): add any/all theorems 2015-04-10 07:01:14 -07:00
Leonardo de Moura
5caa983919 feat(library/data/finset): redefine bigop for finset 2015-04-10 06:13:32 -07:00
Leonardo de Moura
53f730ec82 feat(library/data/list/bigop): add bigop perm theorem 2015-04-10 06:01:23 -07:00
Leonardo de Moura
608e2838bf feat(library/data/list): define bigop for lists 2015-04-10 05:52:19 -07:00
Leonardo de Moura
4be8741a39 feat(library/data/list): break list/basic.lean into smaller files 2015-04-10 05:19:52 -07:00
Leonardo de Moura
a223b9b1f7 feat(library/data/finset): add bigop for finset + commutative groups 2015-04-09 20:00:00 -07:00
Leonardo de Moura
795acc70a6 refactor(library/data/finset): move finset to its own directory 2015-04-09 19:30:09 -07:00
Leonardo de Moura
ca377e5f8b feat(library/data/list/basic): add foldr/foldl theorems 2015-04-09 18:48:04 -07:00
Leonardo de Moura
b209f442f7 refactor(library/data/list) fix theorem name, and do not rely on implementation of mem 2015-04-09 16:27:48 -07:00
Leonardo de Moura
2ab2f7dc9d feat(library/data/finset): add basic support for finite sets 2015-04-09 15:51:23 -07:00
Leonardo de Moura
571ff76080 feat(library/data/list/perm): add perm_ext theorem 2015-04-09 15:27:32 -07:00
Leonardo de Moura
64173ddf93 feat(library/data/list/basic): more nodup theorems 2015-04-09 14:50:00 -07:00
Leonardo de Moura
b4611ba33d feat(library/data/list/basic): add mem erase theorems 2015-04-09 13:19:51 -07:00
Leonardo de Moura
d5176ebae5 refactor(library/algebra/binary): define right_commutative and left_commutative 2015-04-09 10:54:28 -07:00
Leonardo de Moura
8522fbec4b feat(library/data/list): more general theorems for perm foldl and foldr, and other minor improvements 2015-04-09 09:29:58 -07:00
Leonardo de Moura
07ff0900aa feat(library/data/list): add permutation theorems for union and insert 2015-04-08 19:02:35 -07:00
Leonardo de Moura
33422a387a feat(library/data/list/basic): define 'union' and 'insert' for lists 2015-04-08 18:12:51 -07:00
Leonardo de Moura
c95bd8ba61 feat(library/data/list): add erase_dup and theorems 2015-04-08 12:28:48 -07:00
Leonardo de Moura
05bd6b5fe7 feat(library/data/list): add foldr/foldl equality theorems for permutations 2015-04-08 10:36:05 -07:00
Jeremy Avigad
eb5089bf27 feat(library/data/set): add theory of functions and maps between sets 2015-04-08 09:46:34 -07:00
Jeremy Avigad
5812b35d93 feat(library/data/set/function.lean): begin theory of functions on sets 2015-04-08 09:46:34 -07:00
Leonardo de Moura
afc75f141c refactor(library/data/list/perm): prove auxiliary theorems using 'match-with' 2015-04-08 09:43:17 -07:00
Leonardo de Moura
56d20852aa refactor(library/data/list/perm): remove dead code 2015-04-08 09:32:28 -07:00
Leonardo de Moura
ef1b057b63 refactor(library/data/list/perm): cleanup theorem 2015-04-08 09:29:40 -07:00
Leonardo de Moura
e0e65705db feat(library/data/list/perm): add perm inversion theorems 2015-04-07 18:54:02 -07:00
Leonardo de Moura
c6a35e718d refactor(library/data/list/perm): use by_cases instead of dependent-if 2015-04-07 09:26:24 -07:00
Leonardo de Moura
9306830d8c feat(library/data/list): perm is decidable 2015-04-07 09:12:10 -07:00
Leonardo de Moura
754276a660 feat(frontends/lean): round parenthesis for [tactic1 | tactic2]
This commit also replaces the notation for divides
     `(` a `|` b `)`
with
      a `∣` b

The character `∣` is entered by typing \|

closes #516
2015-04-06 09:24:09 -07:00
Leonardo de Moura
3b959c9e6c refactor(library/data): move perm to list folder 2015-04-05 12:01:32 -07:00
Jeremy Avigad
c563548980 feat(library/data/set/basic.lean): add definitions and simplify proofs 2015-04-05 12:36:54 -04:00
Jeremy Avigad
c6c50a61b3 refactor(library/data/set/basic.lean): take advantage of extensionality in sets 2015-04-05 10:12:27 -04:00
Jeremy Avigad
6596217a84 refactor(library/data/set): expand set.lean to set directory 2015-04-05 09:27:15 -04:00
Leonardo de Moura
4ec0e1b07c feat(frontends/lean): improve calc mode
Now, it automatically supports transitivity of the form
    (R a b) -> (b = c) -> R a c
    (a = b) -> (R b c) -> R a c

closes #507
2015-04-04 08:58:35 -07:00
Leonardo de Moura
f1b7021ed0 feat(library/data/list/basic): add more theorems for disjoint predicate 2015-04-03 22:55:16 -07:00
Leonardo de Moura
23a1f5fa4b feat(library/data/list/basic): define nodup and disjoint 2015-04-03 15:44:07 -07:00
Leonardo de Moura
01f5dd9fa8 feat(library/data/list): add "erase" function lemmas 2015-04-03 13:18:48 -07:00
Leonardo de Moura
fc0ed5e46c feat(library/data/list/basic): define erase and prove basic theorems 2015-04-02 23:58:47 -07:00
Leonardo de Moura
9f3ba66295 feat(library/data/perm): add more theorems 2015-04-02 20:00:46 -07:00
Leonardo de Moura
e47c8c2d9e feat(library/data/list/basic): add quasiequality predicate l₁≈a|l₂, l₁ is equal to l₂ with 'a' inserted somewhere 2015-04-02 20:00:46 -07:00
Leonardo de Moura
5a394ac7ea feat(library/data/perm): add more theorems 2015-04-02 09:21:20 -07:00
Leonardo de Moura
92d6e93971 feat(library/data/perm): cleanup and add calculational proof support to perm 2015-04-02 08:50:05 -07:00
Leonardo de Moura
54136c1ec0 feat(library/data/perm): add list permutation module 2015-04-01 23:00:02 -07:00
Leonardo de Moura
dbe54c4fb5 feat(library/data): define unordered pairs using quotients 2015-04-01 17:30:49 -07:00
Leonardo de Moura
3951b50282 feat(library/data/prod): define swap 2015-04-01 17:30:37 -07:00
Leonardo de Moura
ed1acd9fb0 feat(library/init): move propext to init/quot, add Jeremy's funext theorem 2015-04-01 12:36:33 -07:00
Leonardo de Moura
ce5e83eb3e refactor(library/init): move subsingleton to init folder 2015-04-01 11:57:29 -07:00
Leonardo de Moura
a52cb009dc refactor(library): reorganize init folder and add setoid 2015-03-31 19:56:05 -07:00
Leonardo de Moura
e35de54cee feat(library/data/list/basic): add aux theorems 2015-03-31 18:38:05 -07:00
Leonardo de Moura
4c0ce9a619 feat(library/data/list/basic): missing theorems 2015-03-30 19:11:45 -07:00
Leonardo de Moura
299cbe4b25 feat(library/data/bool): add auxiliary theorems for bool 2015-03-30 04:55:28 -07:00
Leonardo de Moura
42fe87d7cc feat(library/data/list/basic): add sublist predicate 2015-03-30 03:20:42 -07:00
Leonardo de Moura
66bb22f268 feat(library/data/list/basic): cleanup 2015-03-30 02:14:33 -07:00
Leonardo de Moura
ec1a60b02c feat(library/init/logic): add helper function for proving decidable equality 2015-03-30 02:14:26 -07:00
Leonardo de Moura
5b9d52c0dd refactor(library/data/int/order): cleanup 2015-03-28 12:58:40 -07:00
Leonardo de Moura
75621df52b feat(frontends/lean): uniform notation for lists in tactics
closes #504
2015-03-27 17:54:48 -07:00
Jeremy Avigad
765f6f21f8 fix(library/algebra/ring.lean): allow degenerate semirings and rings, but not degenerate ordered_semirings and ordered_rings. Closes #478. 2015-03-25 18:29:06 -07:00
Leonardo de Moura
9b577a7b3e feat(frontends/lean): add 'migrate' command 2015-03-14 21:48:00 -07:00
Leonardo de Moura
ba913876e0 feat(library/data/list/basic): enforce name conventions, add foldl_eq_foldr theorem 2015-03-14 13:06:09 -07:00
Leonardo de Moura
bed0d6df6b fix(frontends/lean/elaborator): inaccessible over coercion 2015-03-13 23:04:45 -07:00
Leonardo de Moura
27e58dc534 refactor(library/data): cleanup vector and list modules 2015-03-13 22:25:21 -07:00
Jeremy Avigad
ec05e83a2a feat(library/data/int/div.lean): add theorems about div 2015-03-12 20:54:49 -07:00
Leonardo de Moura
167675a397 feat(library/data/vector): add nth and decidable_eq 2015-03-09 08:41:36 -07:00
Leonardo de Moura
a628836f28 feat(library/data/vector): add theorems 2015-03-08 22:51:11 -07:00
Leonardo de Moura
f6cd604a44 chore(library/data/bool): enforce naming conventions 2015-03-06 19:20:48 -08:00
Leonardo de Moura
4fdac068b0 chore(library/data/vector): cleanup vector proofs 2015-03-06 17:37:03 -08:00
Leonardo de Moura
78d8e79000 fix(library/data/num): naming convention 2015-03-05 23:48:08 -08:00
Leonardo de Moura
57ec52b6f1 refactor(library/data/fin): cleanup pattern matching equations 2015-03-05 14:42:42 -08:00
Leonardo de Moura
e4060a5614 feat(frontends/lean): do not force user to type the function name in the left-hand-side of recursive equations 2015-03-05 12:08:36 -08:00
Leonardo de Moura
53df3d86ee feat(library/data/list/basic): use 'show' instead of 'change' tactic 2015-03-04 20:40:06 -08:00
Leonardo de Moura
b8afba47ad feat(library/data/list/basic): add some map, foldl, foldl, zip and unzip 2015-03-04 20:30:19 -08:00
Leonardo de Moura
c78734874d feat(library/data/list/basic): list A has decidable equality if A has 2015-03-04 18:48:13 -08:00
Leonardo de Moura
cc2d988aea feat(library/data/num): prove many theorems for pos_num.lt and pos_num.le 2015-03-04 18:30:31 -08:00
Leonardo de Moura
f60fc5183a feat(library/data/bool): add auxiliary theorems 2015-03-04 18:30:31 -08:00
Leonardo de Moura
02d3f7c37c refactor(library/data/list): use 'change' tactic 2015-03-01 14:27:22 -08:00
Leonardo de Moura
df13588b93 chore(library/data): remove unnecessary parentheses 2015-03-01 14:18:36 -08:00
Leonardo de Moura
e8ef1f97b6 feat(library/data/set): use Prop instead of bool when defining set 2015-03-01 08:23:39 -08:00
Leonardo de Moura
68110faa4d feat(frontends/lean/inductive_cmd): allow '|' in inductive datatype declarations 2015-02-25 17:00:10 -08:00
Leonardo de Moura
5ca52d81ec feat(frontends/lean): ML-like notation for match and recursive equations 2015-02-25 16:20:44 -08:00
Leonardo de Moura
3c24461e51 refactor(*): modify '|' binding power, use 'abs a' instead of '|a|', and '(a | b)' instead of 'a | b' 2015-02-25 15:18:21 -08:00
Leonardo de Moura
c04c610b7b feat(frontends/lean): add 'assert H : A, ...' as notation for 'have H [visible] : A, ...' 2015-02-25 14:30:42 -08:00
Jeremy Avigad
e513b0ead4 refactor(library,hott): rename theorems for decidable and inhabited
The convention is this: we use e.g. nat.is_inhabited and nat.has_decidable_eq
for these two purposes only, to avoid clashing with "inhabited" and "decidable_eq"
in a namespace. Otherwise, we use "decidable_foo" and "inhabited_foo".
2015-02-25 14:05:07 -08:00
Jeremy Avigad
e555531eb6 feat(library/data/int/div): start on div for integers 2015-02-25 14:05:07 -08:00
Jeremy Avigad
7a57908d62 feat/refactor(library/data/int): revise and add theorems 2015-02-25 14:05:07 -08:00
Jeremy Avigad
cfdaffb6f5 feat/refactor(library/data/nat): do some housecleaning, add facts to div 2015-02-25 14:05:07 -08:00
Jeremy Avigad
a607e7dd57 feat(library/algebra/group): add rules for sub equalities 2015-02-25 14:05:06 -08:00
Leonardo de Moura
909ebfc5f1 feat(frontends/lean/elaborator): try coercions after each overload
We try only the easy cases since the more general case is too expensive.

closes #444
2015-02-24 17:41:20 -08:00
Leonardo de Moura
3ede8e9150 refactor(library): use [] binder annotation when declaring instances 2015-02-24 16:12:39 -08:00
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
74b8499fa9 refactor(library/data/nat/div): simplify proof of dvd_of_dvd_add_left 2015-02-17 18:55:44 -08:00
Leonardo de Moura
a35cce38b3 feat(frontends/lean): new semantics for "protected" declarations
closes #426
2015-02-11 14:09:25 -08:00
Leonardo de Moura
2ffdbba8b0 feat(library): replace same 'calc' proofs with 'rewrite' 2015-02-05 10:39:25 -08:00
Jeremy Avigad
77e8439012 feat(library/data/nat/div): add theorems for coprime, etc. 2015-02-03 13:50:59 -08:00
Jeremy Avigad
90da0290f4 fix(library/init/{prod,sigma},library/data/sum): move notation in/out of namespaces 2015-02-01 11:17:45 -08:00