# Provide infinite sequence of coprime numbers [duplicate]

This question already has an answer here:

Provide an infinite sequence of natural numbers $x_1,x_2,x_3,\ldots$ such that I'm not sure if I'm on the right track with that. any help would be great

## marked as duplicate by Community♦Mar 15 '17 at 5:19

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

## 1 Answer

Your answer is certainly correct: if you choose $x_n$ to be $p_n^2$ (the square of the $n$th prime number), then

• none of the numbers $x_n$ are prime numbers $\checkmark$, and
• any two $x_n$ and $x_m$ are coprime to each other $\checkmark$

The latter part is true because

• $\gcd(p,q)=1$ for any distinct prime numbers $p$ and $q$
• $\gcd(ab,c)=\gcd(a,c)$ if $\gcd(b,c)=1$, for any integers $a,b,c$

and therefore $$\gcd(x_n,x_m)=\gcd(p_n^2,p_m^2)=\gcd(p_n,p_m^2)=\gcd(p_m^2,p_n)=\gcd(p_m,p_n)=1$$ for any two prime numbers $p_n$, $p_m$.

• ahh thanks ! how would you write it so theres an infinite sequence of natural numbers ? – rprogramr Mar 14 '17 at 8:58
• @rprogramr: Not sure what you're looking for; I would say that the sentence $$\text{“Define x_n to be p_n^2, the square of the nth prime number”}$$ gives an infinite sequence of natural numbers, since there are infinitely many prime numbers. – Zev Chonoles Mar 14 '17 at 9:03
• alright I see thank you for the feedback ! :) – rprogramr Mar 14 '17 at 9:04