# Construct a function that is surjective, but not injective

The given domain and codomain are: $$\mathbb{R} \rightarrow \{x \in \mathbb{R} | x \ge - 3\}$$

I'm suppossed to create a function that is surjective but not injective.

Now, does the codomain imply that in order for the function to be surjectice all real y values have to be covered by that function for all $x \ge - 3$ or is the more (or less?) to it? If that's the case, I supposse that the function has to approach a certain value in one way or another while also not being hyperbolic (i.e. $x^2$ wouldn't be surjectice, but $x^3$ would be injective), but I'm not really sure how to approach the problem mathematically. Could someone please give me a tip?

Thanks!

• Not functional analysis....or set theory (please read the tags first) – MathematicsStudent1122 Nov 8 '16 at 21:38
• Sorry, thought that the amount of analysis required to solve this problem would be enough to justify the tag. – Skydiver Nov 8 '16 at 21:40
• What about $x^2-3$? – arberavdullahu Nov 8 '16 at 21:43
• Just surjective and not injective, no other conditions required? Why not $f(x)=x$ for $x\ge -3$ and $f(x)=-3$ otherwise – user160738 Nov 8 '16 at 21:44
• @arbervdullahu x^2 is not surjective... – Skydiver Nov 8 '16 at 21:50

The codomain of the function is $\{ x \in \mathbb R | x \geq -3\}$. Hence, surjective means that you should cover all $y \in \mathbb R$ so that $y \geq -3$ (do not let the notation fool you).
Consider the function $f(x) = x^2 - 3$.