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

A180599 Zero followed by infinitely many 9's.

Original entry on oeis.org

0, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9
Offset: 0

Views

Author

Odimar Fabeny, Sep 10 2010

Keywords

Comments

Another interpretation: A real number with an infinitesimally small difference from the integer 1 which is used to test the precision of calculating devices. - John W. Nicholson, Feb 01 2012
a(n) is also the number of n-digit positive repdigit numbers (A010785). - Stefano Spezia, Aug 15 2020

Examples

			Viewed as a real number: For a TI-89, entering 1.-10^-12 yields .999999999999; however, 1.-10^-13 yields 1. - _John W. Nicholson_, Feb 01 2012
		

Crossrefs

Programs

Formula

a(0) = 0, a(n) = 9 for n > 0.
a(n) = 9 * A057427(n).
a(n) = A010888(9*n), where A010888 is the digital root.
From Robert Israel, Dec 16 2014: (Start)
G.f.: 9*x/(1 - x).
E.g.f.: 9*(exp(x) - 1). (End)

Extensions

More terms from Robert G. Wilson v, Sep 20 2010
Definition changed by N. J. A. Sloane, Feb 04 2012

A178403 Numbers containing the rounded up arithmetic mean of their digits at least once, cf. A004427.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 21, 22, 23, 32, 33, 34, 43, 44, 45, 54, 55, 56, 65, 66, 67, 76, 77, 78, 87, 88, 89, 98, 99, 100, 101, 102, 110, 111, 112, 120, 121, 122, 123, 132, 133, 134, 135, 143, 145, 146, 147, 153, 154, 157, 158, 159, 164, 169, 174, 175, 185
Offset: 1

Views

Author

Reinhard Zumkeller, May 27 2010

Keywords

Comments

A178401(a(n)) > 0; complement of A178402.
A010785, A050278, A178358, A178359 are subsequences;
a(n) = A131207(n) for n < 48;
a(n) = A134336(n) for n < 48;
a(n+1) = A032981(n) for n < 38.

A190217 Numbers all of whose divisors are repdigit numbers.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 22, 33, 44, 55, 66, 77, 88, 99, 1111111111111111111, 2222222222222222222, 3333333333333333333, 4444444444444444444, 5555555555555555555, 6666666666666666666, 7777777777777777777, 8888888888888888888, 9999999999999999999
Offset: 1

Views

Author

Jaroslav Krizek, May 06 2011

Keywords

Comments

Subset of A010785, A190220 and A190221.

Examples

			Number 99 is in sequence because all divisors of 99 (1, 3, 9, 11, 33, 99) are repdigit numbers.
		

A243535 Numbers whose list of divisors contains 2 distinct digits (in base 10).

Original entry on oeis.org

2, 3, 5, 7, 13, 17, 19, 22, 31, 33, 41, 55, 61, 71, 77, 101, 113, 121, 131, 151, 181, 191, 199, 211, 311, 313, 331, 661, 811, 881, 911, 919, 991, 1111, 1117, 1151, 1171, 1181, 1511, 1777, 1811, 1999, 2111, 2221, 3313, 3331, 4111, 4441, 6661, 7177, 7717, 8111
Offset: 1

Views

Author

Jaroslav Krizek, Jun 13 2014

Keywords

Comments

Numbers k such that A037278(k), A176558(k) and A243360(k) contain 2 distinct digits.
Many of the composite terms are in A203897. - Charles R Greathouse IV, Sep 06 2016
Terms are either repdigit numbers (A010785) or contain only 1 and a single other digit. - Michael S. Branicky, Nov 16 2022

Examples

			121 is in the sequence because the list of divisors of 121, i.e., (1, 11, 121), contains 2 distinct digits (1, 2).
		

Crossrefs

Sequences of numbers n such that the list of divisors of n contains k distinct digits for 1 <= k <= 10: k = 1: A243534; k = 2: A243535; k = 3: A243536; k = 4: A243537; k = 5: A243538; k = 6: A243539; k = 7: A243540; k = 8: A243541; k = 9: A243542; k = 10: A095050.
Cf. A243543 (the smallest number m whose list of divisors contains n distinct digits).

Programs

  • Excel
    [Row n = 1..10000; Column A: A(n) = A095048(n); Column B: B(n) = IF(A(n)=2;A(n)); Arrangement of column B]
    
  • Maple
    dmax:= 6: # get all terms of <= dmax digits
    Res:= {}:
    for a in [0,$2..9] do
        S:= {0}:
        for d from 1 to dmax do
            S:= map(t -> (10*t+1,10*t+a), S);
            Res:= Res union select(filter, S)
        od
    od:
    sort(convert(Res,list)): # Robert Israel, Sep 05 2016
  • Mathematica
    Select[Range[9000],Length[Union[Flatten[IntegerDigits/@Divisors[ #]]]] == 2&] (* Harvey P. Dale, Dec 14 2017 *)
  • PARI
    isok(n) = vd = []; fordiv(n, d, vd = concat(vd, digits(d))); #Set(vd) == 2; \\ Michel Marcus, Jun 13 2014
    
  • Python
    from sympy import divisors
    from itertools import count, islice, product
    def ok(n):
        s = set("1"+str(n))
        if len(s) > 2: return False
        for d in divisors(n, generator=True):
            s |= set(str(d))
            if len(s) > 2: return False
        return len(s) == 2
    def agen():
        yield from [2, 3, 5, 7]
        for d in count(2):
            s = set()
            for first, other in product("123456789", "0123456789"):
                for p in product(sorted(set(first+other)), repeat=d-1):
                    if other not in p: continue
                    t = int(first+"".join(p))
                    if ok(t): s.add(t)
            yield from sorted(s)
    print(list(islice(agen(), 52))) # Michael S. Branicky, Nov 16 2022

A048328 Numbers that are repdigits in base 3.

Original entry on oeis.org

0, 1, 2, 4, 8, 13, 26, 40, 80, 121, 242, 364, 728, 1093, 2186, 3280, 6560, 9841, 19682, 29524, 59048, 88573, 177146, 265720, 531440, 797161, 1594322, 2391484, 4782968, 7174453, 14348906, 21523360, 43046720, 64570081, 129140162, 193710244, 387420488, 581130733
Offset: 0

Views

Author

Patrick De Geest, Feb 15 1999

Keywords

Comments

Case for base 2 see A000225: 2^n - 1.
If the sequence b(n) represents the number of paths of length n, n >= 1, starting at node 1 and ending at nodes 1, 2, 3 and 4 on the path graph P_5 then a(n-1) = b(n) - 1. - Johannes W. Meijer, May 29 2010

Crossrefs

Programs

  • Maple
    nmax := 35; a(0) := 0: for n from 1 to nmax do a(2*n) := a(2*n-2) + 2*3^(n-1); od: a(1) := 1: for n from 1 to nmax do a(2*n+1) := 1*a(2*n-1) + 3^n; od: seq(a(n), n=0..nmax);
    # End program 1
    with(GraphTheory): G := PathGraph(5): A:= AdjacencyMatrix(G): nmax := nmax; for n from 1 to nmax+1 do B(n) := A^n; b(n) := add(B(n)[1, k], k=1..4); a1(n-1) := b(n)-1; od: seq(a1(n), n=0..nmax);
    # End program 2
    # From Johannes W. Meijer, May 29 2010, revised Sep 23 2012
    # third Maple program:
    a:= n->(<<0|1>, <-3|4>>^iquo(n, 2, 'r').`if`(r=0, <<0, 2>>, <<1, 4>>))[1, 1]:
    seq (a(n), n=0..60);  # Alois P. Heinz, Sep 23 2012
  • Mathematica
    Rest[FromDigits[#, 3]&/@Flatten[Table[{PadRight[{1}, n, 1], PadRight[{2}, n, 2]}, {n, 0, 20}], 1]] (* Harvey P. Dale, Feb 03 2011 *)
  • PARI
    a(n)=([0,1,0,0; 0,0,1,0; 0,0,0,1; -3,0,4,0]^n*[0;1;2;4])[1,1] \\ Charles R Greathouse IV, Oct 07 2015

Formula

G.f.: (2*x^2+x)/(1-4*x^2+3*x^4). - Alois P. Heinz, Sep 23 2012
Sum_{n>=1} 1/a(n) = 3 * A214369 = 2.04646050781571420028... - Amiram Eldar, Jan 21 2022
a(n) = (3^(n/2)*(sqrt(3) + 2 - (-1)^n*(sqrt(3) - 2)) - 3 - (-1)^n)/4. - Stefano Spezia, Feb 18 2022

A054268 Sum of composite numbers between prime p and nextprime(p) is a repdigit.

Original entry on oeis.org

3, 5, 109, 111111109, 259259257
Offset: 1

Views

Author

Patrick De Geest, Apr 15 2000

Keywords

Comments

No additional terms below 472882027.
No additional terms below 10^58. - Chai Wah Wu, Jun 01 2024

Examples

			a(5) is ok since between 259259257 and nextprime 259259261 we get the sum 259259258 + 259259259 + 259259260 which yield repdigit 777777777.
		

Crossrefs

Programs

  • Mathematica
    repQ[n_]:=Count[DigitCount[n],0]==9; Select[Prime[Range[2,14500000]], repQ[Total[Range[#+1,NextPrime[#]-1]]]&] (* Harvey P. Dale, Jan 29 2011 *)
  • Python
    from sympy import prime
    A054268 = [prime(n) for n in range(2,10**5) if len(set(str(int((prime(n+1)-prime(n)-1)*(prime(n+1)+prime(n))/2)))) == 1]
    # Chai Wah Wu, Aug 12 2014
    
  • Python
    from itertools import count, islice
    from sympy import isprime, nextprime
    from sympy.abc import x,y
    from sympy.solvers.diophantine.diophantine import diop_quadratic
    def A054268_gen(): # generator of terms
        for l in count(1):
            c = []
            for m in range(1,10):
                k = m*(10**l-1)//9<<1
                for a, b in diop_quadratic((x-y-1)*(x+y)-k):
                    if isprime(b) and a == nextprime(b):
                        c.append(b)
            yield from sorted(c)
    A054268_list = list(islice(A054268_gen(),5)) # Chai Wah Wu, Jun 01 2024

Formula

Numbers A000040(n) for n > 1 such that A001043(n)*(A001223(n)-1)/2 is in A010785. - Chai Wah Wu, Aug 12 2014

Extensions

Offset changed by Andrew Howroyd, Aug 14 2024

A244112 Reverse digit count of n in decimal representation.

Original entry on oeis.org

10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 1110, 21, 1211, 1311, 1411, 1511, 1611, 1711, 1811, 1911, 1210, 1211, 22, 1312, 1412, 1512, 1612, 1712, 1812, 1912, 1310, 1311, 1312, 23, 1413, 1513, 1613, 1713, 1813, 1913, 1410, 1411, 1412, 1413, 24, 1514, 1614, 1714
Offset: 0

Views

Author

Reinhard Zumkeller, Nov 11 2014

Keywords

Comments

Frequencies of digits 0 through 9, occurring in n, are summarized in order of decreasing digits;
a(A010785(n)) = A047842(A010785(n)).

Examples

			101 contains two 1s and one 0, therefore a(101) = 2110;
102 contains one 2, one 1 and one 0, therefore a(102) = 121110.
		

Crossrefs

See A036058 for the orbit of 0 under this map.

Programs

  • Haskell
    import Data.List (sort, group); import Data.Function (on)
    a244112 :: Integer -> Integer
    a244112 n = read $ concat $
       zipWith ((++) `on` show) (map length xs) (map head xs)
       where xs = group $ reverse $ sort $ map (read . return) $ show n
    
  • Mathematica
    f[n_] := Block[{s = Split@ IntegerDigits@ n}, FromDigits@ Reverse@ Riffle[Union@ Flatten@ s, Length@# & /@ s]]; Array[f, 48, 0] (* Robert G. Wilson v, Dec 01 2016 *)
  • PARI
    A244112(n,c=1,S="")={for(i=2,#n=vecsort(digits(n),,4),n[i]==n[i-1]&&c++&&next;S=Str(S,c,n[i-1]);c=1);eval(Str(S,c,if(n,n[#n])))} \\ M. F. Hasler, Feb 25 2018
  • Python
    def A244112(n):
        return int(''.join([str(str(n).count(d))+d for d in '9876543210' if str(n).count(d) > 0])) # Chai Wah Wu, Dec 01 2016
    

A329197 Length of the n-th nontrivial cycle of the "ghost iteration" A329200.

Original entry on oeis.org

5, 6, 3, 7, 5, 9, 6, 3, 3, 5, 3, 3, 6, 3, 3, 3, 5, 3, 3, 6, 3, 3, 3, 3, 5, 3, 3, 6, 3, 17, 3, 11, 3, 3, 3, 5, 3, 3, 6, 6, 3, 17, 3, 3, 3, 3, 5, 7, 6
Offset: 1

Views

Author

M. F. Hasler, Nov 10 2019

Keywords

Comments

A329200 consists in adding or subtracting the number A040115(n) whose digits are the differences of adjacent digits of n, depending on its parity.
Repdigits A010785 are fixed points of this map, but some numbers enter nontrivial cycles. This sequence gives the length of these cycles, ordered by their smallest member, as they are listed in the table A329196. See there for more information.

Examples

			The first cycle of A329200 is row 1 of A329196, (8290, 8969, 9102), of length 3 = a(1).
The second cycle of A329200 is row 2 of A329196, (17998, 24199, 21819, 20041, 22084, 21800, 20020), of length 7 = a(2).
		

Crossrefs

Cf. A329196, A329200, A329198, A329342 (variant using A329201).

Programs

  • PARI
    /* change T to #T in print statement of code for A329196 */

Extensions

a(9)-a(35) from Scott R. Shannon, Nov 12 2019
a(36)-a(49) from Lars Blomberg, Nov 15 2019

A329201 The ghost iteration (B): add or subtract the number formed by absolute differences of digits (A040115), according to parity (odd or even).

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 11, 13, 11, 17, 11, 21, 11, 25, 11, 18, 22, 22, 24, 22, 28, 22, 32, 22, 36, 33, 29, 33, 33, 35, 33, 39, 33, 43, 33, 36, 44, 40, 44, 44, 46, 44, 50, 44, 54, 55, 47, 55, 51, 55, 55, 57, 55, 61, 55, 54, 66, 58, 66, 62, 66, 66, 68, 66, 72, 77, 65, 77, 69, 77, 73, 77
Offset: 0

Views

Author

Eric Angelini and M. F. Hasler, Nov 09 2019

Keywords

Comments

Sequence A040115 is most naturally extended to 0 (empty sum) for single-digit arguments; that's what we use for n < 10 here. This value is subtracted from n if even, added if odd.
A040115 is zero iff the argument is a repdigit (A010785), which therefore are the fixed points of this map A329201. All small starting values reach a fixed point, but larger values may enter a nontrivial cycle (or "loop").
See the table A329342 for the list of these cycles.

Examples

			For n = 101, the number formed by the absolute differences of digits is 11. Since this is odd it is added to n, so a(101) = 101 + 11 = 112.
		

Crossrefs

Cf. A040115, A329200 (variant A: add/subtract if even/odd), A010785 (fixed points).
Cf. A329342 (list of cycles).

Programs

  • PARI
    apply( A329201(n)={n-(-1)^(n=fromdigits(abs((n=digits(n+!n))[^-1]-n[^1])))*n}, [1..199])

Formula

a(n) = n - (-1)^d*d where d = A040115(n), 0 for n < 10.

A340548 Integers whose number of repdigit divisors sets a new record.

Original entry on oeis.org

1, 2, 4, 6, 12, 24, 66, 132, 264, 792, 3960, 14652, 26664, 29304, 79992, 146520, 399960, 1025640, 2666664, 7999992, 13333320, 39999960, 269333064, 807999192, 1346665320, 4039995960, 28279971720, 7999999999992, 8080799919192, 13333333333320, 13467999865320, 39999999999960, 40403999595960
Offset: 1

Views

Author

Bernard Schott, Jan 11 2021

Keywords

Comments

The first 10 terms are the same as A093036, then A093036(11) = 1848 while a(11) = 3960, because from a(1) to a(10), all palindromic divisors are also repdigits, and then 616 is a non-repdigit palindromic divisor of 1848.
Number of repdigit divisors: 1, 2, 3, 4, 5, 6, 8, 10, 12, 14, 16, 17, 18, ...
Indices of repdigits: 1, 2, 3, 4, 7, ...

Examples

			132 has 12 divisors: {1, 2, 3, 4, 6, 11, 12, 22, 33, 44, 66, 132} of which 10 are repdigits: {1, 2, 3, 4, 6, 11, 22, 33, 44, 66}. No positive integer smaller than 132 has as many as ten repdigit divisors; hence 132 is a term.
		

Crossrefs

Similar for: A053624 (odd), A181808 (even), A093036 (palindromes), A340549 (repunits).

Programs

  • Mathematica
    repQ[n_] := Length @ Union @ IntegerDigits[n] == 1; s[n_] := DivisorSum[n, 1 &, repQ[#] &]; smax =  0; seq = {}; Do[s1 = s[n]; If[s1 > smax, smax = s1; AppendTo[seq, n]], {n, 1, 10^5}]; seq (* Amiram Eldar, Jan 11 2021 *)
  • PARI
    isrd(n) = {1 == #Set(digits(n))}; \\ A010785
    f(n) = sumdiv(n, d, isrd(d));
    lista(nn) = {my(m = 0); for (n=1, nn, my(x = f(n)); if (x > m, print1(n, ", "); m = x););} \\ Michel Marcus, Jan 11 2021

Extensions

a(16)-a(20) from Michel Marcus, Jan 11 2021
a(21)-a(26) from Amiram Eldar, Jan 12 2021
a(27) from Chai Wah Wu, Jan 14 2021
More terms from David A. Corneth, Jan 15 2021
Previous Showing 31-40 of 171 results. Next