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/matrix): trace of an endomorphism independent of basis #3125

Closed
wants to merge 7 commits into from

Conversation

kckennylau
Copy link
Collaborator


@bryangingechen bryangingechen added the awaiting-review The author would like community review of the PR label Jun 21, 2020
@ocfnash
Copy link
Collaborator

ocfnash commented Jun 21, 2020

I'm delighted to see someone finally defining traces; nice work!

Ages ago I had plans to do this and was planning to define the trace by showing that dual_tensor_hom was a bijection when we needed it to be (e.g., when there exists bases) and then composing its inverse with contract_left. If it was easy, it might be nice if we had some lemmas connecting the definition here with this approach.

... = trace_aux R hc : by { rw trace_aux_range R hc, congr }

/-- Trace of an endomorphism independent of basis. -/
def trace' (R : Type u) [comm_ring R] (M : Type v) [add_comm_group M] [module R M] :
Copy link
Member

Choose a reason for hiding this comment

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

Shouldn't this be in a different namespace? linear_map.trace?

@jcommelin
Copy link
Member

@kckennylau What do you think of @ocfnash 's suggestion? That way the definition is intrinsically independent of a basis. And given a basis, you turn the linear map into a matrix, and relate the linear_map.trace to matrix.trace.

@kckennylau
Copy link
Collaborator Author

@jcommelin could we relate those in another PR?

@jcommelin
Copy link
Member

@kckennylau We could do that, but I guess it means that the next PR would refactor the definition and lemmas about linear_map.trace. Something like trace_apply is not the statement that would be natural with the other definition.

@kckennylau
Copy link
Collaborator Author

the next PR can just be (linear_map.trace R M).comp (dual_tensor_hom R M M) = contract_left R M

@jcommelin
Copy link
Member

jcommelin commented Jun 22, 2020

@kckennylau You don't like "Linear algebra done right"?
Anyway, I don't really care about what the definition is, if all the lemmas are there.

kckennylau and others added 2 commits June 22, 2020 16:14
Co-authored-by: Johan Commelin <johan@commelin.net>
@jcommelin
Copy link
Member

Thanks 🎉

bors merge

looking forward to the next PR

@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 22, 2020
bors bot pushed a commit that referenced this pull request Jun 22, 2020
@bors
Copy link

bors bot commented Jun 22, 2020

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(linear_algebra/matrix): trace of an endomorphism independent of basis [Merged by Bors] - feat(linear_algebra/matrix): trace of an endomorphism independent of basis Jun 22, 2020
@bors bors bot closed this Jun 22, 2020
@bors bors bot deleted the trace branch June 22, 2020 11:50
cipher1024 pushed a commit to cipher1024/mathlib that referenced this pull request Mar 15, 2022
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

4 participants