# what does the notation $g\colon X\to Y$ mean?

What does the notation $g\colon X \to Y$ mean in this Wikipedia page, under the section "Problem statement (supervised version)"?

• I generally use $\rightarrowtail$ instead of $\to$ but that is no big deal. Something like $$f:X\rightarrowtail Y:x\mapsto y$$ would mean $f(x)=y$ such that $x\in X$ and $y\in Y$. – Mr Pie Jun 20 '18 at 12:01

It means that $g$ is a function which takes elements from $X$ as inputs and returns elements in $Y$ as outputs.
• As far as I've seen this is always the meaning of $g: X\rightarrow Y$, but I can't say for certain that it's never used differently. – Alex Becker May 1 '11 at 6:55
• Well, sometimes this notation is used to describe a morphism in a category. And morphisms needs not to be functions (e.g. in the category $\mbox{Set}^{op}$ a morphism $g: X \to Y$ is a function $Y \to X$). Anyway this is not the case here. – Giacomo d'Antonio May 1 '11 at 8:20
The $g$ function there is the mapping between instances to output labels. In other words, it is the correct association of events and their respective patterns. Presumably, the goal of supervised pattern recognition is to assign patterns to events in a way that best mirrors the truth (i.e. the $g$ function).