Determine if $$p: \mathbb N \times \mathbb N \to \mathbb N\quad \quad p(a,b) = \frac {ab(b+1)}2$$ is injective and/or surjective.
Just from looking at it and plugging in a few numbers I can already tell that this function is a bijection. However, I have no clue how to begin to prove that this is the case.
I am comfortable proving injectivity and surjectivity for functions with 1 variable but I get very confused when there is more than 1.
I could use some help generalizing a way of how to do this comfortably.
Thanks.
Best Answer
It is surjective because $p(n,1)=n$. It is not injective because $p(5,2)=p(1,5)$.