# Is $z=x^2+y^2$ a bijection?

I am learning basic set theory and was doing some exercises where we are to determine whether a given relation is a function, an injection, a surjection and if it is a bijection.

The question in this case was: Determine whether the relation from $\mathbb{R}^2$ to $\mathbb{R}$ defined by $(x,y)Rz$ if and only if $z=x^2+y^2$ is $(1)$ a function, $(2)$ an injection, $(3)$ a surjection and $(4)$ a bijection.

$(1)$ is clearly true. $(2)$ It is not an injection as $(x,y)$ and $(y,x)$ both map to the same point in $\mathbb{R}$. $(3)$ Neither is it a surjection as $x^2+y^2\ge0, \forall x,y\in\mathbb{R}$. $(4)$ This leads me to believe that it is therefore not a bijection. However the answers says it is. This is strange as the book defines a bijection to be a function which is both an injection and a surjection. Clearly the given relation does not satisfy either condition so cannot be a bijection.

I think the answers might have some typos though since it is missing the answer to the next exercise (A relation from $\mathbb{Z}\times\mathbb{Z}$ to $\mathbb{Z}\times\mathbb{Z}$ where $(a,b)R(x,y)$ if an only if $y=a$ and $x=b$; which I found to be a bijection) and so might have mixed up the answer to this exercise with the previous. However, I am new to set theory and so was wondering whether I just made a silly mistake.

-
Looks like a typo. It is in fact neither an injection nor a surjection, so it can't be a bijection. –  Qiaochu Yuan Jun 24 '12 at 6:20

Recall the definitions:

$F\colon A\to B$ is a bijection if two things are true:

1. For every $x,y\in A$ if $x\neq y$ then $F(x)\neq F(y)$ (injectivity); and
2. For every $b\in B$ there is some $a\in A$ such that $F(a)=b$ (surjectivity).

Now we identify this in the problem, $A=\mathbb R^2$ and $B=\mathbb R$, and $F(\langle x,y\rangle)=x^2+y^2$.

1. Is this $F$ injective (do the ordered pairs $\langle a,b\rangle$ and $\langle b,a\rangle$ have different images)?

2. Is this $F$ surjective (can the sum of two non-negative numbers be $-1$)?

Even if only one of these is true the definition of bijection no longer holds, in our case - both are true.

-

As you said, a bijection is both an injection and a surjection, therefore it can't be one, as you have shown to be neither of those.

-