2

Question. Suppose that positive integers $a,b,n$ satisfy $d=\gcd(a,n)=\gcd(b,n)$. Prove that then there are integers $x,y$ coprime to $n$ with $ax=b$ and $by=a$ modulo $n$.

I doubt this is true. First let integer $r$ be such that$$r\left(\frac a d\right)\equiv 1\left(\operatorname{mod}~\frac n d\right)$$

Of course finding $x$ with $ax=b$ modulo $n$ is just picking a solution $x$ in the form $$x_k=r\left(\frac b d\right)+k\left(\frac n d\right)=\frac{rb+kn}{d}~~(k=0,1,...,d-1).$$What is tricky is I need to show such $x_k$ is coprime to $n$ for some $k$. Actually it is sufficient to find $k$ such that $x_k$ is coprime to $d$. How could you pick such $k$?

For counterexamples, first note that the question is true when $d=1$, and in general it is true if $\gcd(a/d,n)=\gcd(b/d,n)$=1. It is also true when $n$ divides $a$ and $b$, because then $x=1$ would work...

  • 1
    If you suspect it's false, have you tried finding a counterexample? – jjagmath Mar 10 '25 at 14:55
  • @jjagmath Yes necessarily I really need $a,n$ such that $a/d$ is not coprime to $n$, but I haven't found an exact counterexample to the asked question for the pairs I have tested. – user108580 Mar 10 '25 at 15:00
  • That (and every other thing you have worked on the problem) should be in your post to avoid other to do work you have already done. – jjagmath Mar 10 '25 at 15:03
  • Duplicate almost surely, but I don't have time to search at the moment. OP: do you know anything about groups, rings, ideals, cosets? – Bill Dubuque Mar 10 '25 at 15:39
  • @BillDubuque Yes, and I accept answers of all levels. – user108580 Mar 10 '25 at 15:40
  • Hint: $, a:!\Bbb Z_n = \gcd(a,n):!\Bbb Z_n,,$ so $,a\Bbb Z_n = b\Bbb Z_n,$ by hypothesis. For visual intuition see Spirograph and Roulette curves and Star Polygons. $\ \ $ – Bill Dubuque Mar 10 '25 at 15:53
  • @BillDubuque Okay but $a\mathbb Z_n=b\mathbb Z_n$ basically just tells me there is an $x$ with $ax=b$ modulo $n$. But is there a reasoning of why you can choose $x$ in $\mathbb Z_n^\times$? This is specified in the question that $x$ needs to be coprime to $n$. – user108580 Mar 10 '25 at 15:55
  • You need to know that if $u\equiv v\pmod w,$ then $ud\equiv vd\pmod{wd}.$ – Thomas Andrews Mar 10 '25 at 16:42
  • Duplicate $\exists:! k\in \Bbb Z!:\ (rb/d + k,n/d, n)=1,$ follows from here by $(rb/d,n/d) = 1,,$ by $(r,n/d)=1=(b/d,n/d).,$ I give a one-line intuitive high-school level proof there that avoids need for CRT or p-adic valuations (using an old idea of Stieltjes). See also here. – Bill Dubuque Mar 10 '25 at 19:47
  • I asked about ring theory knowledge since your question is equivalent to "associates are unit multiples" in the ring $\Bbb Z_n \cong \Bbb Z/(n),,$ which follows from known results for more general rings, see the literature I cite here. I'll add an answer from this more general perspective when spare time arises. $\ \ $ – Bill Dubuque Mar 14 '25 at 13:34

1 Answers1

-1

Since $a/d$ and $n/d$ are coprime, there is some integer $r$ with $ar/d\equiv 1$ modulo $n/d$, so that $abr/d\equiv b$ modulo $n$. We know $r$ and $b/d$ are both coprime to $n/d$, so is $rb/d$. Define $d’$ be the largest positive factor of $d$ which is coprime to $n/d$(think of it as just $d$ dividing out all prime factors that occur in $n/d$.) Now use Chinese Reminder Theorem for the system $x\equiv rb/d$ modulo $n/d$ and $x\equiv 1$ modulo $d’$. The resulting $x$ satisfies $ax=b$ modulo $n$ and the $x$ is coprime to both $n/d$ and $d’$, thus coprime to $n$ as well. Use similar reasoning for finding $y$.