I consider two sequences of numbers $A=\{a\_1,...,a\_n\}$ and $B=\{k-a\_1,...,k-a\_n\}$, where $a\_1 \le a\_2 \le ... \le a\_n \le k$.


**I am looking for such conditions under which**: $\gcd(a\_1,...,a\_n) = \gcd(k-a\_1,...,k-a\_n)=1$.


**In more general form**: $\gcd(a\_1,...,a\_n) = \gcd(k-a\_1,...,k-a\_n) \ge 1$.




---


It can be seen that the problem is solved only in a particular forms.


I found only four particular solutions.


1. If there is such a number $\exists a\_s \in A: k-a\_t=a\_s$, where $a\_t \in A$ then $\gcd(a\_1,...,a\_n) = \gcd(k-a\_1,...,k-a\_n)$.
2. Let $\gcd(a\_1,...,a\_n)=e$ and $\gcd(a\_n-a\_1,...,a\_2-a\_1)=E$. If $e=E$ and $e\mid k$, then $\gcd(a\_1,...,a\_n) = \gcd(k-a\_1,...,k-a\_n)$.
3. Let $P=p\_1 \cdot ... \cdot p\_n$ denotes the primorial equaling the product of the first $n$ prime numbers and $p\_i$ is the $i^{th}$ prime number. Let $a\_i=\frac{P}{p\_i}$ and $k=P$, then $\gcd(a\_1,...,a\_n) = \gcd(k-a\_1,...,k-a\_n) = 1$.
4. Let $\gcd(k-a\_1,...,k-a\_n) = 1$ and $a\_i\mid k, \forall a\_i \in A$, then $\gcd(a\_1,...,a\_n) = 1$.


**I am convinced that there are other solutions, but I can not find them yet.
I will be grateful for any help.**



Greatest common divisor of two specified sequences of numbers (search for equality)
Here is a try. Call $k$ to be good, if $d\_k\triangleq (k-a\_1,\dots,k-a\_n)>(a\_1,\dots,a\_n)=1$. If $k$ is good, it then follows that, there is a prime $p$, such that $p\mid k-a\_i$ for every $1\leqslant i \leqslant n$. In particular, $a\_1\equiv \cdots\equiv a\_n\equiv k\pmod{p}$. Hence, if $k$ is good, then there necessarily is a prime $p$ at which $a\_1,\dots,a\_n$ are all congruent. 


Now, if $k$ is such that, if for all prime $p$, there is an $i$ with $k-a\_i\not\equiv 0\pmod{p}$, we then have that $(k-a\_1,\dots,k-a\_n)=1$. In particular, a sufficient condition is as follows. If the collection $(a\_1,\dots,a\_n)$ is such that, for every prime $p$, there exists $i <j$ such that $a\_i\not\equiv a\_j\pmod{p}$, we have that for any $k$, $(k-a\_1,\dots,k-a\_n)=1$.


