In mathematics, an **irrational number** is any real number that is not a rational number, i.e., one that cannot be written as a fraction *a* / *b* with *a* and *b* integers and *b* not zero. The irrational numbers are precisely those numbers whose decimal expansion never ends and never enters a periodic pattern. "Almost all" real numbers are irrational, in a sense which is defined more precisely below.

Some irrational numbers are algebraic numbers such as 2^{1/2} (the square root of two) and 3^{1/3} (the cube root of 3); others are transcendental numbers such as &pi and *e*.

Perhaps the numbers most easily proved to be irrational are logarithms like log_{2}3. The argument by reductio ad absurdum is as follows:

- Suppose log
_{2}3 is rational. Then for some positive integers`m`and`n`, we have log_{2}3 =`m`/`n`. - Consequently 2
^{m/n}= 3. - So 2
^{m}= 3^{n}. - But 2
^{m}is even (because at least one of its prime factors is two) and 3^{n}is odd (because none of its prime factors is two (they're all three)) so that is impossible.

The discovery of irrational number is usually attributed attributed to Pythagoras or one of his followers, who produced a (most likely geometrical) proof of the irrationality of the square root of 2.

One proof of this irrationality is the following reductio ad absurdum. The proposition is proved by assuming the opposite and showing that that is false, which in mathematics means that the proposition must be true.

- Assume that √2 is a rational number. Meaning that there exists an integer
*a*and*b*so that*a*/*b*= √2. - Then √2 can be written as an irreducible fraction (the fraction is shortened as much as possible)
*a*/*b*such that*a*and*b*are coprime integers and (*a*/*b*)^{2}= 2. - It follows that
*a*^{2}/*b*^{2}= 2 and*a*^{2}= 2*b*^{2}. - Therefore
*a*^{2}is even because it is equal to 2*b*^{2}which is obviously even. - It follows that
*a*must be even. (Odd numbers have odd squares and even numbers have even squares.) - Because
*a*is even, there exists a*k*that fullfills:*a*= 2*k*. - We insert the last equation of (3) in (6): 2
*b*^{2}= (2*k*)^{2}is equivalent to 2*b*^{2}= 4*k*^{2}is equivalent to*b*^{2}= 2*k*^{2}. - Because 2
*k*^{2}is even it follows that*b*^{2}is also even which means that*b*is even because only even numbers have even squares. - By (5) and (8)
*a*and*b*are both even, which contradicts that*a*/*b*is irreducible as stated in (2).

This proof can be generalized to show that any root of any natural number is either a natural number or irrational.

Because the algebraic numbers form a field, many irrational numbers can be constructed by combining transcendental and algebraic numbers. For example 3π+2, π + √2 and *e*√3 are irrational (and even transcendental).

It is often erroneously assumed that mathematicians define "irrational number" in terms of decimal expansions, calling a number irrational if its decimal expansion neither repeats nor terminates. No mathematician takes that to be the definition, since the choice of base 10 would be arbitrary and since the standard definition is simpler and more well-motivated. Nonetheless it is true that a number is of the form *n*/*m* where *n* and *m* are integers, if and only if its decimal expansion repeats or terminates. When the long division algorithm that everyone learns in grammar school is applied to the division of *n* by *m*, only *m* remainders are possible. If 0 appears as a remainder, the decimal expansion terminates. If 0 never occurs, then the algorithm can run at most *m* − 1 steps without using any remainder more than once. After that, a remainder must recur, and then the decimal expansion repeats! Conversely, suppose we are faced with a repeating decimal, for example:

It is not known whether π + *e* or π − *e* are irrational or not. In fact, there is no pair of non-zero integers *m* and *n* for which it is known whether *m*π + *ne* is irrational or not.
It is not known whether 2^{e}, π^{e}, π^{√2} or the Euler-Mascheroni gamma constant γ are irrational.

The set of all irrational numbers is uncountable (since the rationals are countable and the reals are uncountable). Using the absolute value to measure distances, the irrational numbers become a metric space which is not complete. However, this metric space is homeomorphic to the complete metric space of all sequences of positive integers; the homeomorphism is given by the infinite continued fraction expansion. This shows that the Baire category theorem applies to the space of irrational numbers.