## Definition ## Given a [[commutative ring]] $R$ and any type $T$, the type of functions $T \to R$ has the structure of an $R$-algebra, with canonical ring homomorphism $c:R \to (T \to R)$ being the constant functions in $T \to R$. One could define the $R$-algebra operations pointwise on $R$: $$r:R \vdash 0(r) \coloneqq 0$$ $$r:R \vdash (f + g)(r) \coloneqq f(r) + g(r)$$ $$r:R \vdash (-f)(r) \coloneqq -f(r)$$ $$r:R \vdash 1(r) \coloneqq 1$$ $$r:R, s:R \vdash (s f)(r) \coloneqq c(s) \cdot f(r)$$ $$r:R \vdash (f \cdot g)(r) \coloneqq f(r) \cdot g(r)$$ There is also the identity function on $R$. ## See also ## * [[ring]] * [[commutative ring]]