login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A191774 Lim f(f(...f(n)...)) where f(n) is the Farey fractal sequence, A131967. 5
1, 2, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 2, 1, 2, 2, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

Suppose that f(1), f(2), f(3),... is a fractal sequence (a sequence which contains itself as a proper subsequence, such as 1, 2, 1, 2, 3, 1, 2, 3, 4, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 6, ...; if the first occurrence of each n is deleted, the remaining sequence is identical to the original; see the Wikipedia article for a rigorous definition).  Then for each n>=1, the limit L(n) of composites f(f(f...f(n)...)) exists and is one of the numbers in the set {k : f(k)=k}.  Thus, if f(2)>2, then L(n)=1 for all n; if f(2)=2 and f(3)>3, then L(n) is 1 or 2 for all n.  Examples:  A020903, A191770, A191774

LINKS

Table of n, a(n) for n=1..86.

Wikipedia, Fractal sequence

EXAMPLE

Write the counting numbers and A131967 like this:

1..2..3..4..5..6..7..8..9..10..11..12..13..14..15..

1..2..1..3..2..1..4..3..5..2...1...6...4...3...5...

It is then easy to check composites:

1->1, 2->2, 3->1, 4->3->1, 5->2, 6->1, 7->4->3->1,...

MATHEMATICA

Farey[n_] := Select[Union@Flatten@Outer[Divide, Range[n + 1] - 1, Range[n]], # <= 1 &];

newpos[n_] := Module[{length = Total@Array[EulerPhi, n] + 1, f1 = Farey[n], f2 = Farey[n - 1], to},

   to = Complement[Range[length], Flatten[Position[f1, #] & /@ f2]];

   ReplacePart[Array[0 &, length],

    Inner[Rule, to, Range[length - Length[to] + 1, length], List]]];

a[n_] := Flatten@Table[Fold[ReplacePart[Array[newpos, i][[#2 + 1]], Inner[Rule, Flatten@Position[Array[newpos, i][[#2 + 1]], 0], #1, List]] &, Array[newpos, i][[1]], Range[i - 1]], {i, n}];

t = a[12]; f[n_] := Part[t, n];

Table[f[n], {n, 1, 100}]          (* A131967 *)

h[n_] := Nest[f, n, 50]

t = Table[h[n], {n, 1, 200}]      (* A191774 *)

s = Flatten[Position[t, 1]]       (* A191775 *)

s = Flatten[Position[t, 2]]       (* A191776 *)

CROSSREFS

Cf. A020903, A191770, A191775, A191776.

Sequence in context: A235757 A020906 A220280 * A262885 A097305 A120675

Adjacent sequences:  A191771 A191772 A191773 * A191775 A191776 A191777

KEYWORD

nonn

AUTHOR

Clark Kimberling, Jun 16 2011

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified January 20 10:55 EST 2022. Contains 350472 sequences. (Running on oeis4.)