Lean4
/-- Evaluation of functions into an indexed collection of semigroups at a point is a semigroup
homomorphism.
This is `Function.eval i` as a `MulHom`. -/
@[to_additive (attr := simps) /--
Evaluation of functions into an indexed collection of additive semigroups at a point is an
additive semigroup homomorphism. This is `Function.eval i` as an `AddHom`. -/
]
def evalMulHom (i : I) : (∀ i, f i) →ₙ* f i where
toFun g := g i
map_mul' _ _ := Pi.mul_apply _ _ i