Rationals are exactly the fractions of two integers
A rational number is a quotient p/q of integers with q nonzero—every integer included when q is 1. The set of rationals closes under addition, subtraction, multiplication, and division by nonzero rationals, forming a field. Irrationals are the numbers that refuse this fraction form.
Their decimal expansions either stop, as 3/4 = 0.75 does, or settle into a repeating block, as with 9/44 = 0.20454545…. Reals lacking that property are irrational, such as √2, e, π and φ, the golden ratio. Because the rationals are countable and the reals are not, almost every real number is irrational, even though the rationals are dense among the reals, and the reals can be constructed from them through Cauchy sequences, Dedekind cuts or infinite decimals.
Each rational has one canonical form a/b with a and b coprime and b positive, reached by dividing out the greatest common divisor and flipping signs if the denominator is negative; an integer n becomes n/1. Sums follow (ad + bc)/bd and products ac/bd, though a product of two canonical fractions can still be reducible. Every rational has an opposite, every nonzero one has a reciprocal b/a, and dividing by c/d amounts to multiplying by d/c.
Algebraically the rationals, written Q, form the smallest field containing the integers, a prime field, and any field of characteristic zero contains a copy of them. The vocabulary runs backwards from what one might guess: irrational was applied to numbers in 1551, following translations of Euclid's term for lengths the Greeks refused to treat as numbers, rational followed in 1570, and ratio in its modern sense only around 1660. As an adjective the word can also mean having rational coefficients, so a rational point is one whose coordinates are all rational.
Source: Rational number