Question: is tan x a function?
Answer: Why is tan(x) a function? A function f:X→Y maps each x∈X to some y∈Y. So consider tanπ2 for which tan(x) is undefined, so in this case, tan(x) does not map to an element of its range.