English
The tensor product respects addition in the M-factor on the left: (m1 + m2) ⊗ n = m1 ⊗ n + m2 ⊗ n.
Русский
Тензорное произведение respects addition in M-части слева: (m1 + m2) ⊗ n = m1 ⊗ n + m2 ⊗ n.
LaTeX
$$$ (m_1 + m_2) \\otimes_R n = m_1 \\otimes_R n + m_2 \\otimes_R n. $$$
Lean4
/-- Produces an arbitrary representation of the form `mₒ ⊗ₜ n₀ + ...`. -/
unsafe instance [Repr M] [Repr N] : Repr (M ⊗[R] N) where
reprPrec mn
p :=
let parts := mn.unquot.toList.map fun (mi, ni) => Std.Format.group f!"{(reprPrec mi 100)} ⊗ₜ {reprPrec ni 101}"
match parts with
| [] => f!"0"
| [part] => if p > 100 then Std.Format.bracketFill "(" part ")" else .fill part
| parts =>
(if p > 65 then (Std.Format.bracketFill "(" · ")") else (.fill ·)) <| .joinSep parts f! " +{Std.Format.line}"