# Thread: Prove sqrt(q) is irrational

1. ## [SOLVED]Prove sqrt(q) is irrational

Let q $\displaystyle \geq$ 2 be such that $\displaystyle \forall a \in \mathbb{Z} \forall b \in \mathbb{Z}$, q|ab $\displaystyle \longrightarrow$ q|a or q|b. Show that $\displaystyle \sqrt q$ is irrational.

The hint of the book said to imitate the proof that $\displaystyle \sqrt 2$ is irrational. I did it by letting $\displaystyle x^2=q$ and assuming $\displaystyle x = \sqrt q$ is rational. So $\displaystyle x = \frac{m}{n}$ and then $\displaystyle x^2= q = \frac{m^2}{n^2}$ . Thus, $\displaystyle qn^2=m^2$.

From here, I must consider if m is even or odd. If m is odd, it must follow that both q and $\displaystyle n^2$ is odd.

It does not seem I could reach any contradiction from the assumption $\displaystyle \forall a \in \mathbb{Z} \forall b \in \mathbb{Z}$, q|ab $\displaystyle \longrightarrow$ q|a or q|b.

2. Originally Posted by armeros
Let q $\displaystyle \geq$ 2 be such that $\displaystyle \forall a \in \mathbb{Z} \forall b \in \mathbb{Z}$, q|ab $\displaystyle \longrightarrow$ q|a or q|b. Show that $\displaystyle \sqrt q$ is irrational.

The hint of the book said to imitate the proof that $\displaystyle \sqrt 2$ is irrational. I did it by letting $\displaystyle x^2=q$ and assuming $\displaystyle x = \sqrt q$ is rational. So $\displaystyle x = \frac{m}{n}$
$\displaystyle x= \frac{m}{n}$, reduced to lowest terms. That means that m and n have no common factors, therefore $\displaystyle m^2$ and $\displaystyle n^2$ have no common factors.

and then $\displaystyle x^2= q = \frac{m^2}{n^2}$ . Thus, $\displaystyle qn^2=m^2$.
And since $\displaystyle m^2$ and $\displaystyle n^2$ have no common factors, q must divide $\displaystyle m^2= (m)(m)$ so, by your condition, q must divide m. m= qp for some integer p and so $\displaystyle m^2= q^2p^2$ and then $\displaystyle qn^2= q^2p^2$, $\displaystyle n^2= qp^2$. Since $\displaystyle p^2$, and thus p, is a factor of $\displaystyle m^2$ and so not a factor of $\displaystyle n^2$, we must have q a factor of $\displaystyle n^2$, again, by your condition on q, a factor of n, contradicting the fact that m and n have no common factors.

From here, I must consider if m is even or odd. If m is odd, it must follow that both q and $\displaystyle n^2$ is odd.

It does not seem I could reach any contradiction from the assumption $\displaystyle \forall a \in \mathbb{Z} \forall b \in \mathbb{Z}$, q|ab $\displaystyle \longrightarrow$ q|a or q|b.

$\displaystyle q | ab$ implies $\displaystyle q | a$ or $\displaystyle q | b$ for all $\displaystyle a,b \in \Bbb Z,$
then q must be a prime. Indeed if we had $\displaystyle q=mn$ with neither $\displaystyle m$ nor $\displaystyle n$ a unit, then $\displaystyle q | mn$ but $\displaystyle q$ would certainly divide neither m or n.
Now to show $\displaystyle \sqrt{p}$ is irrational, suppose $\displaystyle \sqrt{p}=\frac{a}{b}$. Then $\displaystyle pb^2=a^2$. The right-hand side is a square, hence all prime powers in the factorization of $\displaystyle pb^2$ should have even exponent; but the exponent of p is odd. Hence there exist no such $\displaystyle a,b$.
{"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 1, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "url": "http://mathhelpforum.com/number-theory/92620-prove-sqrt-q-irrational.html", "fetch_time": 1524242985000000000, "content_mime_type": "text/html", "warc_filename": "crawl-data/CC-MAIN-2018-17/segments/1524125944479.27/warc/CC-MAIN-20180420155332-20180420175332-00087.warc.gz", "warc_record_offset": 204778167, "warc_record_length": 10404, "token_count": 965, "char_count": 3163, "score": 4.0625, "int_score": 4, "crawl": "CC-MAIN-2018-17", "snapshot_type": "latest", "language": "en", "language_score": 0.8025293350219727, "file_path": "/sailhome/yjruan/project/latent-lm/data/processed/finemath-4plus/finemath-4plus/train-00010-of-00064.parquet"}