Skip to content

[Merged by Bors] - feat(RepresentationTheory/Coinduced): add CoeFun instance - #43948

Closed
JX-Mo wants to merge 8 commits into
leanprover-community:masterfrom
JX-Mo:coind_apply_apply
Closed

JX-Mo wants to merge 8 commits into
leanprover-community:masterfrom
JX-Mo:coind_apply_apply

Conversation

@JX-Mo

@JX-Mo JX-Mo commented Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

This allows us to drop numerous set_option backward.isDefEq.respectTransparency.types false.


Remove five backward.isDefEq.respectTransparency.types and add a CoeFun instance for coindV to justify the existing coe-named lemmas.

https://leanprover.zulipchat.com/#narrow/channel/287929-mathlib4/topic/.60CoeFun.60.20or.20.60.2Eval.60/with/630026437

@github-actions github-actions Bot added the tech debt Fixes cross-cutting technical debt, see the "technical debt counters" stream on zulip label Sep 18, 2026
@github-actions

github-actions Bot commented Sep 18, 2026 •

Copy link
Copy Markdown

PR summary 312f2f6515

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference

Declarations diff (regex)

+ coe_coindMap_apply
+ coe_coindMap_apply_apply
+ coe_coind_apply
+ instance : CoeFun (coindV φ σ) (fun _ => H → A) := ⟨Subtype.val⟩

You can run this locally as follows
## from your `mathlib4` directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci

## summary with just the declaration names:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh <optional_commit>

## more verbose report:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh long <optional_commit>

The doc-module for scripts/pr_summary/declarations_diff.sh in the mathlib-ci repository contains some details about this script.

Declarations diff (Lean)

✅ Lean-aware diff — post-build, computed from the Lean environment (commit 312f2f6).

  • +4 new declarations
  • −0 removed declarations
+Representation.coe_coindMap_apply
+Representation.coe_coindMap_apply_apply
+Representation.coe_coind_apply
+Representation.instCoeFunSubtypeForallMemSubmoduleCoindV

Decrease in strong tech debt: (relative, absolute) = (5.00, 0.00)
Current number Change Type (strong)
1887 -5 backward.isDefEq.respectTransparency.types
No changes to weak technical debt.

Current commit 312f2f6515
Reference commit 2446d631e9

This script lives in the mathlib-ci repository. To run it locally, from your mathlib4 directory:

git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
../mathlib-ci/scripts/reporting/technical-debt-metrics.py pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

@JX-Mo

JX-Mo commented Sep 18, 2026

Copy link
Copy Markdown
Contributor Author

!radar

@github-actions github-actions Bot added the t-algebra Algebra (groups, rings, fields, etc) label Sep 18, 2026
@leanprover-radar

leanprover-radar commented Sep 18, 2026 •

Copy link
Copy Markdown

Benchmark results for ff76090 against f0ab343 are in. No significant results found. @JX-Mo

  • 🟥 build//instructions: +18.4G (+0.01%)

Small changes (2✅)

  • ✅ build/module/Mathlib.Tactic.Convert//instructions: -95.5M (-1.01%)
  • ✅ build/module/Mathlib.Tactic.GRewrite//instructions: -27.1M (-1.36%)

@JX-Mo

JX-Mo commented Sep 18, 2026

Copy link
Copy Markdown
Contributor Author

easy

@github-actions github-actions Bot added the easy < 20s of review time. See the lifecycle page for guidelines. label Sep 18, 2026
@JX-Mo JX-Mo changed the title chore(RepresentationTheory): coinduced tech debt chore(RepresentationTheory/Coinduced): tech debt Sep 18, 2026
@jjdishere

Copy link
Copy Markdown
Collaborator

Thanks for doing this!

maintainer delegate

@github-actions

Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by jjdishere.

@mathlib-triage mathlib-triage Bot added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Sep 19, 2026
@jjdishere

Copy link
Copy Markdown
Collaborator

Thanks again!

maintainer merge

@github-actions

Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by jjdishere.

@jjdishere

Copy link
Copy Markdown
Collaborator

I would like to also hear the opinion from @Whysoserioushah, since he is an expert of representation theory part of Mathlib.

@jcommelin

Copy link
Copy Markdown
Member

bors d=whysoserioushah

@mathlib-bors mathlib-bors Bot added the delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). label Sep 21, 2026
@mathlib-bors

mathlib-bors Bot commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

✌️ Whysoserioushah can now approve this pull request until 2026-10-05 09:50 UTC (in 2 weeks). To approve and merge, reply with bors r+. More detailed instructions are available here.

⚠️ This delegation only covers changes within Archive/**, Counterexamples/**, docs/**, DownstreamTest/**, Mathlib/**, MathlibTest/**, Wanted/**, widget/**, Archive.lean, Counterexamples.lean, docs.lean, Mathlib.lean, Wanted.lean; an author commit touching anything else will revoke it. Bors also revokes it if a later push changes too many files for it to check the full list — even if it stays within scope.

@mathlib-triage mathlib-triage Bot removed the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Sep 21, 2026
@mathlib-bors

mathlib-bors Bot commented Sep 28, 2026

Copy link
Copy Markdown
Contributor

⏳ @Whysoserioushah, your delegation on this PR expires in less than a week (approximately 6 days, 23 hours, at 2026-10-05 09:50 UTC).

@mathlib-bors

mathlib-bors Bot commented Oct 4, 2026

Copy link
Copy Markdown
Contributor

⏳ @Whysoserioushah, your delegation on this PR expires in less than 24 hours (approximately 23 hours, 55 minutes, at 2026-10-05 09:50 UTC).

@mathlib-bors

mathlib-bors Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

⌛ Delegation for @Whysoserioushah on this PR has expired (at 2026-10-05 09:50 UTC). Reply with bors d+ or bors d=Whysoserioushah with a for= argument to re-delegate.

@mathlib-bors mathlib-bors Bot removed the delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). label Oct 5, 2026
@JX-Mo

JX-Mo commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor Author

In addition to the above discussion regarding @Whysoserioushah 's CoeFun instance question, Kevin's repository class field theory IndCoind/Finite.lean line 79-83 has a similar FunLike instance

Can you explain why do we need this Coe instance? Note that there is no general coe instance for elements in submodules to the ambient module, also the later set_option is not a result of this, i.e removing this instance and adding .1 at suitable place would just work

abbrev coind₁V := coindV (⊥ : Subgroup G).subtype (trivial R _ V)

instance : FunLike (coind₁V R G V) G V where
  coe f := f.val
  coe_injective := Subtype.val_injective

I am happy to learn about the general policy here @jcommelin @jjdishere. Using FunLike here breaks some proofs because we have to manage f x v.s. f.val x, e.g. LinearMap.coe_restrict_apply needs (foo.restrict _ _).val.

@mathlib-merge-conflicts mathlib-merge-conflicts Bot added the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Nov 19, 2026
@mathlib-merge-conflicts

Copy link
Copy Markdown

This pull request has conflicts, please merge master and resolve them.

@github-actions github-actions Bot removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Nov 19, 2026
@ocfnash ocfnash changed the title chore(RepresentationTheory/Coinduced): tech debt feat(RepresentationTheory/Coinduced): add CoeFun instance Nov 30, 2026
@ocfnash

ocfnash commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

bors merge

@mathlib-bors mathlib-bors Bot added the ready-to-merge This PR has been sent to bors. label Nov 30, 2026
mathlib-bors Bot pushed a commit that referenced this pull request Nov 30, 2026
This allows us to drop numerous `set_option backward.isDefEq.respectTransparency.types false`.

Co-authored-by: Oliver Nash <[email protected]>
@mathlib-bors mathlib-bors Bot added the bors-staging This PR is currently being built by bors on the staging branch. label Nov 30, 2026
@mathlib-bors

mathlib-bors Bot commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

@mathlib-bors mathlib-bors Bot changed the title feat(RepresentationTheory/Coinduced): add CoeFun instance [Merged by Bors] - feat(RepresentationTheory/Coinduced): add CoeFun instance Nov 30, 2026
@mathlib-bors mathlib-bors Bot closed this Nov 30, 2026
TJHeeringa pushed a commit to TJHeeringa/mathlib4 that referenced this pull request Dec 2, 2026
…er-community#43948)

This allows us to drop numerous `set_option backward.isDefEq.respectTransparency.types false`.

Co-authored-by: Oliver Nash <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bors-staging This PR is currently being built by bors on the staging branch. easy < 20s of review time. See the lifecycle page for guidelines. ready-to-merge This PR has been sent to bors. t-algebra Algebra (groups, rings, fields, etc) tech debt Fixes cross-cutting technical debt, see the "technical debt counters" stream on zulip

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants