# Why $p_1\mid a \wedge p_2\mid a \Rightarrow p_1p_2\mid a$? [duplicate]

Why $$p_1\mid a \wedge p_2\mid a \Rightarrow p_1p_2\mid a$$ where $$p_i$$ is a prime number, $$p_i \neq p_j$$ and $$a$$ is a integer?

I don't fully understand that.

Also, is it true when $$p_i$$ is something different from a prime number?

• This is not true. Take $p_1=p_2=a$. Nov 10, 2020 at 10:13
• I edited the question to say that $p_i \neq p_j$. Nov 10, 2020 at 10:39
• For the second part of the question (non-prime $p_i$), you need still $p_1$ and $p_2$ to be coprime, as an example $p_1=2,p_2=4,a=4$ shows.
– Sil
Nov 10, 2020 at 10:44
• @Sil, thank you, below in the answer it's beem already said. Nov 10, 2020 at 10:51

Edit
Thanks to Dietrich Burde for indicating that a counter example is the case where $$p_1$$ and $$p_2$$ are the same prime. This answer assumes that they are distinct primes.

$$p_1 | a \implies ~\exists ~r ~\text{such that} ~a = p_1 \times r.$$

Therefore, $$p_2 | a ~\implies ~p_2 | (p_1 \times r).$$

Since $$p_1$$ and $$p_2$$ are relatively prime, this implies that

$$p_2 | r \implies ~\exists ~$$s$$~\text{such that} ~r = ~p_2 \times s.$$

Therefore, $$p_2 \times s \times p_1 = r \times p_1 = a.$$

A sufficient (but not necessarily required) condition is that $$p_1$$ and $$p_2$$ be relatively prime. They don't have to actually be prime #'s.

• But $p_2sp_1=rp_1$ is wrong for $r=s=1$ (the OP doesn't say that $p_1$ and $p_2$ are relatively prime). Nov 10, 2020 at 10:14
• But you agree that the choice $p_1=p_2=a$ is a counterexample to the statement? So you should need that $p_1$ and $p_2$ are distinct primes. Nov 10, 2020 at 10:24
• @DietrichBurde See my latest edit. Nov 10, 2020 at 10:31
• Thanks, I see it now. Nov 10, 2020 at 10:37