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

A306360 Numbers k such that A101337(k)/k is an integer.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 153, 370, 371, 407, 459, 1634, 8208, 9474, 13598, 48495, 54748, 92727, 93084, 119564, 174961, 306979, 548834, 1741725, 3194922, 4210818, 9800817, 9926315, 12720569, 24678050, 24678051, 88593477, 144688641, 146511208
Offset: 1

Views

Author

Ctibor O. Zizka, Feb 10 2019

Keywords

Comments

A005188 is a subsequence of this sequence.
Sequence is finite. In particular, a(n) < 10^60. If k >= 10^60, then A101337(k) < k. - Chai Wah Wu, Feb 26 2019

Examples

			For k = 1, (1^1)/1 = 1;
for k = 459, (4^3 + 5^3 + 9^3) / 459 = 2.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10^6], IntegerQ[Total[IntegerDigits[#]^IntegerLength[#]]/#] &] (* Michael De Vlieger, Aug 01 2019 *)
  • PARI
    isok(n) = frac(A101337(n)/n) == 0; \\ Michel Marcus, Feb 11 2019
    
  • PARI
    select( is(n)=!(A101337(n)%n), [0..999]) \\ M. F. Hasler, Nov 17 2019
    
  • Python
    A306360_list, k = [], 1
    while k < 10**9:
        s = str(k)
        l, c = len(s), 0
        for i in range(l):
            c = (c + int(s[i])**l) % k
        if c == 0:
            A306360_list.append(k)
        k += 1 # Chai Wah Wu, Feb 26 2019

Extensions

a(22)-a(37) from Daniel Suteu, Feb 10 2019

A306354 a(n) = gcd(n, A101337(n)).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 2, 1, 4, 1, 2, 1, 4, 1, 3, 1, 1, 3, 1, 1, 9, 1, 1, 3, 8, 1, 2, 1, 4, 1, 2, 1, 16, 1, 25, 1, 1, 1, 1, 5, 1, 1, 1, 1, 12, 1, 2, 9, 4, 1, 6, 1, 4, 3, 7, 1, 1, 1, 1, 1, 1, 7, 1, 1, 16, 1, 2, 1, 4, 1, 2, 1, 8, 1, 9
Offset: 1

Views

Author

Ctibor O. Zizka, Feb 09 2019

Keywords

Comments

A101337(n) / n = r, r an integer, gives A306360. A101337(n) / n = 1 gives A005188. n / A101337(n) = s, s an integer, gives A306361. The motivation for this sequence was the question as to which numbers n have the property A101337(n) / n = r and the property n / A101337(n) = s?

Examples

			For n = 24, a(24) = gcd(24, 2*2 + 4*4) = gcd(24,20) = 4, thus a(24) = 4;
for n = 153, a(153) = gcd(153, 1*1*1 + 5*5*5 + 3*3*3) = gcd(153,153) = 153, thus a(153) = 153.
		

Crossrefs

Programs

  • Mathematica
    Array[GCD[#1, Total[#2^Length[#2]]] & @@ {#, IntegerDigits@ #} &, 90] (* Michael De Vlieger, Feb 09 2019 *)
  • PARI
    a(n) = my(d=digits(n)); gcd(n, sum(i=1, #d, d[i]^#d)); \\ Michel Marcus, Feb 12 2019
    
  • Python
    from math import gcd
    def A306354(n): return gcd(n,sum(int(d)**len(str(n)) for d in str(n))) # Chai Wah Wu, Jan 26 2022

A306361 Numbers k divisible by A101337(k) (narcissistic function).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 20, 50, 100, 110, 111, 153, 200, 221, 370, 371, 407, 500, 702, 1000, 1010, 1011, 1020, 1100, 1101, 1110, 1121, 1122, 1634, 2000, 2322, 4104, 5000, 8208, 9474, 10000, 10010, 10011, 10100, 10101, 10110, 11000, 11001, 11010, 11022, 11100, 11122, 11220, 12012, 12110, 12210, 12320, 14550
Offset: 1

Views

Author

Ctibor O. Zizka, Feb 10 2019

Keywords

Comments

A005188 is a subsequence of this sequence.
Numbers in A007088 with either 3 or 9 ones are terms of this sequence. - Chai Wah Wu, Feb 26 2019
For all N in A007088 we have A101337(N) = A007953(N) = number of digits '1'; whenever this equals 2^k*5^m (k, m >= 0) and N ends in max(k,m) '0's, then N is also in this sequence. - M. F. Hasler, Nov 18 2019

Examples

			For k = 20, 20 / (2^2 + 0^2) = 5;
for k = 221, 221 / (2^3 + 2^3 + 1^3) = 13.
		

Crossrefs

Programs

A329291 Ratio A101337(m)/m for m = A306360(n), numbers dividing the value of their narcissistic function.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 7, 2, 1, 1, 1, 5, 4, 4, 1, 1, 3, 1, 1, 1, 4, 1, 1, 1, 2, 1, 1, 1, 1, 3, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 4, 1, 1, 3, 2, 1, 4, 1, 1, 1, 4, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

M. F. Hasler, Nov 17 2019

Keywords

Comments

A101337 (sum of digits raised to power A055642(n) = #digits(n)) is sometimes called the narcissistic function for base 10.
This sequence has the same finite number of elements as A306360.

Crossrefs

Cf. A101337, A306360, A329292 (least index i with a(i) = n = 1, 2, 3...).

Programs

Formula

a(n) = A101337(A306360(n))/A306360(n).

Extensions

a(108)-a(109) from Giovanni Resta, Nov 18 2019

A329292 Least number m > 0 such that A101337(m)/m = n, or 0 if no such m exists.

Original entry on oeis.org

1, 459, 3194922, 174961, 119564, 0, 13598
Offset: 1

Views

Author

M. F. Hasler, Nov 17 2019

Keywords

Comments

Subsequence of A306360, therefore also finite.

Crossrefs

Programs

Formula

a(n) = min { m in A306360 | A101337(m)/m = n }.

Extensions

a(6)-a(7) from Chai Wah Wu, Nov 18 2019 using b-file of A306360

A115026 Limiting value of n under iteration of "sum of the digits raised to the power of the number of digits of n" (A101337).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 2, 5, 1, 370, 370, 370, 370, 370, 1, 4, 5, 8, 1, 4, 370, 370, 370, 1, 370, 9, 1, 1, 370, 370, 370, 370, 370, 370, 370, 370, 370, 4, 370, 1, 370, 370, 370, 370, 1, 370, 370, 370, 370, 370, 370, 370, 370, 370, 160, 370, 370, 370, 370, 370, 370
Offset: 1

Views

Author

Sergio Pimentel, Feb 24 2006

Keywords

Comments

Iterate A101337 starting at n until reaching a constant value (like 370) or a cycle (like 160, 217, 352, 160, ...). In the latter case, a(n) takes the smallest value in the cycle (e.g., a(59) = 160). Since k*9^k < 10^k for all k > 34, each number n is guaranteed to yield a smaller number a(n) if n > 10^34, so every number reaches a constant or a cycle under this sequence.
Conjecture: no term is greater than 370. - Harvey P. Dale, Jun 08 2022

Examples

			a(89)=370 since:
89 (2 digits): 8^2 + 9^2 = 145,
145 (3 digits): 1^3 + 4^3 + 5^3 = 190,
190 (3 digits): 1^3 + 9^3 + 0^3 = 730,
730 (3 digits): 7^3 + 3^3 + 0^3 = 370,
370 (3 digits): 3^3 + 7^3 + 0^3 = 370, etc.
So a(89) = 370 since 370 is a fixed point of A101337.
		

Crossrefs

Cf. A101337.

Programs

  • Mathematica
    Table[Min[FindTransientRepeat[NestList[Total[IntegerDigits[#]^IntegerLength[#]]&,n,20],3][[2]]],{n,70}] (* Harvey P. Dale, Jun 08 2022 *)

A329659 Largest number m > 0 such that A101337(m)/m = n, or 0 if no such m exists.

Original entry on oeis.org

115132219018763992565095597973971522401, 13384899942524140745922870, 18935132531699388, 2098649524599800996, 119564, 0, 13598
Offset: 1

Views

Author

Chai Wah Wu, Nov 18 2019

Keywords

Crossrefs

A007088 The binary numbers (or binary words, or binary vectors, or binary expansion of n): numbers written in base 2.

Original entry on oeis.org

0, 1, 10, 11, 100, 101, 110, 111, 1000, 1001, 1010, 1011, 1100, 1101, 1110, 1111, 10000, 10001, 10010, 10011, 10100, 10101, 10110, 10111, 11000, 11001, 11010, 11011, 11100, 11101, 11110, 11111, 100000, 100001, 100010, 100011, 100100, 100101, 100110, 100111
Offset: 0

Views

Author

Keywords

Comments

List of binary numbers. (This comment is to assist people searching for that particular phrase. - N. J. A. Sloane, Apr 08 2016)
Or, numbers that are sums of distinct powers of 10.
Or, numbers having only digits 0 and 1 in their decimal representation.
Complement of A136399; A064770(a(n)) = a(n). - Reinhard Zumkeller, Dec 30 2007
From Rick L. Shepherd, Jun 25 2009: (Start)
Nonnegative integers with no decimal digit > 1.
Thus nonnegative integers n in base 10 such that kn can be calculated by normal addition (i.e., n + n + ... + n, with k n's (but not necessarily k + k + ... + k, with n k's)) or multiplication without requiring any carry operations for 0 <= k <= 9. (End)
For n > 1: A257773(a(n)) = 10, numbers that are Belgian-k for k=0..9. - Reinhard Zumkeller, May 08 2015
For any integer n>=0, find the binary representation and then interpret as decimal representation giving a(n). - Michael Somos, Nov 15 2015
N is in this sequence iff A007953(N) = A101337(N). A028897 is a left inverse. - M. F. Hasler, Nov 18 2019
For n > 0, numbers whose largest decimal digit is 1. - Stefano Spezia, Nov 15 2023

Examples

			a(6)=110 because (1/2)*((1-(-1)^6)*10^0 + (1-(-1)^3)*10^1 + (1-(-1)^1)*10^2) = 10 + 100.
G.f. = x + 10*x^2 + 11*x^3 + 100*x^4 + 101*x^5 + 110*x^6 + 111*x^7 + 1000*x^8 + ...
.
  000    The numbers < 2^n can be regarded as vectors with
  001    a fixed length n if padded with zeros on the left
  010    side. This represents the n-fold Cartesian product
  011    over the set {0, 1}. In the example on the left,
  100    n = 3. (See also the second Python program.)
  101    Binary vectors in this format can also be seen as a
  110    representation of the subsets of a set with n elements.
  111    - _Peter Luschny_, Jan 22 2024
		

References

  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See p. 21.
  • Jan Gullberg, Mathematics from the Birth of Numbers, W. W. Norton & Co., NY & London, 1997, §2.8 Binary, Octal, Hexadecimal, p. 64.
  • Manfred R. Schroeder, "Fractals, Chaos, Power Laws", W. H. Freeman, 1991, p. 383.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

The basic sequences concerning the binary expansion of n are this one, A000120 (Hammingweight: sum of bits), A000788 (partial sums of A000120), A000069 (A000120 is odd), A001969 (A000120 is even), A023416 (number of bits 0), A059015 (partial sums). Bisections A099820 and A099821.
Cf. A028897 (convert binary to decimal).

Programs

  • Haskell
    a007088 0 = 0
    a007088 n = 10 * a007088 n' + m where (n',m) = divMod n 2
    -- Reinhard Zumkeller, Jan 10 2012
    
  • Maple
    A007088 := n-> convert(n, binary): seq(A007088(n), n=0..50); # R. J. Mathar, Aug 11 2009
  • Mathematica
    Table[ FromDigits[ IntegerDigits[n, 2]], {n, 0, 39}]
    Table[Sum[ (Floor[( Mod[f/2 ^n, 2])])*(10^n) , {n, 0, Floor[Log[2, f]]}], {f, 1, 100}] (* José de Jesús Camacho Medina, Jul 24 2014 *)
    FromDigits/@Tuples[{1,0},6]//Sort (* Harvey P. Dale, Aug 10 2017 *)
  • PARI
    {a(n) = subst( Pol( binary(n)), x, 10)}; /* Michael Somos, Jun 07 2002 */
    
  • PARI
    {a(n) = if( n<=0, 0, n%2 + 10*a(n\2))}; /* Michael Somos, Jun 07 2002 */
    
  • PARI
    a(n)=fromdigits(binary(n),10) \\ Charles R Greathouse IV, Apr 08 2015
    
  • Python
    def a(n): return int(bin(n)[2:])
    print([a(n) for n in range(40)]) # Michael S. Branicky, Jan 10 2021
    
  • Python
    from itertools import product
    n = 4
    for p in product([0, 1], repeat=n): print(''.join(str(x) for x in p))
    # Peter Luschny, Jan 22 2024

Formula

a(n) = Sum_{i=0..m} d(i)*10^i, where Sum_{i=0..m} d(i)*2^i is the base 2 representation of n.
a(n) = (1/2)*Sum_{i>=0} (1-(-1)^floor(n/2^i))*10^i. - Benoit Cloitre, Nov 20 2001
a(n) = A097256(n)/9.
a(2n) = 10*a(n), a(2n+1) = a(2n)+1.
G.f.: 1/(1-x) * Sum_{k>=0} 10^k * x^(2^k)/(1+x^(2^k)) - for sequence as decimal integers. - Franklin T. Adams-Watters, Jun 16 2006
a(A000290(n)) = A001737(n). - Reinhard Zumkeller, Apr 25 2009
a(n) = Sum_{k>=0} A030308(n,k)*10^k. - Philippe Deléham, Oct 19 2011
For n > 0: A054055(a(n)) = 1. - Reinhard Zumkeller, Apr 25 2012
a(n) = Sum_{k=0..floor(log_2(n))} floor((Mod(n/2^k, 2)))*(10^k). - José de Jesús Camacho Medina, Jul 24 2014

A113019 (Number of digits of n) raised to the power of (the digital root of n).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 2, 4, 8, 16, 32, 64, 128, 256, 512, 2, 4, 8, 16, 32, 64, 128, 256, 512, 2, 4, 8, 16, 32, 64, 128, 256, 512, 2, 4, 8, 16, 32, 64, 128, 256, 512, 2, 4, 8, 16, 32, 64, 128, 256, 512, 2, 4, 8, 16, 32
Offset: 0

Views

Author

Alexandre Wajnberg, Jan 03 2006

Keywords

Comments

n=1 and 32 are fixed points. Are there any others?
First occurrence of k: 1,10,100,11,10000,100000,1000000,12,101,1000000000, ..., . - Robert G. Wilson v

Examples

			a(0) = 1^0 = 1.
a(9) = 1^9 = 1.
a(10) = 2^(1+0) = 2.
a(89) = 2^(8+9=17=>1+7) = 2^8 = 256.
		

Crossrefs

Cf. A101337.

Programs

  • Maple
    A113019 := proc(n) if(n=0)then return 1:fi: return length(n)^(((n-1) mod 9) + 1): end: seq(A113019(n),n=0..100); # Nathaniel Johnston, May 04 2011
  • Mathematica
    f[n_] := If[n == 0, 1, Floor[ Log[10, 10n]]^(Mod[n - 1, 9] + 1)]; Table[ f[n], {n, 0, 73}] (* Robert G. Wilson v, Jan 04 2006 *)
  • PARI
    apply( A113019(n)=(logint(n+!n,10)+1)^((n-1)%9+1), [0..99]) \\ M. F. Hasler, Nov 17 2019

Formula

a(ijk...) [m digits ijk...] = m^(i+j+k+..[one digit])

A113009 {Sum of the digits of n} raised to the power {number of digits of n}.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 36, 49, 64, 81, 100, 121, 144, 169, 196
Offset: 0

Views

Author

Alexandre Wajnberg, Jan 03 2006

Keywords

Comments

Fixed points are: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 81, 5832. Are there any others?
Fixed points include: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 81, 512, 2401. There are no other fixed points less than 10^1000. - Chai Wah Wu, Feb 28 2019

Examples

			a(9)=9^1=9
a(19)=(1+9)^2=100
a(101)=(1+0+1)^3=8
		

Crossrefs

Cf. A101337.

Programs

  • Mathematica
    Join[{0},Table[Total[IntegerDigits[n]]^IntegerLength[n],{n,100}]] (* Harvey P. Dale, Nov 09 2014 *)
  • Python
    def A113009(n):
        return sum(int(d) for d in str(n))**len(str(n)) # Chai Wah Wu, Feb 28 2019

Formula

a(ijk...)[m digits ijk...]=(i+j+k)^m
Showing 1-10 of 20 results. Next