# When is an Integer a Rational Number, and are All Ratios Rational, Even $\frac{\sqrt{7}}{2}$?

$$\Bbb{Q} = \left\{\frac ab \mid \text{a and b are integers and b \ne 0} \right\}$$

In other words, a rational number is a number that can be written as one integer over another.

For an integer, the denominator is $1$ in that case. For example, $5$ can be written as $\dfrac 51$.

Is $5$ a rational number? Or is $\dfrac 51$ a rational number? I'm not able to figure out what the definition is actually saying. What are the numbers that cannot be written as one integer over another?

Irrational numbers are the numbers that cannot be written as one integer over another. Roots of numbers that are not perfect squares are examples of irrational numbers.

However, what is this then: $\dfrac {\sqrt 7} {2}$?

• Every integer is a rational number, as you showed, yet $\,\frac{\sqrt 7}2\,$ is not a rational since it is not a quotient of two integers... – DonAntonio May 14 '13 at 16:02
• I'm not sure I understand what you mean. $\frac{\sqrt{7}}{2}$ is not rational, because $\sqrt{7}$ is not an integer. Have you seen a proof that $\sqrt{2}$ is not rational, e.g., where you suppose $\sqrt{2} = p/q$ with $p$ and $q$ coprime integers, and get a contradiction? – snar May 14 '13 at 16:03

## 7 Answers

Any number for which it is possible to express as the ratio or quotient of integers is a rational number. So yes, $5$ is rational, because it is possible to express this as $\frac 51, \frac {10}{2}...$.

$5$ is also an integer. Every integer is a rational number, but not all rational numbers, e.g. $\frac 12$, is an integer. We know $\frac 12$ is rational, because it is the quotient of two integers.

However, $\dfrac {\sqrt 7}{2}$ is not a ratio of integers. It is a ratio of a non-integer, namely $\sqrt 7$, over an integer. So $\dfrac{\sqrt 7}{2}$ is not rational.

• $0.5$ is a rational number because it can be expressed as a quotient of two integers, i.e. $\frac 12$. But what about $\frac {0.5}{1}$ ? The numerator in this case is not a integer. Nevertheless, the answer is '$\frac {0.5}{1}=0.5$' which is a rational number. – Samama Fahim May 14 '13 at 18:13
• $\frac{0.5}{1} = 0.5 = \frac 12$. Since it is possible to equate $0.5$ as a ratio of integers, it is rational, whatever form it takes. We don't necessarily have to use any given form, we only need to know it is possible to equate it with a quotient/ratio of integers. – Namaste May 14 '13 at 18:24
• @amWhy: This might be on its way to a nice answer badge :-) +1 – Amzoti May 15 '13 at 0:34
• It's not that obvious that $\frac{\sqrt{7}}{2}$ is irrational. One could use a similar argument to "prove" that $\frac{\sqrt{7}}{\sqrt{7}}$ is irrational. – Pedro May 15 '13 at 1:13
• @amWhy however you are not proving that $\frac{\sqrt{7}}{2}\notin\mathbb{Q}$ since you must prove first (as Pedro said) that every square root of a natural that is not perfect square is irrational. And the OP seems not so aware of the fact unless he mentions it on post, and I suppose he hasn't proven that. That is done later. Things are not so easy. I think your response is not the right one unless the OP marked it. – elessartelkontar Feb 4 '14 at 20:56

$\sqrt{7}$ is not a rational number.

You can prove it by the absurd.

Suppose that you can write it as $\sqrt{7}=\frac{a}{b}$ with $a$ and $b$ natural numbers.

You can suppose without loss of generality that $a$ and $b$ are coprime. Decompose $a$ and $b$ in prime factors: $a=a_1^{n_1}\dots a_k^{n_k}$ and $b=b_1^{m_1}\dots b_l^{m_l}$. All the $a_i$ are primes and different of all the $b_j$ (also primes) because $a$ $b$ are coprime.

$\sqrt{7}=\frac{a}{b}$ give you $7=\frac{a^2}{b^2}$ hence $a^2=7\cdot b^2$ hence $a_1^{2n_1}\dots a_k^{2n_k}=7b_1^{2m_1}\dots b_l^{2m_l}$ hence one of the $a_i$ is $7$ (lets say $a_1=7$). We have: $7^{2n_1-1}\dots a_k^{2n_k}=b_1^{2m_1}\dots b_l^{2m_l}$ hence $7$ divide $b_1^{2m_1}\dots b_l^{2m_l}$ hence one of the $b_j$ is $7$ contradiction with $a$ $b$ coprimes.

• Why are you allowed to assume they are coprime? – Robert S. Barnes May 25 '15 at 17:49
• @RobertS.Barnes If they are not you can write $a=a'.k$ and $b=b'.k$ for some integer $k$ and with $a'$ and $b'$ coprime. Hence $\sqrt{7}=a/b=a'.k/(b'.k)=a'/b'$. – wece May 26 '15 at 7:04

Although there are many answers here already, unless if I have missed something none of them actually proves that $\sqrt{7}/2$ is irrational. As already noted in the comments to amWhy's answer, it is not valid to say that if $a$ is not an integer then $a/b$ is irrational. However, it is valid to say that if $a$ is irrational and $b$ is rational, then $a/b$ is irrational. (This is because if $a/b$ and $b$ were both rational, then their product $a$ would be rational because the product of rational numbers is always rational.) Because $\sqrt{7}$ is irrational (as shown in wece's answer) and 2 is rational, the ratio $\sqrt{7}/2$ is irrational.

As $5$ can be written as $\frac 51$, yes, $5$ is a rational number. All integers are also rational. The fraction $\frac{\sqrt 7}2$ does not denote a rational number because the numerator $\sqrt 7$ is not an integer.

• Your argument for saying that $\frac{\sqrt{7}}{2}$ is not a rational number lays out false. For example: $r=\frac{4}{123}$ and $s=\frac{r}{21}$, then for you $s$ is not rational, since $r$ is not integer. – elessartelkontar Feb 4 '14 at 20:44

$5$ is an integer and a rational number. It is convention that we omit the denominator when it is $1$.

$\frac{\sqrt{7}}{2}$ is not a rational number as it does not conform to the definition i.e., the numerator is not an integer.

A and B have to be integers. Square root 7 is not an integer. It is irrational so it does not qualify as being a rational number. Yes 5/1 is rational. It perfectly satisfies the definition.

Rational numbers are usually defined in terms of the integers.

I would define a rational number as an ordered pair of integers $(a, b)$ such that $b \ne 0$. I would then define equality for rational numbers by $(a, b) = (c, d)$ if and only if $ad = bc$.

With the interpretation of $(a, b)$ as the rational number $a/b$, this means that $a/b = c/d$ if and only if $ad = bc$. In other words, our previous knowledge of how rational number should behave drives all our definitions relating to these rational numbers.

For example, since we want $a/b + c/d = (ad+bd)/bd$, we would $define$ addition by $(a, b)+(c,d) = (ad+bc, bd)$. We would then show that these "rational numbers" behave exactly like we want rational numbers to behave.

Finally, we would say "From now on, we will write $(a, b)$ as $a/b$", and then forget all the constructions since we have laboriously constructed something we we already quite familiar with.

Another example of this is defining all integers in terms of positive integers. We can write an integer as an ordered pair of positive integers $(a, b)$ with equality being defined by $(a, b) = (c, d)$ if and only if $a+d = b+c$. This is because we want $(a, b)$ to mean $a-b$, and $a-b = c-d$ is the same as $a+d = b+c$. This reason we use this definition of equality is that, in our definition of "integers", we can only use positive integers, where addition is always possible, but subtraction is not always possible.

Similarly, in our definition of rational numbers in terms of integers, multiplication is always possible, but division is not always possible.

For more than you probably want to know about this process, read "Foundations of Analysis" by Edmund Landau. This starts with constructing the integers and ends up with the complex numbers.