Maths WorkshopMaths problems with full solutions
Exercise 742Number theory › Divisibility and gcdHigh schoolAdded 2 Nov 2026

When are $2n$ and $3n+1$ coprime?

#divisibility#linear combination#coprimality

Statement

For which integers nn are 2n2n and 3n+13n+1 coprime?

Hint

Find a linear combination of 2n2n and 3n+13n+1 that is constant.

Show solutionHide solution

Solution

Linear combination.
2(3n+1)−3(2n)=6n+2−6n=2.2(3n+1)-3(2n)=6n+2-6n=2.
So d=\divisibility(2n,3n+1)d=\divisibility(2n,3n+1) divides 22, hence d∈{1,2}d\in\{1,2\}.

When is d=2d=2? Since 2n2n is always even, d=2d=2 iff 3n+13n+1 is even, i.e. nn is odd.

Conclusion. \divisibility(2n,3n+1)=1\divisibility(2n,3n+1)=1 if nn is even, and 22 if nn is odd. The numbers are coprime exactly when nn is even.