One of the problems in my discrete math course states that we need to prove that $\mathcal{N}\times\mathcal{N}$ is countable specifically when there's a function $f:\mathcal{N}\times\mathcal{N}\to\mathcal{N}$ defined as follows: $$f(a,b)=\frac{1}{2}(a+b+1)(a+b)+a$$ where $a,b \in \mathcal{N}$. The solution uses the function definition in order to prove that the function is bijective as shown below: $$f(a,b+1)=\frac{1}{2}(a+b+1+1)(a+b+1)+a=$$ $$=\frac{1}{2}(a+b+1)(a+b)+a+\frac{1}{2}(a+b+1)\cdot2$$ How is the transition achieved? I tried all kinds of arithmetics and couldn't arrive to the expression after the equal sign.
2026-03-31 17:59:57.1774979997
cardinality of cartesian product of the infinite set of natural numbers
1.4k Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
$$f(a,b+1)=\color{red}{ \dfrac{1}{2}}(\color{green}{a+b+1}\color{blue}{+1})(a+b+1)+a=$$
$$=\color{red}{ \dfrac{1}{2}}(\color{green}{a+b+1})(a+b+1) + \color{red}{\dfrac{1}{2}}(\color{blue}{+1})(a+b+1)+a$$
$$=\color{red}{ \dfrac{1}{2}}(\color{green}{a+b+1})(a+b\color{orange}{+1}) + \color{red}{\dfrac{1}{2}}(\color{blue}{+1})(a+b+1)+a$$
$$=\color{red}{ \dfrac{1}{2}}(\color{green}{a+b+1})(a+b) + \underbrace{\color{red}{ \dfrac{1}{2}}(\color{green}{a+b+1})(\color{orange}{+1}) + \color{red}{\dfrac{1}{2}}(\color{blue}{+1})(a+b+1)}_{\color{purple}{\text{two copies}}}+a$$
$$=\color{red}{ \dfrac{1}{2}}(\color{green}{a+b+1})(a+b) +\color{purple}{ \dfrac{1}{2}(a+b+1)\cdot 2}+a$$