Prove that a subset of $\mathbb{Z}$ is a subgroup.

First consider the case $A\subseteq \mathbb{Z}$ . . .

If $A=\{0\}$, then $A$ is the trivial subgroup of $\mathbb{Z}$.

Suppose $A\ne\{0\}$.

Since $A$ is closed under negation, $A$ must have a least positive element, $a$ say.

Claim:$\;A=\langle{a}\rangle\;$(the cyclic subgroup of $\mathbb{Z}$ generated by $a$).

Proof:

By an easy induction, $0+2ka\in A$ for all nonnegative integers $k$.

Thus if $n$ is an even nonnegative integer, then $n=2k$ for some nonnegative integer $k$, hence $na=2ka=0+2ka\in A$.

Similarly, by an easy induction, $a+2ka\in A$ for all nonnegative integers $k$.

Thus if $n$ is an odd positive integer, then $n=2k+1$ for some nonnegative integer $k$, hence $na=(2k+1)a=a+2ka\in A$.

Combining both cases, and noting that $A$ is closed under negation, it follows $na\in A$ for all integers $n$.

Hence $\langle{a}\rangle\subseteq A$.

To show $A=\langle{a}\rangle$, suppose instead that we have the proper inclusion $\langle{a}\rangle\subset A$.

Then $A{\setminus}\langle{a}\rangle\ne{\large{\varnothing}}$.

Our goal is to derive a contradiction.

Since $A$ is closed under negation, and $0\in A$, it follows that $A{\setminus}\langle{a}\rangle$ has a least positive element, $b$ say.

By minimality of $a$, we must have $b > a$.

By hypothesis $b-2a\in A$ and since $b\not\in\langle{a}\rangle$, it follows that $b-2a\in A{\setminus}\langle{a}\rangle$.

Since $b-2a < b$, the minimality of $b$ implies $b-2a < 0$.

Thus, $a < b < 2a$.

By hypothesis $2a-b\in A$ and since $b\not\in\langle{a}\rangle$, it follows that $2a-b\in A{\setminus}\langle{a}\rangle$.

But from $a < b < 2a$, we get $0 < 2a - b < b$, contrary to the minimality of $b$.

This completes the proof.

Next consider the case $A\subseteq \mathbb{Z}^2$ . . .

To show that $A$ need not be a subgroup of $\mathbb{Z}^2$, consider the set $$A=\{(x,y)\in\mathbb{Z}^2\mid\;\text{at least one of $x,y$ is even}\}$$ Then $A$ satisfies the hypothesis, but $A$ is not closed under addition since $(1,0)\in A$ and $(0,1)\in A$, but $(1,1)\not\in A$.


Our goal is to prove that for all $a, b\in A$, $a+b\in A$. The result then follows.

Lets start by proving a rather interesting variant of Bézout's identity, which classically says that given $a, b\in\mathbb{Z}$, there exist integers $p, q\in\mathbb{Z}$ such that $\gcd(a, b)=pa+qb$. We show that we may assume that one of these integers $p$ or $q$ is even.

Lemma. Given $a, b\in\mathbb{Z}$ there exist integers $p, q\in\mathbb{Z}$ such that $\gcd(a, b)=pa+qb$, and either $p$ or $q$ is even.

Proof. We know that there exists some pair $(x, y)\in\mathbb{Z}^2$ such that $\gcd(a, b)=xa+yb$. If one of $x$ or $y$ is even then there is nothing to prove, so assume that both are odd. Set: \begin{align*} p&=x+\frac{b}{\gcd(a,b)}\\ q&=y-\frac{a}{\gcd(a,b)} \end{align*} It is straightforward to verify that $\gcd(a, b)=pa+qb$: \begin{align*} \gcd(a, b) &=xa+yb\\ &=xa+yb+\frac{ab}{\gcd(a,b)}-\frac{ab}{\gcd(a,b)}\\ &=\left(x+\frac{b}{\gcd(a,b)}\right)a+\left(y-\frac{a}{\gcd(a,b)}\right)b\\ &=pa+qb \end{align*} Finally, one of $p$ or $q$ is even: by properties of $\gcd$, one of $\frac{a}{\gcd(a,b)}$ or $\frac{b}{\gcd(a,b)}$ is odd, and so as $x$ and $y$ are both odd, and as odd+odd=even, we have that one of $p$ or $q$ is even, as required. QED


We now return to the question. Firstly, suppose $a\in A$. Then, as observed in the comments, we can use induction and the identity $A+2A\subset A$ to prove that $ka\in A$ for all odd integers $k\in\mathbb{Z}$. Moreover, the identity $A+2A\subset A$ implies that $0+2ka\in A$, and so $ka\in A$ for all integers $k\in\mathbb{Z}$. Therefore, the subgroup $\langle a\rangle$ of $\mathbb{Z}$ is contained in $A$.

Now, suppose $a, b\in A$. Then, as $pa, q'b\in A$ for all $p, q'\in\mathbb{Z}$, we have $pa+2q'b\in A$. By the above lemma, $\langle \gcd(a, b)\rangle\subset A$. By the definition of $\gcd$, this implies that $a+b\in\langle \gcd(a, b)\rangle$ and so $a+b\in A$ as required.