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.