Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(linear_algebra/lc): use families not sets #943

Merged
merged 44 commits into from
Jul 3, 2019

Conversation

abentkamp
Copy link
Collaborator

@abentkamp abentkamp commented Apr 16, 2019

I modified the formalization of linear combinations to be based on families instead of sets.
This allows in particular to speak about a family of vectors being linearly dependent if one vector occurs twice.

The old definition is a special case of this new one by using the type of vectors as the index type and the identity as the map of the family.

See also: https://leanprover.zulipchat.com/login/#narrow/stream/116395-maths/topic/linear_independent.20for.20families

TO CONTRIBUTORS:

Make sure you have:

  • [✓] reviewed and applied the coding style: coding, naming
  • [✓] for tactics:
    • [✓] added or adapted documentation in tactics.md
    • [✓] write an example of use of the new feature in tactics.lean
  • [✓] make sure definitions and lemmas are put in the right files
  • [✓] make sure definitions and lemmas are not redundant

If this PR is related to a discussion on Zulip, please include a link in the discussion.

For reviewers: code review check list

@abentkamp abentkamp requested a review from a team as a code owner April 16, 2019 22:21
src/linear_algebra/linear_combination.lean Outdated Show resolved Hide resolved
src/linear_algebra/basis.lean Outdated Show resolved Hide resolved
@abentkamp abentkamp added the WIP Work in progress label Apr 18, 2019
src/data/finsupp.lean Outdated Show resolved Hide resolved
finsupp.vector_space
/-- Interprets (l : α →₀ γ) as linear combination of the elements in the family (v : α → β) and
evaluates this linear combination. -/
protected def total : α →₀ γ →ₗ β := finsupp.lsum (λ i, linear_map.id.smul_right (v i))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

alpha and beta can be implicit here

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the expression finsupp.total α β γ v l, it is very convenient to have the coersion of the linear map finsupp.total α β γ v into a function. I don't understand why, but if I make alpha and beta implicit, the coersion does no longer work. Any ideas?

@abentkamp abentkamp removed the WIP Work in progress label Apr 20, 2019
@cipher1024 cipher1024 assigned cipher1024 and digama0 and unassigned cipher1024 Apr 22, 2019
@abentkamp abentkamp added the WIP Work in progress label Apr 23, 2019
@abentkamp abentkamp force-pushed the linear_independent branch 2 times, most recently from 435425a to 4525504 Compare June 6, 2019 08:10
@abentkamp abentkamp force-pushed the linear_independent branch 4 times, most recently from ee4df40 to c765545 Compare June 19, 2019 15:20
@abentkamp abentkamp removed the WIP Work in progress label Jun 19, 2019
src/data/set/finite.lean Outdated Show resolved Hide resolved
@abentkamp abentkamp force-pushed the linear_independent branch 2 times, most recently from f7e57d1 to 7314d88 Compare June 20, 2019 21:17
@ChrisHughes24 ChrisHughes24 added the ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) label Jul 3, 2019
@mergify mergify bot merged commit d2c5309 into master Jul 3, 2019
@mergify mergify bot deleted the linear_independent branch July 3, 2019 09:42
anrddh pushed a commit to anrddh/mathlib that referenced this pull request May 15, 2020
…ity#943)

* refactor(linear_algebra/lc): use families not sets

* refactor(linear_algebra/lc): merge lc into finsupp

* refactor(linear_algebra/lc): localize decidability

* refactor(linear_algebra/lc): finsupp instances

* refactor(linear_algebra/lc): use families instead of sets

* refactor(linear_algebra/lc): remove set argument in lin_indep

* refactor(linear_algebra/lc): clean up

* refactor(linear_algebra/lc): more clean up

* refactor(linear_algebra/lc): set_option in section

* refactor(linear_algebra/lc): decidability proof

* refactor(linear_algebra/lc): arrow precedence

* refactor(linear_algebra/lc): more cleanup

* refactor(linear_algebra/lc): move finset.preimage

* refactor(linear_algebra/lc): use families not sets

* refactor(linear_algebra/lc): merge lc into finsupp

* refactor(linear_algebra/lc): localize decidability

* refactor(linear_algebra/lc): finsupp instances

* refactor(linear_algebra/lc): use families instead of sets

* refactor(linear_algebra/lc): remove set argument in lin_indep

* refactor(linear_algebra/lc): clean up

* refactor(linear_algebra/lc): more clean up

* refactor(linear_algebra/lc): set_option in section

* refactor(linear_algebra/lc): decidability proof

* refactor(linear_algebra/lc): arrow precedence

* refactor(linear_algebra/lc): more cleanup

* refactor(linear_algebra/lc): move finset.preimage

* tidying up. Remove unnecessary dec_eq from dim. Shorten finset.preimage.

* fix build

* make travis rebuild

*  fix build

* shorten finsupp proofs

* shorten more proofs

* shorten more proofs

* speed up dim_bot

* fix build

* shorten dimension proof
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants