cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-5 of 5 results.

A020344 Fibonacci(a(n)) is the least Fibonacci number beginning with n.

Original entry on oeis.org

0, 1, 3, 4, 19, 5, 15, 25, 6, 16, 21, 45, 26, 7, 12, 17, 41, 22, 46, 27, 51, 8, 56, 13, 37, 18, 42, 66, 23, 47, 71, 28, 52, 119, 9, 33, 57, 14, 148, 38, 62, 19, 86, 43, 67, 134, 24, 225, 48, 72, 139, 29, 230, 53, 254, 10, 278, 34, 302, 58, 259, 15, 283, 39, 240, 63, 197, 20, 154, 288
Offset: 0

Views

Author

Keywords

Comments

Fixed points of this sequence are in A038546. - Alois P. Heinz, Jul 08 2022

Crossrefs

Programs

  • Mathematica
    nn = 100; t = tn = Table[0, {nn}]; found = 0; n = 0; While[found < nn, n++; f = Fibonacci[n]; d = IntegerDigits[f]; i = 1; While[i <= Length[d], k = FromDigits[Take[d, i]]; If[k > nn, Break[]]; If[t[[k]] == 0, t[[k]] = f; tn[[k]] = n; found++]; i++]]; tn = Join[{0}, tn] (* T. D. Noe, Apr 02 2014 *)
  • Python
    def aupton(nn):
        ans, f, g, k = dict(), 0, 1, 0
        while len(ans) < nn+1:
            sf = str(f)
            for i in range(1, len(sf)+1):
                if int(sf[:i]) > nn:
                    break
                if sf[:i] not in ans:
                    ans[sf[:i]] = k
            f, g, k = g, f+g, k+1
        return [int(ans[str(i)]) for i in range(nn+1)]
    print(aupton(70)) # Michael S. Branicky, Jul 08 2022

Formula

A000045(a(n)) = A020345(n).

A020345 Smallest Fibonacci number beginning with n.

Original entry on oeis.org

0, 1, 2, 3, 4181, 5, 610, 75025, 8, 987, 10946, 1134903170, 121393, 13, 144, 1597, 165580141, 17711, 1836311903, 196418, 20365011074, 21, 225851433717, 233, 24157817, 2584, 267914296, 27777890035288, 28657, 2971215073, 308061521170129, 317811
Offset: 0

Views

Author

Keywords

Comments

The graph of the indices A020344 is much more interesting. - T. D. Noe, Apr 02 2014
a(1382) is the first term with > 1000 digits (1004). - Michael S. Branicky, Jul 08 2022

Examples

			a(4) = 4181 is a Fibonacci number starting with 4.
		

Crossrefs

Programs

  • Mathematica
    nn = 31; t = tn = Table[0, {nn}]; found = 0; n = 0; While[found < nn, n++;  f = Fibonacci[n]; d = IntegerDigits[f]; i = 1; While[i <= Length[d], k = FromDigits[Take[d, i]]; If[k > nn, Break[]]; If[t[[k]] == 0, t[[k]] = f; tn[[k]] = n; found++]; i++]]; t = Join[{0}, t] (* T. D. Noe, Apr 02 2014 *)
  • Python
    def aupton(nn):
        ans, f, g, k = dict(), 0, 1, 0
        while len(ans) < nn+1:
            sf = str(f)
            for i in range(1, len(sf)+1):
                if int(sf[:i]) > nn:
                    break
                if sf[:i] not in ans:
                    ans[sf[:i]] = f
            f, g, k = g, f+g, k+1
        return [int(ans[str(i)]) for i in range(nn+1)]
    print(aupton(31)) # Michael S. Branicky, Jul 08 2022

Formula

a(n) = A000045(A020344(n)).

A079185 Number of isomorphism classes of commutative closed binary operations (groupoids) on a set of order n, listed by class size.

Original entry on oeis.org

1, 0, 4, 1, 4, 8, 116, 0, 0, 0, 8, 0, 28, 504, 43428
Offset: 1

Views

Author

Christian van den Bosch (cjb(AT)cjb.ie), Jan 03 2003

Keywords

Comments

Elements per row: 1,2,4,8,16,30,... (given by A027423, number of positive divisors of n!)
First four rows: 1; 0,4; 1,4,8,116; 0,0,0,8,0,28,504,43428
A079176(x) is equal to the sum of the products of each element in row x of this sequence and the corresponding element of A079210.
The sum of each row n is given by A079177(n).

Crossrefs

Cf. A001425, A023183, A079184. a(n, A027423(n)) = A030255(n).

A374026 a(n) = the smallest k such that Fibonacci(k) begins and ends with n, where Fibonacci(k) > n, or -1 if there are none.

Original entry on oeis.org

22, 114, 124, 72, 10, 39, 116, 207, 169, 5715, 2428, 5634, 2366, 189, 2620, 4668, 3137, 2673, 5812, 12090, 721, 11583, 20086, 3798, 1975, 999, 10636, 846, 2071, 9105, 1162, 2076, 8287, 11091, 2770, 2928, 12943, 8493, 172, 2220, 5359, 4737, 28126, 11838, 10460, 7479, 10996
Offset: 1

Views

Author

Gonzalo Martínez, Jun 26 2024

Keywords

Comments

Since the smallest number beginning and ending with n is the same n, the condition that Fibonacci(k) > n is imposed. Partial overlap of the start and end is allowed, but not full overlap.

Examples

			As Fibonacci(22) = 17711 is the smallest Fibonacci number greater than 1 that begins and ends with 1, a(1) = 22.
As Fibonacci(10) = 55 is the smallest Fibonacci number greater than 5 that begins and ends with 5, a(5) = 10.
		

Crossrefs

Programs

  • PARI
    isok(s,t) = my(ss=strsplit(s, t)); (#ss >= 3) && (ss[1]=="") && (ss[#ss]=="");
    a(n) = my(k=7); while(!isok(Str(fibonacci(k)), Str(n)), k++); k; \\ Michel Marcus, Jun 26 2024
    
  • Python
    # uses A023183() in A023183
    from itertools import count
    def a(n):
        if A023183(n) == -1:
            return -1
        f, g, s = 1, 2, str(n)
        pow10 = 10**len(s)
        for k in count(3):
            if g%pow10 == n:
                sfib = str(g)
                if g > n and sfib.startswith(s):
                    return k
            f, g = g, f+g
    print([a(n) for n in range(1, 51)]) # Michael S. Branicky, Jul 03 2024

Formula

a(n) >= max{A023183(n), A020344(n)} except that a(n) = -1 when A023183(n) = -1. - Michael S. Branicky, Jun 27 2024

Extensions

More terms from Michel Marcus, Jun 26 2024

A245456 Index of least Fibonacci number congruent to n mod 100.

Original entry on oeis.org

0, 1, 3, 4, 192, 5, 81, 76, 6, 32, 15, 22, 216, 7, 111, 130, 168, 37, 27, 112, 60, 8, 117, 64, 198, 25, 99, 136, 204, 29, 105, 88, 174, 13, 9, 70, 222, 43, 93, 172, 30, 41, 63, 124, 12, 55, 21, 154, 186, 49, 75, 148, 36, 67, 129, 10, 162, 23, 87, 118, 180, 61, 57, 166, 72, 20, 141, 94, 24, 31, 45, 142, 54, 47, 51, 100, 48, 14, 33, 58, 210, 19, 123, 106, 18, 80, 39, 16, 66, 11, 135, 82, 156, 26, 69, 160, 42, 17, 147, 52
Offset: 0

Views

Author

Keywords

Comments

The analogous sequence mod 1000 does not exist, because no Fibonacci number is congruent to, e.g., 4 mod 1000.

Examples

			a(4) = 192 because F(192) = 5972304273877744135569338397692020533504 is 4 mod 100.
		

Crossrefs

Cf. A023183.

Programs

Showing 1-5 of 5 results.