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-3 of 3 results.

A078427 Sum of all the decimal digits of numbers from 1 to 10^n.

Original entry on oeis.org

46, 901, 13501, 180001, 2250001, 27000001, 315000001, 3600000001, 40500000001, 450000000001, 4950000000001, 54000000000001, 585000000000001, 6300000000000001, 67500000000000001, 720000000000000001, 7650000000000000001, 81000000000000000001
Offset: 1

Views

Author

Shyam Sunder Gupta, Dec 29 2002

Keywords

Examples

			a(2)=901 because sum of all the digits of numbers from 1 to 10^2 is 901.
		

References

  • E. J. Barbeau et al., Five Hundred Mathematical Challenges, Problem 284. pp. 25; 142-143, MAA Washington DC, 1995.

Crossrefs

Programs

  • Magma
    [(45*n)*10^(n-1)+1: n in [1..30]]; // Vincenzo Librandi, Jun 06 2011
    
  • Mathematica
    LinearRecurrence[{21,-120,100},{46,901,13501},20] (* Harvey P. Dale, Nov 24 2016 *)
  • PARI
    Vec(-x*(100*x^2-65*x+46)/((x-1)*(10*x-1)^2) + O(x^100)) \\ Colin Barker, May 23 2014

Formula

a(n) = (45*n)*10^(n-1)+1.
a(n) = 45*A053541(n)+1. - Lekraj Beedassy, Sep 16 2006
a(n) = 21*a(n-1)-120*a(n-2)+100*a(n-3). - Colin Barker, May 23 2014
G.f.: -x*(100*x^2-65*x+46) / ((x-1)*(10*x-1)^2). - Colin Barker, May 23 2014

Extensions

Edited by Charles R Greathouse IV, Aug 02 2010
More terms from Colin Barker, May 23 2014

A229186 Beginning position of n in the decimal expansion of the Champernowne constant.

Original entry on oeis.org

11, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 1, 16, 18, 20, 22, 24, 26, 28, 30, 15, 34, 2, 38, 40, 42, 44, 46, 48, 50, 17, 37, 56, 3, 60, 62, 64, 66, 68, 70, 19, 39, 59, 78, 4, 82, 84, 86, 88, 90, 21, 41, 61, 81, 100, 5, 104, 106, 108, 110, 23
Offset: 0

Views

Author

Eric W. Weisstein, Sep 15 2013

Keywords

Comments

Ignoring the initial 0 to the left of the decimal point.
Same as A031297 but including the a(0) term.

Crossrefs

Cf. A033307 (decimal expansion of the Champernowne constant).
Cf. A072290 (number of digits in the decimal expansion of the Champernowne constant that must be scanned to encounter all n-digit strings).
Cf. A031297 (same sequence but omitting the a(0) term).

Programs

  • Python
    from itertools import count, islice
    def agen():
        k, chap = 1, ".1"
        for n in count(0):
            target = str(n)
            while chap.find(target) == -1: k += 1; chap += str(k)
            yield chap.find(target)
    print(list(islice(agen(), 70))) # Michael S. Branicky, Oct 06 2022

A094797 Number of times 1 is used in writing out all numbers 1 through 10^n.

Original entry on oeis.org

1, 2, 21, 301, 4001, 50001, 600001, 7000001, 80000001, 900000001, 10000000001, 110000000001, 1200000000001, 13000000000001, 140000000000001, 1500000000000001, 16000000000000001, 170000000000000001, 1800000000000000001, 19000000000000000001
Offset: 0

Views

Author

Lekraj Beedassy, Jun 11 2004

Keywords

Crossrefs

Programs

  • Mathematica
    Table[ n*10^(n - 1) + 1, {n, 0, 17}] (* Robert G. Wilson v, Jun 15 2004 *)
    LinearRecurrence[{21,-120,100},{1,2,21},20] (* Harvey P. Dale, Sep 07 2022 *)
  • PARI
    Vec(-(99*x^2-19*x+1)/((x-1)*(10*x-1)^2) + O(x^100)) \\ Colin Barker, May 23 2014

Formula

a(n) = n*10^(n-1) + 1.
a(n) = 21*a(n-1)-120*a(n-2)+100*a(n-3). - Colin Barker, May 23 2014
G.f.: -(99*x^2-19*x+1) / ((x-1)*(10*x-1)^2). - Colin Barker, May 23 2014
a(n) = A094798(A011557(n)). - Michel Marcus, Oct 03 2023

Extensions

More terms from Robert G. Wilson v, Jun 15 2004
Further terms from Colin Barker, May 23 2014
Showing 1-3 of 3 results.