Skip to content

Commit 5eaea33

Browse files
committed
chore(LinearAlgebra.TensorAlgebra): more idiomatic transparency management in induction (#31953)
Normally to contain reduction at weaker transparency we build the appropriate API via theorems. Here we have a `let` definition. We could factor it out and proceed as usual but that does not seem worth the effort currently. So we mimic this with a `have` instead. Co-authored-by: Matthew Ballard <[email protected]>
1 parent 4e5860e commit 5eaea33

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Mathlib/LinearAlgebra/TensorAlgebra/Basic.lean

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -191,13 +191,11 @@ theorem induction {C : TensorAlgebra R M → Prop}
191191
add_mem' := @add
192192
algebraMap_mem' := algebraMap }
193193
let of : M →ₗ[R] s := (TensorAlgebra.ι R).codRestrict (Subalgebra.toSubmodule s) ι
194+
have of_apply {x : M} : of x = (TensorAlgebra.ι R) x := by rfl
194195
-- the mapping through the subalgebra is the identity
195196
have of_id : AlgHom.id R (TensorAlgebra R M) = s.val.comp (lift R of) := by
196197
ext
197-
simp only [AlgHom.toLinearMap_id, LinearMap.id_comp, AlgHom.comp_toLinearMap,
198-
LinearMap.coe_comp, Function.comp_apply, AlgHom.toLinearMap_apply, lift_ι_apply,
199-
Subalgebra.coe_val]
200-
erw [LinearMap.codRestrict_apply]
198+
simp [of_apply]
201199
-- finding a proof is finding an element of the subalgebra
202200
rw [← AlgHom.id_apply (R := R) a, of_id]
203201
exact Subtype.prop (lift R of a)

0 commit comments

Comments
 (0)