Consider the set of linear fractional transformations (LFTs) defined by

where a, b, c, and d are integers, and ad − bc = ±1. Since this set of LFTs contains an identity element (0 + x)/1, and since it is closed under composition of functions, and every member of the set has an inverse in the set, these LFTs form a group (the group operation being composition of functions), GL(2,Z).
We can define an equivalence relation on the set of real numbers by means of this group of linear fractional transformations. We will say that two real numbers x and y are equivalent (written x ~ y) if

for some integers a, b, c, and d such that ad − bc = ±1.
Clearly this relation is symmetric, reflexive, and transitive, so it is an equivalence relation and it can be used to separate the real numbers into equivalence classes. All the rational numbers are equivalent, because each rational number is equivalent to zero. What can be said about the irrational numbers? Do they also fall into a single equivalence class?
Two irrational numbers x and y are equivalent under this scheme if and only if the infinitely long "tails" in their expansions as regular continued fractions are exactly the same. More precisely, the following theorem can be proved.
Let x and y be two irrational (real) numbers, and let the kth complete quotient in the regular continued fraction expansions of x and y be denoted by ζ k and ψk, respectively, Then x ~ y (under the equivalence defined in the preceding section) if and only if there are positive integers m and n such that ζm = ψn.
The golden ratio φ is the irrational number with the very simplest possible expansion as a regular continued fraction: φ = [1; 1, 1, 1, …]. The theorem tells us first that if x is any real number whose expansion as a regular continued fraction contains the infinite string
[1, 1, 1, 1, …], then there are integers a, b, c, and d (with ad − bc = ±1) such that

Conversely, if a, b, c, and d are integers (with ad − bc = ±1), then the regular continued fraction expansion of every real number y that can be expressed in the form

eventually reaches a "tail" that looks just like the regular continued fraction for φ.