login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A254608 a(n) is the smallest number such that A254606(a(n)) = n. 1
1, 2, 9, 14, 27, 26, 34, 63, 64, 53, 89, 115, 88, 165, 101, 116, 132, 292, 149, 185, 166, 225, 271, 205, 270, 318, 247, 397, 294, 293, 319, 370, 371, 344, 399, 398, 427, 691, 489, 488, 553, 552, 520, 655, 658, 620, 622, 769, 621, 693, 656, 731, 851, 810, 732 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

LINKS

Lei Zhou, Table of n, a(n) for n = 0..10000

EXAMPLE

A254606(1)=0, so a(0)=1;

A254606(2)=1, so a(1)=2;

A254606(m)<2 for all m<9, and A254606(9)=2, so a(2)=9.

MATHEMATICA

NumDiff[n1_, n2_] :=  Module[{c1 = n1, c2 = n2}, If[c1 < c2, c1 = c1 + c2; c2 = c1 - c2; c1 = c1 - c2];

  k = Floor[c1/c2]; a1 = c1 - k*c2; If[a1 == 0, a2 = 0, a2 = (k + 1) c2 - c1]; Return[Min[a1, a2]]];

a = {1}; n = 0; p1 = 2; p2 = 1; lb = 0; While[lb < 100, n++; p2 = NextPrime[p2]; If[p2 > p1, p1 = p2; p2 = 2];

d = NumDiff[p1, p2]; While[l = Length[a]; l <= d, AppendTo[a, 0]]; If[a[[d + 1]] == 0, a[[d + 1]] = n; ps = Position[a, 0]; If[Length[ps] == 0, b = a, ps1 = ps[[1]][[1]]; b = Take[a, ps1 - 1]]; lb = Length[b]]]; b

CROSSREFS

Cf. A254606.

Sequence in context: A242466 A071344 A224855 * A324275 A106360 A024470

Adjacent sequences:  A254605 A254606 A254607 * A254609 A254610 A254611

KEYWORD

nonn

AUTHOR

Lei Zhou, Feb 02 2015

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 April 18 02:38 EDT 2021. Contains 343072 sequences. (Running on oeis4.)