TITLE: Is there a mathematical notation to express the domain without the range or the range without the domain?
QUESTION [2 upvotes]: According to the domain's Wikipedia page
I can express the domain and range of a function like this $$f:X\rightarrow Y$$
What if I am only interested in the domain of the function? Is it mathematically accepted to write this?
$$f:X$$
What if I am only interested in the range?
I am asking if there is a mathematical notation to represent these concepts individually without presenting both at the same time.

REPLY [9 votes]: One often sees 
$\operatorname{dom }f$ and $\operatorname{ran} f$ or $D(f)$ and $R(f)$ or $D_{f}$ and $R_{f}$ .
Of course, you can also say something like

When $f$ is a function, we will write “$\square f$” to mean the domain of $f$ and “$f\square$” to mean the codomain

or whatever. You're allowed to make up whatever notation you like, as long as you explain it clearly.
{"set_name": "stack_exchange", "score": 2, "question_id": 2906842}