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

[Merged by Bors] - feat(linear_algebra/affine_space): affine independence #3140

Closed
wants to merge 23 commits into from

Conversation

jsm28
Copy link
Collaborator

@jsm28 jsm28 commented Jun 22, 2020

Define affine independent indexed families of points (in terms of no
nontrivial weighted_vsub in the family being zero), prove that a
family of at most one point is affine independent, and prove a family
of points is affine independent if and only if a corresponding family
of subtractions is linearly independent.

There are of course other equivalent descriptions of affine
independent families it will be useful to add later (that the affine
span of all proper subfamilies is smaller than the affine span of the
whole family, that each point is not in the affine span of the rest;
in the case of a family indexed by a fintype, that the dimension of
the affine span is one less than the cardinality). But I think the
definition and one equivalent formulation is a reasonable starting
point.


Define affine independent indexed families of points (in terms of no
nontrivial `weighted_vsub` in the family being zero), prove that a
family of at most one point is affine independent, and prove a family
of points is affine independent if and only if a corresponding family
of subtractions is linearly independent.

There are of course other equivalent descriptions of affine
independent families it will be useful to add later (that the affine
span of all proper subfamilies is smaller than the affine span of the
whole family, that each point is not in the affine span of the rest;
in the case of a family indexed by a `fintype`, that the dimension of
the affine span is one less than the cardinality).  But I think the
definition and one equivalent formulation is a reasonable starting
point.
@jsm28 jsm28 added the awaiting-review The author would like community review of the PR label Jun 22, 2020
@PatrickMassot
Copy link
Member

That proof seems too big. Are you sure you can't factor out a couple of useful lemmas?

@jsm28
Copy link
Collaborator Author

jsm28 commented Jun 22, 2020

The lemmas I could find that seemed possibly relevant to more than just this proof were merged in #3124. The two directions of the lemma could of course be split into separate lemmas linear_independent_vsub_of_affine_independent and affine_independent_of_linear_independent_vsub, but while that might make it quicker for Lean to process, it wouldn't make the proof any simpler.

@PatrickMassot
Copy link
Member

I'm sorry but I'm not convinced. I can't really believe you couldn't develop the theory of equiv.vadd_const and equiv.const_vadd to help here.

src/data/finset.lean Outdated Show resolved Hide resolved
@PatrickMassot PatrickMassot added awaiting-author A reviewer has asked the author a question or requested changes and removed awaiting-review The author would like community review of the PR labels Jun 25, 2020
@semorrison semorrison added awaiting-review The author would like community review of the PR and removed awaiting-author A reviewer has asked the author a question or requested changes labels Jun 26, 2020
@semorrison
Copy link
Collaborator

@PatrickMassot --- maybe you can indicate what you'd like to see when you said "I can't really believe you couldn't develop the theory of equiv.vadd_const and equiv.const_vadd to help here."?

@jsm28
Copy link
Collaborator Author

jsm28 commented Jun 26, 2020

I certainly couldn't see the relevance of equiv.vadd_const and equiv.const_vadd. The proof is all manipulations of sums and subtypes; I've split out eight lemmas about such manipulations (not counting to_additive variants separately), but that doesn't make the proof that much shorter as it's still necessary to set up hypotheses in the right form for using those lemmas.

@jcommelin
Copy link
Member

You still went down from ~70 lines to ~50 lines. And all the new results will hopefully be useful in later developments, hence pay off in the long run.
(I haven't really reviewd the PR yet.)

@PatrickMassot
Copy link
Member

I certainly couldn't see the relevance of equiv.vadd_const and equiv.const_vadd.

The statement is definitionaly equal to

affine_independent k V p ↔ linear_independent k (λ i : {x // x ≠ i1}, (vadd_const V (p i1)).symm $ p i)

How could it fail to be relevant? My question is: could you write lemmas about vadd_const that could prove this lemma. It seems to me that vadd_const is a central object in the theory, and I find it surprising that it's not use more. However I'm already very happy with your recent work. Anything that remove lines from a specialized proof to add them to big_operator is worth the trouble in my opinion.

@PatrickMassot
Copy link
Member

bors merge

@github-actions github-actions bot added ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) and removed awaiting-review The author would like community review of the PR labels Jun 29, 2020
bors bot pushed a commit that referenced this pull request Jun 29, 2020
Define affine independent indexed families of points (in terms of no
nontrivial `weighted_vsub` in the family being zero), prove that a
family of at most one point is affine independent, and prove a family
of points is affine independent if and only if a corresponding family
of subtractions is linearly independent.

There are of course other equivalent descriptions of affine
independent families it will be useful to add later (that the affine
span of all proper subfamilies is smaller than the affine span of the
whole family, that each point is not in the affine span of the rest;
in the case of a family indexed by a `fintype`, that the dimension of
the affine span is one less than the cardinality).  But I think the
definition and one equivalent formulation is a reasonable starting
point.




Co-authored-by: Patrick Massot <patrickmassot@free.fr>
@bors
Copy link

bors bot commented Jun 29, 2020

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(linear_algebra/affine_space): affine independence [Merged by Bors] - feat(linear_algebra/affine_space): affine independence Jun 29, 2020
@bors bors bot closed this Jun 29, 2020
@bors bors bot deleted the affine-independent branch June 29, 2020 15:01
cipher1024 pushed a commit to cipher1024/mathlib that referenced this pull request Mar 15, 2022
…mmunity#3140)

Define affine independent indexed families of points (in terms of no
nontrivial `weighted_vsub` in the family being zero), prove that a
family of at most one point is affine independent, and prove a family
of points is affine independent if and only if a corresponding family
of subtractions is linearly independent.

There are of course other equivalent descriptions of affine
independent families it will be useful to add later (that the affine
span of all proper subfamilies is smaller than the affine span of the
whole family, that each point is not in the affine span of the rest;
in the case of a family indexed by a `fintype`, that the dimension of
the affine span is one less than the cardinality).  But I think the
definition and one equivalent formulation is a reasonable starting
point.




Co-authored-by: Patrick Massot <patrickmassot@free.fr>
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

6 participants