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 171 results. Next

A002275 Repunits: (10^n - 1)/9. Often denoted by R_n.

Original entry on oeis.org

0, 1, 11, 111, 1111, 11111, 111111, 1111111, 11111111, 111111111, 1111111111, 11111111111, 111111111111, 1111111111111, 11111111111111, 111111111111111, 1111111111111111, 11111111111111111, 111111111111111111, 1111111111111111111, 11111111111111111111
Offset: 0

Views

Author

Keywords

Comments

R_n is a string of n 1's.
Base-4 representation of Jacobsthal bisection sequence A002450. E.g., a(4)= 1111 because A002450(4)= 85 (in base 10) = 64 + 16 + 4 + 1 = 1*(4^3) + 1*(4^2) + 1*(4^1) + 1. - Paul Barry, Mar 12 2004
Except for the first two terms, these numbers cannot be perfect squares, because x^2 != 11 (mod 100). - Zak Seidov, Dec 05 2008
For n >= 0: a(n) = (A000225(n) written in base 2). - Jaroslav Krizek, Jul 27 2009, edited by M. F. Hasler, Jul 03 2020
Let A be the Hessenberg matrix of order n, defined by: A[1,j]=1, A[i,i]:=10, (i>1), A[i,i-1]=-1, and A[i,j]=0 otherwise. Then, for n>=1, a(n)=det(A). - Milan Janjic, Feb 21 2010
Except 0, 1 and 11, all these integers are Brazilian numbers, A125134. - Bernard Schott, Dec 24 2012
Numbers n such that 11...111 = R_n = (10^n - 1)/9 is prime are in A004023. - Bernard Schott, Dec 24 2012
The terms 0 and 1 are the only squares in this sequence, as a(n) == 3 (mod 4) for n>=2. - Nehul Yadav, Sep 26 2013
For n>=2 the multiplicative order of 10 modulo the a(n) is n. - Robert G. Wilson v, Aug 20 2014
The above is a special case of the statement that the order of z modulo (z^n-1)/(z-1) is n, here for z=10. - Joerg Arndt, Aug 21 2014
From Peter Bala, Sep 20 2015: (Start)
Let d be a divisor of a(n). Let m*d be any multiple of d. Split the decimal expansion of m*d into 2 blocks of contiguous digits a and b, so we have m*d = 10^k*a + b for some k, where 0 <= k < number of decimal digits of m*d. Then d divides a^n - (-b)^n (see McGough). For example, 271 divides a(5) and we find 2^5 + 71^5 = 11*73*271*8291 and 27^5 + 1^5 = 2^2*7*31*61*271 are both divisible by 271. Similarly, 4*271 = 1084 and 10^5 + 84^5 = 2^5*31*47*271*331 while 108^5 + 4^5 = 2^12*7*31*61*271 are again both divisible by 271. (End)
Starting with the second term this sequence is the binary representation of the n-th iteration of the Rule 220 and 252 elementary cellular automaton starting with a single ON (black) cell. - Robert Price, Feb 21 2016
If p > 5 is a prime, then p divides a(p-1). - Thomas Ordowski, Apr 10 2016
0, 1 and 11 are only terms that are of the form x^2 + y^2 + z^2 where x, y, z are integers. In other words, a(n) is a member of A004215 for all n > 2. - Altug Alkan, May 08 2016
Except for the initial terms, the binary representation of the x-axis, from the left edge to the origin, of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 737", based on the 5-celled von Neumann neighborhood, initialized with a single black (ON) cell at stage zero. - Robert Price, Mar 17 2017
The term "repunit" was coined by Albert H. Beiler in 1964. - Amiram Eldar, Nov 13 2020
q-integers for q = 10. - John Keith, Apr 12 2021
Binomial transform of A001019 with leading zero. - Jules Beauchamp, Jan 04 2022

References

  • Albert H. Beiler, Recreations in the Theory of Numbers: The Queen of Mathematics Entertains, New York: Dover Publications, 1964, chapter XI, p. 83.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See pp. 235-237.
  • David Wells, The Penguin Dictionary of Curious and Interesting Numbers, Penguin Books, 1987, pp. 197-198.
  • Samuel Yates, Peculiar Properties of Repunits, J. Recr. Math. 2, 139-146, 1969.
  • Samuel Yates, Prime Divisors of Repunits, J. Recr. Math. 8, 33-38, 1975.

Crossrefs

Programs

  • Haskell
    a002275 = (`div` 9) . subtract 1 . (10 ^)
    a002275_list = iterate ((+ 1) . (* 10)) 0
    -- Reinhard Zumkeller, Jul 05 2013, Feb 05 2012
    
  • Magma
    [(10^n-1)/9: n in [0..25]]; // Vincenzo Librandi, Nov 06 2014
    
  • Maple
    seq((10^k - 1)/9, k=0..30); # Wesley Ivan Hurt, Sep 28 2013
  • Mathematica
    Table[(10^n - 1)/9, {n, 0, 19}] (* Alonso del Arte, Nov 15 2011 *)
    Join[{0},Table[FromDigits[PadRight[{},n,1]],{n,20}]] (* Harvey P. Dale, Mar 04 2012 *)
  • Maxima
    a[0]:0$
    a[1]:1$
    a[n]:=11*a[n-1]-10*a[n-2]$
    A002275(n):=a[n]$
    makelist(A002275(n),n,0,30); /* Martin Ettl, Nov 05 2012 */
    
  • PARI
    a(n)=(10^n-1)/9; \\ Michael B. Porter, Oct 26 2009
    
  • PARI
    my(x='x+O('x^30)); concat(0, Vec(x/((1-10*x)*(1-x)))) \\ Altug Alkan, Apr 10 2016
    
  • Python
    print([(10**n-1)//9 for n in range(100)]) # Michael S. Branicky, Apr 30 2022
  • Sage
    [lucas_number1(n, 11, 10) for n in range(21)]  # Zerinvary Lajos, Apr 27 2009
    

Formula

a(n) = 10*a(n-1) + 1, a(0)=0.
a(n) = A000042(n) for n >= 1.
Second binomial transform of Jacobsthal trisection A001045(3n)/3 (A015565). - Paul Barry, Mar 24 2004
G.f.: x/((1-10*x)*(1-x)). Regarded as base b numbers, g.f. x/((1-b*x)*(1-x)). - Franklin T. Adams-Watters, Jun 15 2006
a(n) = 11*a(n-1) - 10*a(n-2), a(0)=0, a(1)=1. - Lekraj Beedassy, Jun 07 2006
a(n) = A125118(n,9) for n>8. - Reinhard Zumkeller, Nov 21 2006
a(n) = A075412(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
a(n) = a(n-1) + 10^(n-1) with a(0)=0. - Vincenzo Librandi, Jul 22 2010
a(n) = A242614(n,A242622(n)). - Reinhard Zumkeller, Jul 17 2014
E.g.f.: (exp(9*x) - 1)*exp(x)/9. - Ilya Gutkovskiy, May 11 2016
a(n) = Sum_{k=0..n-1} 10^k. - Torlach Rush, Nov 03 2020
Sum_{n>=1} 1/a(n) = A065444. - Amiram Eldar, Nov 13 2020
From Elmo R. Oliveira, Aug 02 2025: (Start)
a(n) = A002283(n)/9 = A105279(n)/10.
a(n) = A010785(A017173(n-1)) for n >= 1. (End)

A002283 a(n) = 10^n - 1.

Original entry on oeis.org

0, 9, 99, 999, 9999, 99999, 999999, 9999999, 99999999, 999999999, 9999999999, 99999999999, 999999999999, 9999999999999, 99999999999999, 999999999999999, 9999999999999999, 99999999999999999, 999999999999999999, 9999999999999999999, 99999999999999999999, 999999999999999999999, 9999999999999999999999
Offset: 0

Views

Author

Keywords

Comments

A friend from Germany remarks that the sequence 9, 99, 999, 9999, 99999, 999999, ... might be called the grumpy German sequence: nein!, nein! nein!, nein! nein! nein!, ...
The Regan link shows that integers of the form 10^n -1 have binary representations with exactly n trailing 1 bits. Also those integers have quinary expressions with exactly n trailing 4's. For example, 10^4 -1 = (304444)5. The first digits in quinary correspond to the number 2^n -1, in our example (30)5 = 2^4 -1. A similar pattern occurs in the binary case. Consider 9 = (1001)2. - Washington Bomfim Dec 23 2010
a(n) is the number of positive integers with less than n+1 digits. - Bui Quang Tuan, Mar 09 2015
From Peter Bala, Sep 27 2015: (Start)
For n >= 1, the simple continued fraction expansion of sqrt(a(2*n)) = [10^n - 1; 1, 2*(10^n - 1), 1, 2*(10^n - 1), ...] has period 2. The simple continued fraction expansion of sqrt(a(2*n))/a(n) = [1; 10^n - 1, 2, 10^n - 1, 2, ...] also has period 2. Note the occurrence of large partial quotients in both expansions.
A theorem of Kuzmin in the measure theory of continued fractions says that large partial quotients are the exception in continued fraction expansions.
Empirically, we also see the presence of unexpectedly large partial quotients early in the continued fraction expansions of the m-th roots of the numbers a(m*n) for m >= 3. Some typical examples are given below. (End)
For n > 0, numbers whose smallest decimal digit is 9. - Stefano Spezia, Nov 16 2023

Examples

			From _Peter Bala_, Sep 27 2015: (Start)
Continued fraction expansions showing large partial quotients:
a(12)^(1/3) = [9999; 1, 299999998, 1, 9998, 1, 449999998, 1, 7998, 1, 535714284, 1, 2, 2, 142, 2, 2, 1, 599999999, 3, 1, 1,...].
Compare with a(30)^(1/3) = [9999999999; 1, 299999999999999999998, 1, 9999999998, 1, 449999999999999999998, 1, 7999999998, 1, 535714285714285714284, 1, 2, 2, 142857142, 2, 2, 1, 599999999999999999999, 3, 1, 1,...].
a(24)^(1/4) = [999999; 1, 3999999999999999998, 1, 666665, 1, 1, 1, 799999999999999999, 3, 476190, 7, 190476190476190476, 21, 43289, 1, 229, 1, 1864801864801863, 1, 4, 6,...].
Compare with a(48)^(1/4) = [999999999999; 1, 3999999999999999999999999999999999998, 1, 666666666665, 1, 1, 1, 799999999999999999999999999999999999, 3, 476190476190, 7, 190476190476190476190476190476190476, 21, 43290043289, 1, 229, 1, 1864801864801864801864801864801863, 1, 4, 6,...].
a(25)^(1/5) = [99999, 1, 499999999999999999998, 1, 49998, 1, 999999999999999999998, 1, 33332, 3, 151515151515151515151, 5, 1, 1, 1947, 1, 1, 38, 3787878787878787878, 1, 3, 5,...].
(End)
		

Crossrefs

Programs

Formula

From Mohammad K. Azarian, Jan 14 2009: (Start)
G.f.: 1/(1-10*x)-1/(1-x).
E.g.f.: e^(10*x)-e^x. (End)
a(n) = A075412(n)/A002275(n) = A178630(n)/A002276(n) = A178631(n)/A002277(n) = A075415(n)/A002278(n) = A178632(n)/A002279(n) = A178633(n)/A002280(n) = A178634(n)/A002281(n) = A178635(n)/A002282(n). - Reinhard Zumkeller, May 31 2010
a(n) = a(n-1) + 9*10^(n-1) with a(0)=0; Also: a(n) = 11*a(n-1) - 10*a(n-2) with a(0)=0, a(1)=9. - Vincenzo Librandi, Jul 22 2010
For n>0, A007953(a(n)) = A008591(n) and A010888(a(n)) = 9. - Reinhard Zumkeller, Aug 06 2010
A048379(a(n)) = 0. - Reinhard Zumkeller, Feb 21 2014
a(n) = Sum_{k=1..n} 9*10^k. - Carauleanu Marc, Sep 03 2016
Sum_{n>=1} 1/a(n) = A073668. - Amiram Eldar, Nov 13 2020
From Elmo R. Oliveira, Jul 19 2025: (Start)
a(n) = 9*A002275(n).
a(n) = A010785(A008591(n)). (End)

Extensions

More terms from Michael De Vlieger, Sep 27 2015

A151949 a(n) = image of n under the Kaprekar map n -> (n with digits sorted into descending order) - (n with digits sorted into ascending order).

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 9, 18, 27, 36, 45, 54, 63, 72, 18, 9, 0, 9, 18, 27, 36, 45, 54, 63, 27, 18, 9, 0, 9, 18, 27, 36, 45, 54, 36, 27, 18, 9, 0, 9, 18, 27, 36, 45, 45, 36, 27, 18, 9, 0, 9, 18, 27, 36, 54, 45, 36, 27, 18, 9, 0, 9, 18, 27, 63, 54, 45, 36, 27, 18, 9, 0, 9, 18, 72, 63, 54, 45, 36, 27, 18, 9, 0, 9, 81, 72, 63, 54, 45, 36, 27, 18, 9, 0, 99, 99, 198, 297, 396, 495, 594, 693, 792, 891, 99, 0, 99, 198, 297, 396, 495, 594, 693, 792
Offset: 0

Views

Author

N. J. A. Sloane, Aug 18 2009

Keywords

Comments

Entries are multiples of 9 - see A151950.
a(n) = A004186(n) - A004185(n); a(A010785(n)) = 0. - Reinhard Zumkeller, corrected: Mar 23 2015, Jul 09 2013

Examples

			For n = 15, a(15) = 51 - 15 = 36. - _Indranil Ghosh_, Feb 01 2017
		

Crossrefs

In other bases: A164884 (base 2), A164993 (base 3), A165012 (base 4), A165032 (base 5), A165051 (base 6), A165071 (base 7), A165090 (base 8), A165110 (base 9). - Joseph Myers, Sep 05 2009
Cf. also A004185, A004186, A099009 (fixed points).

Programs

  • Haskell
    a151949 n = a004186 n - a004185 n
    -- Reinhard Zumkeller, corrected: Mar 23 2015, Jul 09 2013
    
  • Mathematica
    f[n_] := Module[{idn = IntegerDigits@n, idns}, idns = Sort@ idn; FromDigits@ Reverse@ idns - FromDigits@ idns]; Table[ f@n, {n, 0, 200}] (* Harvey P. Dale, Aug 18 2009 *)
    Flatten[Table[Differences[FromDigits /@ {y = Sort[x = IntegerDigits[n]], Reverse[y]}], {n, 0, 74}]] (* Jayanta Basu, Jul 11 2013 *)
  • PARI
    a(n) = {my(d=digits(n)); fromdigits(vecsort(d,,4)) - fromdigits(vecsort(d));} \\ Michel Marcus, Dec 08 2019
  • Python
    def A151949(n):
        return int("".join(sorted(str(n),reverse=True)))-int("".join(sorted(str(n)))) # Indranil Ghosh, Feb 01 2017
    

Extensions

More terms from Robert G. Wilson v, Aug 19 2009
More than the usual number of terms are shown in order to distinguish this from similar sequences. - N. J. A. Sloane, Sep 22 2021

A002277 a(n) = 3*(10^n - 1)/9.

Original entry on oeis.org

0, 3, 33, 333, 3333, 33333, 333333, 3333333, 33333333, 333333333, 3333333333, 33333333333, 333333333333, 3333333333333, 33333333333333, 333333333333333, 3333333333333333, 33333333333333333, 333333333333333333, 3333333333333333333, 33333333333333333333, 333333333333333333333
Offset: 0

Views

Author

Keywords

Comments

From Wolfdieter Lang, Feb 08 2017: (Start)
This sequence (for n >= 1) appears in n-families satisfying so-called curious cubic identities based on the Armstrong numbers 153, 370 and 371, A005188(10) - A005188(12).
153 also involves A246057(n-1) and A093143(n). See a comment in A246057 with the van Poorten et al. reference, and A281857.
370 and 371 also involve A067275(n+1). See the comment there, and A281858 and A281860. (End)

Examples

			From _Wolfdieter Lang_, Feb 08 2017: (Start)
Curious cubic identities (see a comment above):
1^3 + 5^3 + 3^3 = 153, 16^3 + 50^3 + 33^3 = 165033, 166^3 + 500^3 + 333^3 = 166500333, ...
3^3 + 7^3 + 0^3 = 370; 336700 = 33^3 + 67^3 + (00)^3 = 336700,  333^3 + 667^3 + (000)^3 = 333667000, ...
3^3 + 7^3 + 1^3 = 371, 33^3 + 67^3 + (01)^3 = 336701, 333^3 + 667^3 + (001)^3 = 333667001, ... (End)
		

Crossrefs

Programs

Formula

a(n) = 3*A002275(n).
a(n) = A178631(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
From Vincenzo Librandi, Jul 22 2010: (Start)
a(n) = a(n-1) + 3*10^(n-1) with a(0)=0;
a(n) = 11*a(n-1) - 10*a(n-2) with a(0)=0, a(1)=3. (End)
G.f.: 3*x/((1 - x)*(1 - 10*x)). - Ilya Gutkovskiy, Feb 24 2017
Sum_{n>=1} 1/a(n) = A135702. - Amiram Eldar, Nov 13 2020
E.g.f.: exp(x)*(exp(9*x) - 1)/3. - Stefano Spezia, Sep 13 2023
From Elmo R. Oliveira, Jul 20 2025: (Start)
a(n) = (A246057(n) - 1)/5.
a(n) = A010785(A017197(n-1)) for n >= 1. (End)

A002276 a(n) = 2*(10^n - 1)/9.

Original entry on oeis.org

0, 2, 22, 222, 2222, 22222, 222222, 2222222, 22222222, 222222222, 2222222222, 22222222222, 222222222222, 2222222222222, 22222222222222, 222222222222222, 2222222222222222, 22222222222222222, 222222222222222222, 2222222222222222222, 22222222222222222222, 222222222222222222222
Offset: 0

Views

Author

Keywords

Comments

a(n) is also the total number of holes in a variation of a box fractal as in illustration. - Kival Ngaokrajang, May 23 2014 [As observed by Hans Havermann, this seems to be incorrect: e.g., for n = 2 the illustration shows 28 small holes plus two larger holes. - M. F. Hasler, Oct 05 2020]

Crossrefs

Programs

Formula

a(n) = A178630(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
From Vincenzo Librandi, Jul 22 2010: (Start)
a(n) = a(n-1) + 2*10^(n-1) with a(0) = 0.
a(n) = 11*a(n-1) - 10*a(n-2) with a(0) = 0, a(1) = 2. (End)
G.f.: 2*x/((1 - x)*(1 - 10*x)). - Ilya Gutkovskiy, Feb 24 2017
E.g.f.: 2*exp(x)*(exp(9*x) - 1)/9. - Stefano Spezia, Sep 13 2023
From Elmo R. Oliveira, Jul 19 2025: (Start)
a(n) = 2*A002275(n).
a(n) = A010785(A017185(n-1)) for n >= 1. (End)

A002282 a(n) = 8*(10^n - 1)/9.

Original entry on oeis.org

0, 8, 88, 888, 8888, 88888, 888888, 8888888, 88888888, 888888888, 8888888888, 88888888888, 888888888888, 8888888888888, 88888888888888, 888888888888888, 8888888888888888, 88888888888888888, 888888888888888888, 8888888888888888888, 88888888888888888888, 888888888888888888888
Offset: 0

Views

Author

Keywords

Comments

If the initial term is omitted, might be called eightful (or hateful) numbers!

Examples

			Curious multiplications:
9*9 + 7 = 88;
98*9 + 6 = 888;
987*9 + 5 = 8888;
9876*9 + 4 = 88888;
98765*9 + 3 = 888888;
987654*9 + 2 = 8888888;
9876543*9 + 1 = 88888888;
98765432*9 + 0 = 888888888;
987654321*9 - 1 = 8888888888;
9876543210*9 - 2 = 88888888888. - _Philippe Deléham_, Mar 09 2014
		

References

  • Alfred S. Posamentier, Math Charmers, Tantalizing Tidbits for the Mind, Prometheus Books, NY, 2003, page 32.

Crossrefs

Programs

  • Maple
    A002282:=n->8*(10^n - 1)/9; seq(A002282(n), n=0..20); # Wesley Ivan Hurt, Mar 10 2014
  • Mathematica
    LinearRecurrence[{11,-10}, {0,8}, 20] (* Harvey P. Dale, May 30 2013 *)
  • PARI
    { a=-4/5; for (n = 0, 200, a+=8*10^(n - 1); write("b002282.txt", n, " ", a); ) } \\ Harry J. Smith, Jun 27 2009
    
  • Python
    def a(n): return 8*(10**n - 1)//9 # Martin Gergov, Oct 19 2022

Formula

From Jaume Oliver Lafont, Feb 03 2009: (Start)
a(n) = 11*a(n-1) - 10*a(n-2), with a(0)=0, a(1)=8.
G.f.: 8*x/((1-x)*(1-10*x)). (End)
a(n) = A178635(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
a(n) = a(n-1) + 8*10^(n-1), with a(0)=0. - Vincenzo Librandi, Jul 22 2010
a(n) = 8*A002275(n) = A002283(n) - A002275(n). - Carauleanu Marc, Sep 03 2016
From Ilya Gutkovskiy, Sep 03 2016: (Start)
E.g.f.: 8*(exp(9*x) - 1)*exp(x)/9.
a(n) = floor(8*10^n/9). (End)
From Elmo R. Oliveira, Jul 20 2025: (Start)
a(n) = (A246058(n) - 1)/2.
a(n) = A010785(A017257(n-1)) for n >= 1. (End)

A002279 a(n) = 5*(10^n - 1)/9.

Original entry on oeis.org

0, 5, 55, 555, 5555, 55555, 555555, 5555555, 55555555, 555555555, 5555555555, 55555555555, 555555555555, 5555555555555, 55555555555555, 555555555555555, 5555555555555555, 55555555555555555, 555555555555555555, 5555555555555555555, 55555555555555555555, 555555555555555555555
Offset: 0

Views

Author

Keywords

Comments

Arithmetic mean of all n-digit odd numbers. E.g., a(2) = arithmetic mean of {11,13,15,...,97,99} = (11+99)/2 = 55. - Amarnath Murthy, Aug 02 2005

Crossrefs

Programs

Formula

a(n) = A178632(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
From Vincenzo Librandi, Jul 22 2010: (Start)
a(n) = a(n-1) + 5*10^(n-1) with a(0)=0.
a(n) = 11*a(n-1) - 10*a(n-2) with a(0)=0, a(1)=5. (End)
G.f.: 5*x/((1 - x)*(1 - 10*x)). - Ilya Gutkovskiy, Feb 24 2017
E.g.f.: 5*exp(x)*(exp(9*x) - 1)/9. - Stefano Spezia, Sep 13 2023
From Karl-Heinz Hofmann, Nov 28 2023: (Start)
a(n) = A010785(9*n-4) for n > 0.
a(n) = 5 * A002275(n).
a(n) = 5 * A002283(n) / 9. (End)

A002280 a(n) = 6*(10^n - 1)/9.

Original entry on oeis.org

0, 6, 66, 666, 6666, 66666, 666666, 6666666, 66666666, 666666666, 6666666666, 66666666666, 666666666666, 6666666666666, 66666666666666, 666666666666666, 6666666666666666, 66666666666666666, 666666666666666666, 6666666666666666666, 66666666666666666666, 666666666666666666666
Offset: 0

Views

Author

Keywords

Comments

a(n-1) = number of Fibonacci numbers F(k), k <= 10^n, which end in 0. a(1)=6 because there are 6 Fibonacci numbers up to 10^2 which end in 0. - Shyam Sunder Gupta and Benoit Cloitre, Aug 15 2002
a(n) is the total number of holes in a certain triangle fractal (start with 10 triangles, 6 holes) after n iterations. See illustration in links. - Kival Ngaokrajang, Feb 21 2015

Crossrefs

Programs

Formula

a(n) = 6*A002275(n).
From Jaume Oliver Lafont, Feb 03 2009: (Start)
G.f.: 6*x/((1-x)*(1-10*x)).
a(n) = 11*a(n-1) - 10*a(n-2) with a(0)=0, a(1)=6. (End)
a(n) = A178633(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
a(n) = a(n-1) + 6*10^(n-1) with a(0)=0. - Vincenzo Librandi, Jul 22 2010
E.g.f.: 2*exp(x)*(exp(9*x) - 1)/3. - Stefano Spezia, Sep 13 2023
From Elmo R. Oliveira, Jul 21 2025: (Start)
a(n) = A073551(n+1)/2 for n >= 1.
a(n) = A010785(A017233(n-1)) for n >= 1. (End)

A002281 a(n) = 7*(10^n - 1)/9.

Original entry on oeis.org

0, 7, 77, 777, 7777, 77777, 777777, 7777777, 77777777, 777777777, 7777777777, 77777777777, 777777777777, 7777777777777, 77777777777777, 777777777777777, 7777777777777777, 77777777777777777, 777777777777777777, 7777777777777777777, 77777777777777777777, 777777777777777777777
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

Formula

a(n) = A178634(n)/A002283(n). - Reinhard Zumkeller, May 31 2010
From Vincenzo Librandi, Jul 22 2010: (Start)
a(n) = a(n-1) + 7*10^(n-1) with n>0, a(0)=0.
a(n) = 11*a(n-1) - 10*a(n-2) with n>1, a(0)=0, a(1)=7. (End)
G.f.: 7*x/((x-1)*(10*x-1)). - Colin Barker, Jan 24 2013
a(n) = 7*A002275(n). - Wesley Ivan Hurt, Mar 24 2015
E.g.f.: 7*exp(x)*(exp(9*x) - 1)/9. - Stefano Spezia, Sep 13 2023
From Elmo R. Oliveira, Jul 20 2025: (Start)
a(n) = (A099915(n) - 1)/2.
a(n) = A010785(A017245(n-1)) for n >= 1. (End)

A034838 Numbers k that are divisible by every digit of k.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 12, 15, 22, 24, 33, 36, 44, 48, 55, 66, 77, 88, 99, 111, 112, 115, 122, 124, 126, 128, 132, 135, 144, 155, 162, 168, 175, 184, 212, 216, 222, 224, 244, 248, 264, 288, 312, 315, 324, 333, 336, 366, 384, 396, 412, 424, 432, 444, 448
Offset: 1

Views

Author

Keywords

Comments

Subset of zeroless numbers A052382: Integers with at least one digit 0 (A011540) are excluded.
A128635(a(n)) = n.
Contains in particular all repdigits A010785 \ {0}. - M. F. Hasler, Jan 05 2020
The greatest term such that the digits are all different is the greatest Lynch-Bell number 9867312 = A115569(548) = A113028(10) [see Diophante link]. - Bernard Schott, Mar 18 2021
Named "nude numbers" by Katagiri (1982-83). - Amiram Eldar, Jun 26 2021

Examples

			36 is in the sequence because it is divisible by both 3 and 6.
48 is included because both 4 and 8 divide 48.
64 is not included because even though 4 divides 64, 6 does not.
		

References

  • Charles Ashbacher, Journal of Recreational Mathematics, Vol. 33 (2005), pp. 227. See problem number 2693.
  • Yoshinao Katagiri, Letter to the editor of the Journal of Recreational Mathematics, Vol. 15, No. 4 (1982-83).
  • Margaret J. Kenney and Stanley J. Bezuszka, Number Treasury 3: Investigations, Facts And Conjectures About More Than 100 Number Families, World Scientific, 2015, p. 175.
  • Thomas Koshy, Elementary Number Theory with Applications, Elsevier, 2007, p. 79.

Crossrefs

Intersection of A002796 (numbers divisible by each nonzero digit) and A052382 (zeroless numbers), or A002796 \ A011540 (numbers with digit 0).
Subsequence of A034709 (divisible by last digit).
Contains A007602 (multiples of the product of their digits) and subset A059405 (n is the product of its digits raised to positive powers), A225299 (divisible by square of each digit), and A066484 (n and its rotations are divisible by each digit).
Cf. A113028, A346267 (number of terms with n digits), A087140 (complement).
Supersequence of A115569 (with all different digits).

Programs

  • Haskell
    a034838 n = a034838_list !! (n-1)
    a034838_list = filter f a052382_list where
       f u = g u where
         g v = v == 0 || mod u d == 0 && g v' where (v',d) = divMod v 10
    -- Reinhard Zumkeller, Jun 15 2012, Dec 21 2011
    
  • Magma
    [n:n in [1..500]| not 0 in Intseq(n) and #[c:c in [1..#Intseq(n)]| n mod Intseq(n)[c] eq 0] eq #Intseq(n)] // Marius A. Burtea, Sep 12 2019
  • Maple
    a:=proc(n) local nn,j,b,bb: nn:=convert(n,base,10): for j from 1 to nops(nn) do b[j]:=n/nn[j] od: bb:=[seq(b[j],j=1..nops(nn))]: if map(floor,bb)=bb then n else fi end: 1,2,3,4,5,6,7,8,9,seq(seq(seq(a(100*m+10*n+k),k=1..9),n=1..9),m=0..6); # Emeric Deutsch
  • Mathematica
    divByEvryDigitQ[n_] := Block[{id = Union[IntegerDigits[n]]}, Union[ IntegerQ[ #] & /@ (n/id)] == {True}]; Select[ Range[ 487],  divByEvryDigitQ[#] &] (* Robert G. Wilson v, Jun 21 2005 *)
    Select[Range[500],FreeQ[IntegerDigits[#],0]&&AllTrue[#/ IntegerDigits[ #], IntegerQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Mar 31 2019 *)
  • PARI
    is(n)=my(v=vecsort(eval(Vec(Str(n))),,8)); if(v[1]==0, return(0)); for(i=1, #v, if(n%v[i], return(0))); 1 \\ Charles R Greathouse IV, Apr 17 2012
    
  • PARI
    is_A034838(n)=my(d=Set(digits(n)));d[1]&&!forstep(i=#d,1,-1,n%d[i]&&return) \\ M. F. Hasler, Jan 10 2016
    
  • Python
    A034838_list = []
    for g in range(1,4):
        for n in product('123456789',repeat=g):
            s = ''.join(n)
            m = int(s)
            if not any(m % int(d) for d in s):
                A034838_list.append(m) # Chai Wah Wu, Sep 18 2014
    
  • Python
    for n in range(10**3):
        s = str(n)
        if '0' not in s:
            c = 0
            for i in s:
                if n%int(i):
                    c += 1
                    break
            if not c:
                print(n,end=', ') # Derek Orr, Sep 19 2014
    
  • Python
    # finite automaton accepting sequence (see comments in A346267)
    from math import gcd
    def lcm(a, b): return a * b // gcd(a, b)
    def inF(q): return q[0]%q[1] == 0
    def delta(q, c): return ((10*q[0]+c)%2520, lcm(q[1], c))
    def ok(n):
        q = (0, 1)
        for c in map(int, str(n)):
            if c == 0: return False # computation dies
            else: q = delta(q, c)
        return inF(q)
    print(list(filter(ok, range(450)))) # Michael S. Branicky, Jul 18 2021
    
Previous Showing 11-20 of 171 results. Next