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 21-30 of 110 results. Next

A115300 Greatest digit of n * least digit of n.

Original entry on oeis.org

1, 4, 9, 16, 25, 36, 49, 64, 81, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 0, 5, 10, 15, 20, 25, 30, 35, 40, 45, 0, 6, 12, 18, 24, 30, 36, 42, 48, 54, 0, 7, 14, 21, 28, 35, 42, 49, 56, 63, 0, 8
Offset: 1

Views

Author

Rick L. Shepherd, Jan 20 2006

Keywords

Comments

a(101) = 0 and A111707(101) = 1, but all previous terms match.
a(n) = A169669(n) for n <= 100.

Examples

			a(3) = 3 * 3 = 9, a(232) = 3 * 2 = 6, a(1889009898) = 9 * 0 = 0.
		

Crossrefs

Cf. A037904 (greatest-least), A115299 (greatest+least), A111707.

Programs

  • Haskell
    a115300 n = a054054 n * a054055 n  -- Reinhard Zumkeller, Apr 29 2015
    
  • Mathematica
    Array[Max[#] * Min[#] &@ IntegerDigits[#] &, 81] (* James C. McMahon, Aug 18 2024 *)
  • PARI
    a(n) = my(d=digits(n)); vecmin(d)*vecmax(d); \\ Michel Marcus, Aug 18 2024
  • Python
    def a(n): d = list(map(int, str(n))); return max(d) * min(d)
    print([a(n) for n in range(1, 82)]) # Michael S. Branicky, Dec 12 2023
    

Formula

a(n) = A054054(n)*A054055(n). - Reinhard Zumkeller, Apr 29 2015

A136399 Numbers having in their decimal representation at least one digit greater than 1.

Original entry on oeis.org

2, 3, 4, 5, 6, 7, 8, 9, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75
Offset: 1

Views

Author

Reinhard Zumkeller, Dec 30 2007

Keywords

Comments

A054055(a(n)) > 1;
Complement of A007088; A064770(a(n)) <> a(n).

Crossrefs

Programs

  • Haskell
    a136399 n = a136399_list !! (n-1)
    a136399_list = filter (any (> '1') . show) [0..]
    -- Reinhard Zumkeller, Apr 25 2012
    
  • Mathematica
    Select[Range[100], Max[IntegerDigits[#]] > 1 &] (* Paolo Xausa, Oct 30 2024 *)
  • Python
    def A136399(n):
        def f(x):
            s = str(x)
            for i in range(l:=len(s)):
                if s[i]>'1':
                    break
            else:
                return n+int(s,2)
            return n+int(s[:i]+'1'*(l-i),2)
        m, k = n, f(n)
        while m != k: m, k = k, f(k)
        return m # Chai Wah Wu, Oct 16 2024
    
  • Python
    def ok(n): return any(d > '1' for d in str(n))
    print([k for k in range(76) if ok(k)]) # Michael S. Branicky, Oct 29 2024

A190592 Maximal digit in base-3 expansion of n.

Original entry on oeis.org

0, 1, 2, 1, 1, 2, 2, 2, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 1, 1, 2, 1, 1, 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, 2, 2, 2, 2, 2, 2, 2, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2
Offset: 0

Views

Author

N. J. A. Sloane, May 13 2011, based on a suggestion from Marc LeBrun

Keywords

Crossrefs

Programs

  • Maple
    [seq(max(convert(n,base,3)),n=0..120)];
  • Mathematica
    Join[{0}, gl[n_] := Module[{idn = IntegerDigits[n, 3]}, Max[idn]]; Array[gl,100]] (* Vincenzo Librandi, Aug 12 2017 *)
  • PARI
    a(n) = if (n==0, 0, vecmax(digits(n, 3))); \\ Michel Marcus, Aug 12 2017

Formula

a(n) = 2 if n == 2 (mod 3), a(1)=1, otherwise a(n) = a(floor(n/3)). - Robert Israel, Aug 11 2017
a(n) = A054055(A007089(n)). - Felix Fröhlich, Aug 13 2017

A283608 Numbers whose largest decimal digit is 5.

Original entry on oeis.org

5, 15, 25, 35, 45, 50, 51, 52, 53, 54, 55, 105, 115, 125, 135, 145, 150, 151, 152, 153, 154, 155, 205, 215, 225, 235, 245, 250, 251, 252, 253, 254, 255, 305, 315, 325, 335, 345, 350, 351, 352, 353, 354, 355, 405, 415, 425, 435, 445, 450, 451, 452, 453, 454
Offset: 1

Views

Author

Jaroslav Krizek, Mar 19 2017

Keywords

Comments

Numbers n such that A054055(n) = 5.
Number of terms less than 10^n is 6^n - 5^n.
Subsequence of A011535. - David A. Corneth, Mar 25 2017
Prime terms are in A106097.

Crossrefs

Cf. Sequences of numbers whose largest decimal digit is k (for k = 1..9): A007088 (k = 1), A277964 (k = 2), A277965 (k = 3), A277966 (k = 4), this sequence (k = 5), A283609 (k = 6), A283610 (k = 7), A283611 (k = 8), A011539 (k = 9).

Programs

  • GAP
    Filtered([1..500],n->Maximum(ListOfDigits(n))=5); # Muniru A Asiru, Feb 27 2019
  • Magma
    [n: n in [1..100000] | Maximum(Setseq(Set(Sort(&cat[Intseq(n)])))) eq 5];
    
  • Mathematica
    Select[Range[1000], Max[IntegerDigits[#]] == 5 &] (* Giovanni Resta, Mar 19 2017 *)
  • PARI
    for(n=1, 500, if(vecmax(digits(n))==5, print1(n,", "))) \\ Indranil Ghosh, Mar 19 2017
    
  • PARI
    nxt(n) = {my(d = digits(n), i, j=0, t=0); forstep(i=#d,1,-1, if(d[i]!=5, j=i; break)); if(j>0, d[j]++; if(d[j]==5, for(k=j+1,#d,d[k]=0)); if(j<#d && d[j+1]==5, for(k=j+1,#d-1,d[k]=0)); for(k=1,j-1, if(d[k]==5,for(i=j+1, #d, d[i] = 0);break)), d = vector(#d+1); d[1]=1; d[#d]=5);sum(i=1, #d, d[i]*10^(#d-i))} \\ David A. Corneth, Mar 25 2017
    
  • Python
    from sympy.ntheory.factor_ import digits
    print([n for n in range(1, 501) if max(digits(n)[1:])==5]) # Indranil Ghosh, Mar 19 2017
    

A283609 Numbers whose largest decimal digit is 6.

Original entry on oeis.org

6, 16, 26, 36, 46, 56, 60, 61, 62, 63, 64, 65, 66, 106, 116, 126, 136, 146, 156, 160, 161, 162, 163, 164, 165, 166, 206, 216, 226, 236, 246, 256, 260, 261, 262, 263, 264, 265, 266, 306, 316, 326, 336, 346, 356, 360, 361, 362, 363, 364, 365, 366, 406, 416, 426
Offset: 1

Views

Author

Jaroslav Krizek, Mar 19 2017

Keywords

Comments

Numbers n such that A054055(n) = 6.
Number of terms less than 10^n is 7^n - 6^n.
Prime terms are in A106096.

Crossrefs

Cf. Sequences of numbers whose largest decimal digit is k (for k = 1..9): A007088 (k = 1), A277964 (k = 2), A277965 (k = 3), A277966 (k = 4), A283608 (k = 5), this sequence (k = 6), A283610 (k = 7), A283611 (k = 8), A011539 (k = 9).

Programs

  • GAP
    Filtered([1..500],n->Maximum(ListOfDigits(n))=6); # Muniru A Asiru, Mar 01 2019
  • Magma
    [n: n in [1..100000] | Maximum(Setseq(Set(Sort(&cat[Intseq(n)])))) eq 6]
    
  • Mathematica
    Select[Range[1000], Max[IntegerDigits[#]] == 6 &] (* Giovanni Resta, Mar 19 2017 *)
  • PARI
    for(n=1, 500, if(vecmax(digits(n))==6, print1(n,", "))) \\ Indranil Ghosh, Mar 19 2017
    
  • Python
    from sympy.ntheory.factor_ import digits
    print([n for n in range(1, 501) if max(digits(n)[1:])==6]) # Indranil Ghosh, Mar 19 2017
    

A283610 Numbers n whose largest decimal digit is 7.

Original entry on oeis.org

7, 17, 27, 37, 47, 57, 67, 70, 71, 72, 73, 74, 75, 76, 77, 107, 117, 127, 137, 147, 157, 167, 170, 171, 172, 173, 174, 175, 176, 177, 207, 217, 227, 237, 247, 257, 267, 270, 271, 272, 273, 274, 275, 276, 277, 307, 317, 327, 337, 347, 357, 367, 370, 371, 372
Offset: 1

Views

Author

Jaroslav Krizek, Mar 19 2017

Keywords

Comments

Numbers n such that A054055(n) = 7.
Number of terms less than 10^n is 8^n - 7^n.
Prime terms are in A106095.

Crossrefs

Cf. Sequences of numbers n whose largest decimal digit is k (for k = 1 - 9): A007088 (k = 1), A277964 (k = 2), A277965 (k = 3), A277966 (k = 4), A283608 (k = 5), A283609 (k = 6), this sequence (k = 7), A283611 (k = 8), A011539 (k = 9).

Programs

  • GAP
    Filtered([1..380],n->Maximum(ListOfDigits(n))=7); # Muniru A Asiru, Feb 27 2019
  • Magma
    [n: n in [1..100000] | Maximum(Setseq(Set(Sort(&cat[Intseq(n)])))) eq 7]
    
  • Mathematica
    Select[Range[1000], Max[IntegerDigits[#]] == 7 &] (* Giovanni Resta, Mar 19 2017 *)
  • PARI
    for(n=1, 500, if(vecmax(digits(n))==7, print1(n,", "))) \\ Indranil Ghosh, Mar 19 2017
    
  • Python
    from sympy.ntheory.factor_ import digits
    [n for n in range(1, 401) if max(digits(n)[1:]) == 7]  # Indranil Ghosh, Mar 19 2017
    

A283611 Numbers whose largest decimal digit is 8.

Original entry on oeis.org

8, 18, 28, 38, 48, 58, 68, 78, 80, 81, 82, 83, 84, 85, 86, 87, 88, 108, 118, 128, 138, 148, 158, 168, 178, 180, 181, 182, 183, 184, 185, 186, 187, 188, 208, 218, 228, 238, 248, 258, 268, 278, 280, 281, 282, 283, 284, 285, 286, 287, 288, 308, 318, 328, 338, 348
Offset: 1

Views

Author

Jaroslav Krizek, Mar 19 2017

Keywords

Comments

Numbers n such that A054055(n) = 8.
Number of terms less than 10^n is 9^n - 8^n.
Prime terms are in A106094.

Crossrefs

Cf. Sequences of numbers whose largest decimal digit is k (for k = 1..9): A007088 (k = 1), A277964 (k = 2), A277965 (k = 3), A277966 (k = 4), A283608 (k = 5), A283609 (k = 6), A283610 (k = 7), this sequence (k = 8), A011539 (k = 9).

Programs

  • GAP
    Filtered([1..400],n->Maximum(ListOfDigits(n))=8); # Muniru A Asiru, Mar 01 2019
  • Magma
    [n: n in [1..100000] | Maximum(Setseq(Set(Sort(&cat[Intseq(n)])))) eq 8]
    
  • Maple
    f:= proc(n) local L;
      L:= convert(n,base,9);
      if not has(L,8) then return NULL fi;
      add(L[i]*10^(i-1),i=1..nops(L))
    end proc:
    map(f, [$8..1000]); # Robert Israel, Mar 27 2017
  • Mathematica
    Select[Range@ 350, Max@ IntegerDigits@ # == 8 &] (* Michael De Vlieger, Mar 25 2017 *)
  • PARI
    isok(n) = vecmax(digits(n)) == 8; \\ Michel Marcus, Mar 25 2017
    

A041000 If decimal expansion of n-th prime is x1 x2 ... xk, sort the xi into nonincreasing order, y1 y2 ... yk; then a(n) = |y1-y2-y3...-yk|.

Original entry on oeis.org

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

Views

Author

Keywords

Examples

			a(397)=|9-7-3|=1.
		

Crossrefs

Programs

  • Mathematica
    der[n_]:=Module[{c=Reverse[Sort[IntegerDigits[n]]]},Abs[First[c]-Total[Rest[c]]]]; der/@Prime[Range[110]] (* Harvey P. Dale, Aug 15 2012 *)

Formula

a(n) = |A007953(n)-2*A054055(n)|. [Charles R Greathouse IV, May 07 2011]

Extensions

More terms from Michel ten Voorde

A071204 Numbers which are multiples of their largest digit (decimal notation).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 15, 20, 22, 24, 25, 30, 33, 35, 36, 40, 44, 45, 48, 50, 55, 60, 66, 70, 77, 80, 88, 90, 99, 100, 101, 102, 104, 105, 110, 111, 112, 115, 120, 122, 123, 124, 125, 126, 128, 132, 135, 140, 144, 145
Offset: 1

Views

Author

Reinhard Zumkeller, May 16 2002

Keywords

Examples

			15 is a term since 15/5 = 3.
16 is not a term because 16/6 = 2.66666666...
		

Crossrefs

Cf. A071203, A071205, A071206, a(n) mod A054055(n) = 0.

Programs

  • Mathematica
    Select[Range[200], Divisible[#, Sort[IntegerDigits[#]][[-1]]] &] (* Alonso del Arte, Sep 09 2017 *)
  • PARI
    isok(n) = (n % vecmax(digits(n))) == 0; \\ Michel Marcus, Sep 11 2017

A072543 Numbers whose largest decimal digit is also the initial digit.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 20, 21, 22, 30, 31, 32, 33, 40, 41, 42, 43, 44, 50, 51, 52, 53, 54, 55, 60, 61, 62, 63, 64, 65, 66, 70, 71, 72, 73, 74, 75, 76, 77, 80, 81, 82, 83, 84, 85, 86, 87, 88, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 110, 111, 200, 201
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 04 2002

Keywords

Comments

A054055(a(n)) = A000030(a(n));
the sequence differs from A009996, A032873 and A032907: a(66)=101 is not in A009996, a(67)=110 is not in A032873 and a(65)=100 is not in A032907.

Examples

			a(10^ 1) = 9
a(10^ 2) = 411
a(10^ 3) = 6216
a(10^ 4) = 73474
a(10^ 5) = 813826
a(10^ 6) = 8512170
a(10^ 7) = 88368780
a(10^ 8) = 911960211
a(10^ 9) = 9237655227
a(10^10) = 93323313303
		

Crossrefs

Cf. A072544.

Programs

  • Haskell
    a072543 n = a072543_list !! (n-1)
    a072543_list = [x | x <- [0..], a054055 x == a000030 x]
    -- Reinhard Zumkeller, Apr 25 2012
    
  • Maple
    for i from 1 to 10 do A[i]:= i-1 od:
    count:= 10:
    for i from 1 to 9 do P[i]:= [seq([j],j=0..i)]; od:
    for d from 2 to 4 do
      for x from 1 to 9 do
        for p in P[x] do
          count:= count+1;
          A[count]:= add(p[k]*10^(k-1),k=1..d-1) + x*10^(d-1);
        od:
        P[x]:= [seq(seq([op(v),t], v=P[x]),t=0..x)];
      od
    od:
    seq(A[i],i=1..count); # Robert Israel, Feb 01 2015
  • Mathematica
    Select[Range[0,250],Max[IntegerDigits[#]]==First[IntegerDigits[#]]&] (* Harvey P. Dale, Apr 28 2016 *)
  • PARI
    is(n)=n=digits(n); !#n || n[1]==vecmax(n) \\ Charles R Greathouse IV, Jan 02 2014
    
  • PARI
    a(n)={d = 0; r = 1; s = 0; i = 0; if(n == 1, 0, n-=2; while(n > sum(i=0, 9,(i+1)^d), n-=sum(i=0, 9, (i+1)^d); n++; d++); while(n >= (r+1)^d, n -= (r+1)^d; r++);s = r * 10^d; while(n, s += 10^i*(n%(r+1)); n \= (r+1); i++));s } \\ David A. Corneth, Jan 31 2015

Extensions

Offset corrected by Reinhard Zumkeller, Apr 25 2012
Previous Showing 21-30 of 110 results. Next