If I define a function with a domain such that its range is bigger than its codomain, is it necessarily ill-defined?
For example, consider $f: \mathbb{R} \rightarrow \mathbb{Z}\\ f(x) = x.$
Clearly, some values of $f(x)$ are not in the codomain; can I ignore/forbid these values by restricting the codomain to the integers, that is, can I allow the function to return outputs only when they are integers? Or would this function not be well-defined or, indeed, a function at all?