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-20 of 42 results. Next

A277835 Number of '5' digits in the set of all numbers from 0 to A014824(n) = Sum_{i=1..n} i*10^(n-i) = (0, 1, 12, 123, 1234, 12345, ...).

Original entry on oeis.org

0, 0, 1, 22, 343, 4665, 58993, 713385, 8368417, 96029849, 1083755281, 12072120713, 133066886145, 1454125651577, 15775824417009, 170103923182448, 1824496021947951, 19479528120714094, 207140960219486637, 2194866392318323180, 23183231824417799723
Offset: 0

Views

Author

M. F. Hasler, Nov 01 2016

Keywords

Examples

			For n = 2 there is only one digit '5' in the sequence 0, 1, 2, ..., 12.
For n = 3 there are 11 + 10 = 21 more digits '5' in { 15, 25, ..., 45, 50, ..., 59, 65, ..., 115 }, where 55 accounts for two '5's.
		

Crossrefs

Programs

  • PARI
    print1(c=N=0);for(n=1,8,print1(","c+=sum(k=N+1,N=N*10+n,#select(d->d==5,digits(k)))))
    
  • PARI
    A277835(n,m=5)=if(n>m,A277835(n,m+1)+(m+2)*10^(n-m-1),A277830(n)-(m>n)) \\ M. F. Hasler, Nov 02 2016

Formula

a(n) = A277849(n) = A083449(n) = A277830(n) - 1 for n < 5,
a(5) = A277836(5) + 1, a(n) = A277836(n) + 7*10^(n-6) for n >= 6.
More generally, for m = 0, ..., 9, let a[m] denote A277830, ..., A277838 and A277849, respectively. Then a[0](n) = a[n](n) = a[m](n) + 1 for all m > n >= 0, and a[m-1](n) = a[m](n) + (m+1)*10^(n-m) for all n >= m > 1.

Extensions

More terms from Lars Blomberg, Nov 05 2016
Removed incorrect b-file. - David A. Corneth, Dec 31 2020

A277836 Number of '6' digits in the set of all numbers from 0 to A014824(n) = Sum_{i=1..n} i*10^(n-i) = (0, 1, 12, 123, 1234, 12345, ...).

Original entry on oeis.org

0, 0, 1, 22, 343, 4664, 58986, 713315, 8367717, 96022849, 1083685281, 12071420713, 133059886145, 1454055651577, 15775124417009, 170096923182441, 1824426021947881, 19478828120713394, 207133960219479637, 2194796392318253180, 23182531824417099723
Offset: 0

Views

Author

M. F. Hasler, Nov 01 2016

Keywords

Examples

			For n=2 there is only one digit '6' in the sequence 0, 1, 2, ..., 12.
For n=3 there are 11 + 10 = 21 more digits '6' in { 16, 26, ..., 56, 60, ..., 69, 76, 86, ..., 116 }, where 66 accounts for two '6's.
		

Crossrefs

Programs

  • Mathematica
    T[int_Integer, {bndsLow_Integer, bndsUpp_Integer}] := Table[
       Count[
        Flatten[Table[
          IntegerDigits[m],
          {m, 1, Sum[
             10^i - 1,
             {i, n}
             ]/9
           }
          ]],
        int
        ],
       {n, bndsLow, bndsUpp}
       ];
    T[6, {0, 7}](* Robert P. P. McKone, Jan 01 2021 *)
  • PARI
    print1(c=N=0);for(n=1,8,print1(","c+=sum(k=N+1,N=N*10+n,#select(d->d==6,digits(k)))))
    
  • PARI
    A277836(n,m=6)=if(n>m,A277836(n,m+1)+(m+2)*10^(n-m-1),A277830(n)-(m>n)) \\ M. F. Hasler, Nov 02 2016

Formula

a(n) = A277839(n) = A083449(n) = A277830(n) - 1 for n < 6,
a(n) = A277835(n) - 7*10^(n-6) for n >= 6,
a(n) = A277837(n) + 8*10^(n-7) for n >= 7.

Extensions

More terms from Lars Blomberg, Nov 05 2016
Removed incorrect b-file. - David A. Corneth, Dec 31 2020

A277834 Number of '4' digits in the set of all numbers from 0 to A014824(n) = Sum_{i=1..n} i*10^(n-i) = (0, 1, 12, 123, 1234, 12345, ...).

Original entry on oeis.org

0, 0, 1, 22, 344, 4671, 59053, 713985, 8374417, 96089849, 1084355281, 12078120713, 133126886145, 1454725651577, 15781824417015, 170163923182508, 1825096021948551, 19485528120720094, 207200960219546637, 2195466392318923180, 23189231824423799723
Offset: 0

Views

Author

M. F. Hasler, Nov 01 2016

Keywords

Examples

			For n=2 there is only one digit '4' in the sequence 0, 1, 2, ..., 12.
For n=3 there are 11 + 10 = 21 more digits '4' in { 14, 24, 34, 40, ..., 49, 54, ..., 114 }, where 44 accounts for two '4's.
		

Crossrefs

Programs

  • PARI
    print1(c=N=0);for(n=1,8,print1(","c+=sum(k=N+1,N=N*10+n,#select(d->d==4,digits(k)))))
    
  • PARI
    A277834(n,m=4)=if(n>m,A277833(n,m+1)+(m+2)*10^(n-m-1),A277830(n)-(m>n))

Formula

a(n) = A277849(n) = A083449(n) = A277830(n) - 1 for n < 4,
a(n) = A277833(n) - 5*10^(n-4) for n >= 4, a(n) = A277835(n) + 6*10^(n-5) for n >= 5.
More generally, for m = 0, ..., 9, let a[m] denote A277830, ..., A277838 and A277849, respectively. Then a[0](n) = a[n](n) = a[m](n) + 1 for all m > n >= 0, and a[m-1](n) = a[m](n) + (m+1)*10^(n-m) for all n >= m > 1.

Extensions

More terms from Lars Blomberg, Nov 05 2016
Removed incorrect b-file. - David A. Corneth, Dec 31 2020

A014822 Numbers k such that k divides s(k), where s(1)=1, s(j)=10*s(j-1)+j (A014824).

Original entry on oeis.org

1, 2, 3, 5, 6, 9, 10, 15, 18, 22, 27, 30, 42, 45, 54, 66, 78, 81, 90, 110, 111, 126, 135, 162, 198, 205, 210, 222, 234, 242, 243, 270, 294, 330, 333, 342, 378, 390, 405, 410, 462, 465, 486, 506, 546, 555, 594, 615, 630, 666, 702, 726, 729, 810, 858, 882, 930
Offset: 1

Views

Author

Keywords

Programs

  • Maple
    s:= proc(n) option remember; 10*procname(n-1)+n end proc: s(1):= 1:
    select(t -> s(t) mod t = 0, [$1..10000]); # Robert Israel, Feb 28 2025
  • Mathematica
    Transpose[Select[NestList[{#[[1]]+1,10#[[2]]+#[[1]]+1}&,{1,1},1000],Divisible[ #[[2]],#[[1]]]&]][[1]] (* Harvey P. Dale, Sep 24 2012 *)

A095761 a(n) = A014824(2*n-1).

Original entry on oeis.org

1, 123, 12345, 1234567, 123456789, 12345679011, 1234567901233, 123456790123455, 12345679012345677, 1234567901234567899, 123456790123456790121, 12345679012345679012343
Offset: 1

Views

Author

Michael Joseph Halm, Jul 10 2004

Keywords

Comments

Previous name was: Numbers whose square root shows strings of seemingly rational and irrational strings.

Crossrefs

Cf. A014824.

Programs

  • GAP
    a:=[1];; for n in [2..20] do a[n]:=100*a[n-1]+22*n-21; od; a; # Muniru A Asiru, Mar 30 2018
    
  • Magma
    [-19/81-(2/9)*(n-1)+(100/81)*100^(n-1): n in [1..20]]; // Vincenzo Librandi, Apr 03 2018
  • Mathematica
    RecurrenceTable[{a[1]==1, a[n]==100 a[n-1] + 22 n - 21}, a, {n, 20}] (* Vincenzo Librandi, Apr 03 2018 *)
  • PARI
    a=vector(10^3); a[1]=1; for(n=2, #a, a[n]=100*a[n-1]+22*n-21); a \\ Altug Alkan, Mar 30 2018
    

Formula

a(1) = 1; for n > 1, a(n) = 100*a(n - 1) + 22*n - 21.
O.g.f.: x(1+21x)/((-1+x)^2*(1-100x)) = -17/(81(-1+x)) - 1/(81(-1+100*x)) - 2/(9(-1+x)^2). - R. J. Mathar, Feb 01 2008

Extensions

Better name from Georg Fischer, Mar 30 2018

A179477 Antonym of A014824: each term is 10 times the previous term minus n.

Original entry on oeis.org

10, 99, 988, 9877, 98766, 987655, 9876544, 98765433, 987654322, 9876543211, 98765432100, 987654320989, 9876543209878, 98765432098767, 987654320987656, 9876543209876545, 98765432098765434, 987654320987654323, 9876543209876543212, 98765432098765432101
Offset: 0

Views

Author

Mark Dols, Jul 16 2010

Keywords

Crossrefs

Cf. A014824.

Programs

  • Mathematica
    Join[{a=10,b=99},Table[c=11*b-10*a-1;a=b;b=c,{n,60}]] (* Vladimir Joseph Stephan Orlovsky, Jan 20 2011*)
    Join[{a=10}, Table[a=10a-n, {n,60}]] (* T. D. Noe, Jan 20 2011 *)
  • PARI
    Vec(-(10*x^2-21*x+10)/((x-1)^2*(10*x-1)) + O(x^30)) \\ Colin Barker, Oct 03 2015

Formula

a(n) + A014824(n) = 10^(n+1).
From Colin Barker, Oct 03 2015: (Start)
a(n) = 12*a(n-1) - 21*a(n-2) + 10*a(n-3) for n>2.
G.f.: -(10*x^2-21*x+10) / ((x-1)^2*(10*x-1)). (End)
a(n) = (10 + 2^(5+n)*5^(2+n) + 9*n)/81. - Colin Barker, Mar 25 2017

A083449 a(n) = A019566(n)/9, where A019566(n) = concat(n,...,1) - concat(1,...,n).

Original entry on oeis.org

0, 1, 22, 343, 4664, 58985, 713306, 8367627, 96021948, -150891621, -13731137410, -260644605199, 86159119727012, 19839246664059223, 3106259112208391434, 422859356777752723645, 53509280234443297055856, 6473262479112108841388067, 759559693477989774385720278
Offset: 1

Views

Author

Amarnath Murthy and Meenakshi Srikanth (menakan_s(AT)yahoo.com), May 01 2003

Keywords

Comments

Are there any palindromes > 58985?
This sequence also gives the number of occurrences of any digit d > n (thus n < 9) in the list of all numbers from 1 to concatenation(1,...,n) = A007908(n) = A014824(n) = sum_{i=1..n} i*10^(n-i). See A277849, A061217, A277830 etc. - M. F. Hasler, Nov 01 2016, edited Nov 07 2020

Crossrefs

Cf. A061217.

Programs

  • Maple
    a:= n-> (parse(cat((n+1-i)$i=1..n))-parse(cat($1..n)))/9:
    seq(a(n), n=1..20);  # Alois P. Heinz, Nov 09 2020
  • Mathematica
    Array[(FromDigits@ Apply[Join, Reverse@ #] - FromDigits@ Apply[Join, #])/9 &@ Map[IntegerDigits, Range[#]] &, 19] (* Michael De Vlieger, Nov 12 2020 *)
  • PARI
    apply( {A083449(n)=A019566(n)\9}, [1..20]) \\ - M. F. Hasler, Nov 07 2020

Formula

For n < 10, a(n) = ceiling((9*n-11)*(10^n+1)/729). - M. F. Hasler, Nov 07 2020

Extensions

More terms from David Wasserman, Nov 09 2004

A057137 Concatenate next digit at right hand end (where the next digit after 9 is again 0).

Original entry on oeis.org

0, 1, 12, 123, 1234, 12345, 123456, 1234567, 12345678, 123456789, 1234567890, 12345678901, 123456789012, 1234567890123, 12345678901234, 123456789012345, 1234567890123456, 12345678901234567, 123456789012345678, 1234567890123456789, 12345678901234567890, 123456789012345678901
Offset: 0

Views

Author

Henry Bottomley, Aug 12 2000

Keywords

Comments

Also called the triangle of the gods (see Pickover link).
See A037610 for a general formula. - Hieronymus Fischer, Jan 03 2013

References

  • Clifford A. Pickover, A Passion for Mathematics, Wiley, 2005; see p. 61.

Crossrefs

Alternative progression for n >= 10 compared with A007908 and A014824.
Cf. A057138 for reverse. Cf. A010879 (decimal digits).
For primes see A120819.

Programs

Formula

a(n) = 10*(a(n-1)-floor[n/10]) + n = floor[A057139(n)/10^(n-1)].
a(n) = floor((137174210/1111111111)*10^n). - Hieronymus Fischer, Jan 03 2013, corrected by M. F. Hasler, Jan 13 2013

A057932 a(n) = floor(10^(n+1)/81).

Original entry on oeis.org

0, 1, 12, 123, 1234, 12345, 123456, 1234567, 12345679, 123456790, 1234567901, 12345679012, 123456790123, 1234567901234, 12345679012345, 123456790123456, 1234567901234567, 12345679012345679, 123456790123456790, 1234567901234567901, 12345679012345679012, 123456790123456790123
Offset: 0

Views

Author

Henry Bottomley, Oct 04 2000

Keywords

Crossrefs

Programs

A277635 Number of 7's appearing in the sequence of consecutive natural numbers from 1 to A007908(n), where A007908 = (1, 12, 123, 1234, ...).

Original entry on oeis.org

0, 1, 22, 343, 4664, 58985, 713307, 8367637, 96022049
Offset: 1

Views

Author

Keywords

Comments

First 6 terms are the same as in A083449, also see A272525. [See the OEIS wiki page for more details. - M. F. Hasler, Dec 29 2020]
a(n) gives the number of times the digit 7 occurs in all terms of A000027 in the interval [A000027(1), A007908(n)]. - Felix Fröhlich, Oct 28 2016
The sequence was initially defined only up to n = 9 and then extended using A007908 = concat(1..n); see A277837 for the extension using A014824 (a(n) = 10 a(n-1) + n) leading to a smoother growth, in particular at powers of 10. - M. F. Hasler, Nov 01 2016, edited Dec 29 2020

Examples

			22 is the third term of the sequence because there are 22 occurrences of the digit '7' contained in numbers within the range of 1 to 123.
96022049 is the 9th term of the sequence because there are 96022049 occurrences of the digit '7' contained in numbers within the range of 1 to 123456789.
		

Crossrefs

Cf. A277830 - A277838 and A277849: analog for digits 0 .. 9, but based on A014824 instead of A083449.

Programs

  • Mathematica
    Table[a[n] = Count[Flatten@ Map[IntegerDigits, Range@ FromDigits@ Range@ n], k_ /; k == 8]; Print@ a@ n; an = a[n]; an, {n, 0, 9}] (* Michael De Vlieger, Oct 30 2016 *)
  • PARI
    print1(c=0);N=1;for(n=2,8,print1(","c+=sum(k=N+1,N=eval(Str(N,n)),#select(d->d==7,digits(k))))) \\ For illustration; more efficient code below. - M. F. Hasler, Oct 31 2016
    
  • PARI
    A277635(n, m=7)=if(n>m,A277635(n, m+1)+(m+2)*10^(n-m-1),A277830(n)-(m>n)) \\ Valid only for n <= 9. - M. F. Hasler, Nov 02 2016
Previous Showing 11-20 of 42 results. Next