I'm trying to represent a pipeline of functions, each of which accepts an object and returns a potentially different object, in mathematical notation.
Assume we have sets $X$ and $Y$.
Each function in the pipeline can be defined as follows, I believe:
$f : X \times Y \rightarrow X \times Y$
An ordered set of these (a single pipeline) could be defined, for example, as a tuple (where the pipeline has two items)
$f \times f$
or a triple where it has three
$f \times f \times f$
I'd like to represent the set of all possible such ordered pairs, of any length.
Calling this set $P$ I'd then want:
$P \times X \rightarrow X$
which is the result of sending $X$ through the pipeline.
Is this the correct approach?