login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A292031
a(n) is the smallest value m such that n appears in row m of A292030.
4
0, 0, 0, 0, 3, 0, 5, 3, 0, 4, 9, 3, 11, 0, 4, 7, 15, 5, 3, 9, 6, 0, 21, 4, 23, 12, 8, 13, 5, 3, 29, 15, 10, 6, 0, 11, 35, 4, 7, 19, 39, 13, 41, 8, 14, 5, 45, 3, 9, 24, 16, 25, 51, 6, 53, 0, 18, 28, 11, 19, 4, 7, 20, 12, 63, 21, 65, 33, 13, 8, 69, 23, 71, 5, 24, 37, 3, 9, 15, 39, 26
OFFSET
0,5
COMMENTS
a(n) = 0 if and only if n is a member of A000045.
a(n) is never 1 nor 2 since row 1 and 2 are equal to row 0 with a shift. - Michel Marcus, Sep 27 2017, amended by M. F. Hasler, Feb 26 2018
EXAMPLE
a(3)=0 since A292030(0,5) = 3.
a(7)=3 since A292030(3,2) = 7.
PROG
(Python)
def smallestSeq(n):
if(n<0): return []
if(n==0): return [0, 0]
j, r0, r1=0, 0, 1
while(r1<=n): r0, r1=r1, r0+r1 ; j+=1
while(r1>1):
if(n%r1==r0): return [n//r1, j]
r1, r0=r0, r1-r0
j-=1
return [n-1, j]
for i in range(10001):
print(str(i)+" "+str(smallestSeq(i)[0]))
CROSSREFS
Cf. A292030.
Sequence in context: A011293 A181884 A284662 * A201565 A088191 A378034
KEYWORD
nonn
AUTHOR
Ely Golden, Sep 08 2017
STATUS
approved