Well ordering principle and prime factoriation Is it possible to prove the uniqueness of prime factorisation  of natural numbers by the well ordering principle ?
My attempt :
Let S be the set of all natural numbers whose prime factorisation is not unique and assume S is non-emoty.  Then there exists a least element of S, s by the WOP.  By definition s = p1p2p3...pn = q1q2q3...q where pi and qj are all prime numbers and there exists a pi ≠ qj for all j.  Dividing s by p1 gives s/p1 = p1p2p3...pn/p1 = q1q2q3...qm/p1 ie s/p1 = p2p3....pn = q1q2q3...qm/p1 which is also a natural number.  Therefore as p1|q1q2q3...qm it follows p1=qj for some j.  For convenience assume then p1=q1 and so therefore s/p1 = p2p3p4...pn = q2q3q4...qm. But then this number also belongs to S contradicting the fact s is the least element of S.  Therefore our assumption that S is non empty leads to a contradiction meaning S must be empty. 
 A: Yes, it is, though your argument isn’t quite right. The fact that the two prime factorizations of $s$ are different doesn’t immediately guarantee that one has a prime factor that does not appear in the other: in principle they might have exactly the same prime factors, but with different multiplicities. It’s possible to get around that, but it takes a little more work.
As in your argument, suppose that $S\ne\varnothing$, and let $s=\min S$. Then $s$ has distinct prime factorizations
$$s=p_1p_2\ldots p_m=q_1q_2\ldots q_n\;,$$
where we may assume that $p_1\le p_2\le\ldots\le p_m$ and $q_1\le q_2\le\ldots\le q_n$. Then $p_1\mid s$, so $p_1\mid q_1q_2\ldots q_n$, and therefore $p_1=q_k$ for some $k\in\{1,\ldots,n\}$. (If there is more than one such $k$, choose the smallest.) But then
$$\large\prod_{2\le i\le m}p_i=\prod_{{1\le i\le n}\atop{i\ne k}}q_i=\frac{s}{p_1}\notin S\;,$$
so the prime factorizations
$$\large\prod_{2\le i\le m}p_i\qquad\text{and}\qquad\prod_{{1\le i\le n}\atop{i\ne k}}q_i\tag{1}$$
must be identical. (This is where I use the fact that I arranged the factors of each product in non-decreasing order: that makes these products identical not just in identities of the factors, but also in their order.) Thus, $q_k=p_1\le p_2$, and $p_2$ is equal to the smallest of the factors $q_i$ with $i\ne k$, so the way I chose $k$ ensures that $k=1$ and $p_1=q_k=q_1$. Thus, the identical factorizations in $(1)$ are
$$\prod_{2\le i\le m}p_i\qquad\text{and}\qquad\prod_{2\le i\le n}q_i\;,$$
and it follows that $m=n$ and $p_i=q_i$ for $i=1,\ldots,m$, contradicting the hypothesis that $s\in S$.
