(*This Program is designed to generate the Grand Set of rational numbers, whose numerators and denominators are bounded by Fibonacci(n + 1).  The order of this set is 2*Farey(m) - 3, where m = Fibonacci(n + 1).  Farey(Fibonacci(n + 1)) is the Sequence 3-A1???: 2, 3, 5, 11, 23, 59, 141, 361, 941, 2457, 6331, 16619, 43359, 113159, 296385, 775897, 2030103, 5315385, 13912615, 36421835, 95355147, 249635525, ....  2*Farey(m) - 3 is the Sequence A176500: 1, 3, 7, 19, 43, 115, 279, 719, 1879, 4911, 12659, 33235, 86715, 226315, 592767, 1551791, 4060203, 10630767, 27825227, 72843667, 190710291, 499271047, ...  Start the Program by entering the value of n. Example: n = 5, m = Fibonacci(6) = 8, Farey(8) = 23, Grand Set(5) = 43.  These sequences occur in the upper bound of networks formed by n equal resistors.  Author: Sameen Ahmed KHAN, rohelakhan@yahoo.com, http://SameenAhmedKhan.webs.com/ and http://sites.google.com/site/rohelakhan/ E-Print archive: http://arxiv.org/abs/1004.3346/ (21 April 2010) Date: Wednesday the 21 April 2010*)

n = 5; 
m = Fibonacci[n + 1];
FareyFibonacci = Union[Flatten[Table[a/b, {b, m}, {a, 0, b}]]];
GSet = Complement[FareyFibonacci, {0}];
GrandSet = Union[GSet, 1/GSet];
(*Print[StringForm["n = ``, m = Fibonacci(n + 1) = ``, Farey Fibonacci Set = ``, Order of Farey Fibonacci Set = ``",  
                  n, m, FareyFibonacci, Dimensions[FareyFibonacci] ]]*)
(*This line prints the Farey Set with its order*)
Print[StringForm["n = ``, m = Fibonacci(n + 1) = ``, GrandSet = ``, Order of Grand Set =``",  
                  n, m, GrandSet, Dimensions[GrandSet] ]]
(*This line prints the Grand Set with its oder*)
Print[StringForm["n = ``, m = Fibonacci(n + 1) = ``, Order of Farey Fibonacci Set = ``, Order of Grand Set = 2*Farey(m) - 3 = ``, CPU time in seconds = ``",  
                  n, m, Dimensions[FareyFibonacci], Dimensions[GrandSet], TimeUsed[%] ]]