slm {nnR}R Documentation

slm

Description

The function that returns the left scalar multiplication neural network

Usage

slm(a, nu)

a %slm% nu

Arguments

a

A real number.

nu

A neural network of the type generated by create_nn().

Value

Returns a neural network that is a \triangleright \nu. This instantiates as a \cdot f(x) under continuous function activation. More specifically we define operation as:

Let \lambda \in \mathbb{R}. We will denote by (\cdot) \triangleright (\cdot): \mathbb{R} \times \mathsf{NN} \rightarrow \mathsf{NN} the function satisfying for all \nu \in \mathsf{NN} and \lambda \in \mathbb{R} that \lambda \triangleright \nu = \mathsf{Aff}_{\lambda \mathbb{I}_{\mathsf{I}(\nu)},0} \bullet \nu.

References

Definition 2.3.4. Jentzen, A., Kuckuck, B., and von Wurstemberger, P. (2023). Mathematical introduction to deep learning: Methods, implementations, and theory. https://arxiv.org/abs/2310.20360.

Note: We will have two versions of this operation, a prefix and an infix version.

Examples


5 |> slm(Prd(2.1, 0.1))
Prd(2.1, 0.1) |> srm(5)


[Package nnR version 0.1.0 Index]