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.

Previous Showing 11-14 of 14 results.

A153726 Initial digit of Catalan number A000108(n).

Original entry on oeis.org

1, 1, 2, 5, 1, 4, 1, 4, 1, 4, 1, 5, 2, 7, 2, 9, 3, 1, 4, 1, 6, 2, 9, 3, 1, 4, 1, 6, 2, 1, 3, 1, 5, 2, 8, 3, 1, 4, 1, 6, 2, 1, 3, 1, 5, 2, 8, 3, 1, 5, 1, 7, 2, 1, 4, 1, 6, 2, 1, 4, 1, 6, 2, 9, 3, 1, 5, 2, 8, 3, 1, 5, 2, 7, 3, 1, 4, 1, 7, 2, 1, 4, 1, 6, 2, 1
Offset: 0

Views

Author

Omar E. Pol, Dec 30 2008

Keywords

Crossrefs

Programs

  • Mathematica
    First[IntegerDigits[#]]&/@CatalanNumber[Range[0,120]] (* Harvey P. Dale, Jan 20 2014 *)

Formula

a(n)=A000030(A000108(n)).

Extensions

More terms from Harvey P. Dale, Jan 20 2014

A077649 Initial digit of composite numbers.

Original entry on oeis.org

4, 6, 8, 9, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Labos Elemer, Nov 19 2002

Keywords

Crossrefs

Programs

  • Mathematica
    c[x_] := FixedPoint[x+PrimePi[ # ]+1&, x] Table[First[IntegerDigits[c[w]]], {w, 1, 128}]
    First[IntegerDigits[#]]&/@Complement[Range[150],Prime[Range[ PrimePi[150]]]]  (* Harvey P. Dale, Apr 26 2011 *)
  • PARI
    lista(nn) = forcomposite(n=1, nn, print1(digits(n)[1], ", ")); \\ Michel Marcus, Dec 13 2017

Formula

a(n) = A000030(A002808(n)).

A093337 Penultimate digits of the primes.

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 3, 3, 4, 4, 4, 5, 5, 6, 6, 7, 7, 7, 8, 8, 9, 0, 0, 0, 0, 1, 2, 3, 3, 3, 4, 5, 5, 6, 6, 7, 7, 8, 9, 9, 9, 9, 1, 2, 2, 2, 3, 3, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 0, 1, 1, 1, 3, 3, 4, 4, 5, 5, 6, 7, 7, 8, 8, 9, 0, 0, 1, 2, 3, 3, 3, 4, 4, 5, 6, 6, 6, 7, 8, 9, 9, 0, 0, 2, 2, 4, 4, 5, 6, 6, 7, 7, 8, 9, 9
Offset: 11

Views

Author

Cino Hilliard, Apr 25 2004

Keywords

Crossrefs

Programs

  • Magma
    [Intseq(p)[2]: p in PrimesInInterval(11,600)]; // Bruno Berselli, Feb 14 2013
  • Mathematica
    IntegerDigits[#][[-2]]&/@Prime[Range[5,110]] (* Harvey P. Dale, Apr 08 2019 *)
  • PARI
    penult(n) = { forprime(x=11,n, s = Str(x); ln = length(s); pu = mid(s,ln-1,1); print1(pu",") ) } \ Get a substring of length n from string str starting at position s in str. mid(str,s,n) = { v =""; tmp = Vec(str); ln=length(tmp); for(x=s,s+n-1, v=concat(v,tmp[x]); ); return(v) }
    

A093338 Scan primes, write down initial digit if it is a prime.

Original entry on oeis.org

2, 3, 5, 7, 2, 2, 3, 3, 5, 5, 7, 7, 7, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2
Offset: 2

Views

Author

Cino Hilliard, Apr 25 2004

Keywords

Crossrefs

Cf. A077648.

Programs

  • PARI
    firstpr(n) = { forprime(x=2,n, fd = eval(mid(Str(x),1,1)); if(isprime(fd),print1(fd",")) ) } \ Get a substring of length n from string str starting at position s in str. mid(str,s,n) = { v =""; tmp = Vec(str); ln=length(tmp); for(x=s,s+n-1, v=concat(v,tmp[x]); ); return(v) }
Previous Showing 11-14 of 14 results.