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-2 of 2 results.

A194025 Number of fixed points under iteration of sum of cubes of digits in base b.

Original entry on oeis.org

1, 2, 9, 3, 4, 7, 6, 8, 5, 8, 5, 5, 3, 3, 24, 3, 2, 9, 2, 3, 16, 5, 2, 20, 2, 2, 7, 9, 3, 14, 2, 6, 8, 4, 10, 12, 2, 8, 8, 7, 2, 12, 4, 5, 17, 5, 4, 27, 6, 5, 10, 4, 2, 11, 9, 5, 9, 6, 3, 25, 5, 6, 24, 5, 4, 17, 5, 5, 9, 10, 1, 15, 4, 3, 13, 3, 5, 19, 4, 13, 7
Offset: 2

Views

Author

Martin Renner, Aug 22 2011

Keywords

Comments

If b >= 2 and n >= 2*b^3, then S(n,3,b) < n. For each positive integer n, there is a positive integer m such that S^m(n,3,b) < 2*b^3. (Grundman/Teeple, 2001, Lemma 8 and Corollary 9.)
From Christian N. K. Anderson, May 23 2013: (Start)
1 is considered a fixed point in all bases, 0 is not.
In order for a number with d digits in base n to be a fixed point, it must satisfy the condition d*(n-1)^3 < n^d, which can only occur when d < 4 for n > 2. Because all binary numbers are "happy" (become 1 under iteration), there are no fixed points with more than 4 digits in any base. It can further be demonstrated that all 4-digit solutions begin with 1 in base n.
Unlike the number of fixed points under iteration of sum of squares of digits (A193583), this sequence contains many even numbers, and its histogram converges to a smooth distribution (approximately gamma(2.64,2.8); see "histogram" in links). (End)

Examples

			In the decimal system all integers go to (1); (153); (370); (371); (407) or (55, 250,133); (136, 244); (160, 217, 352); (919, 1459) under the iteration of sum of cubes of digits, hence there are five fixed points, two 2-cycles and two 3-cycles. Therefore a(10) = 5.
		

Crossrefs

Solutions for a(10): A046197.
Largest of the a(n) fixed points: A226026.
Related sequences for sum of squared digits: A193583, A209242.

Programs

  • Maple
    S:=proc(n,p,b) local Q,k,N,z; Q:=[n]; for k from 1 do N:=Q[k]; z:=convert(sum(N['i']^p,'i'=1..nops(N)),base,b); if not member(z,Q) then Q:=[op(Q),z]; else Q:=[op(Q),z]; break; fi; od; return Q; end:
    a:=proc(b) local F,i,A,Q,B,C; A:=[]: for i from 1 to 2*b^3 do Q:=S(convert(i,base,b),3,b); A:={op(A),Q[nops(Q)]}; od: F:={}: for i from 1 while nops(A)>0 do B:=S(A[1],3,b); C:=[seq(B[i],i=1..nops(B)-1)]: if nops(C)=1 then F:={op(F),op(C)}: fi: A:=A minus {op(B)}; od: return(nops(F)); end:
    # Martin Renner, Aug 24 2011
  • R
    #See A226026 for an optimized version
    inbase=function(n, b) { x=c(); while(n>=b) { x=c(n%%b, x); n=floor(n/b) }; c(n, x) }; yn=rep(NA, 30)
    for(b in 2:30) yn[b]=sum(sapply(1:(2*b^3), function(x) sum(inbase(x, b)^3))==1:(2*b^3)); yn # Christian N. K. Anderson, Jun 08 2013
  • Sage
    def A194025(n):
        # inefficient but straightforward
        return len([i for i in (1..2*n**3) if i==sum(d**3 for d in i.digits(base=n))]) # D. S. McNeil, Aug 23 2011
    

A336783 Integers b where the number of cycles under iteration of sum of cubes of digits in base b is exactly four.

Original entry on oeis.org

5, 90, 188
Offset: 1

Views

Author

Haiyang Wang, Aug 04 2020

Keywords

Comments

Let b > 1 be an integer, and write the base b expansion of any nonnegative integer m as m = x_0 + x_1 b + ... +x_d b^d with x_d > 0 and 0 <= x_i < b for i=0,...,d.
Consider the map S_{x^3,b}: N to N, with S_{x^3,b}(m) := x_0^3+ ... + x_d^3.
It is known that the orbit set {m,S_{x^3,b}(m), S_{x^3,b}(S_{x^3,b}(m)), ...} is finite for all m>0. Each orbit contains a finite cycle, and for a given base b, the union of such cycles over all orbit sets is finite. Let us denote by L(x^3,i) the set of bases b such that the set of cycles associated to S_{x^3,b} consists of exactly i elements. In this notation, the sequence is the set of known elements of L(x^3,4).
Meanwhile, the known terms of the sequence L(x^3,1) is {2}, L(x^3,2) is empty, and L(x^3,3) is {3, 26}. It's undetermined whether the complete sequences are finite, if so, whether the above give all terms.

Examples

			For instance, when b=5 the associated four cycles are (1),(28),(118) and (9,65,35).
		

Crossrefs

Cf. A336744 and A336762 (sum of squares of digits).

Formula

Integers b where A194025(b) + A194281(b) = 4.
Showing 1-2 of 2 results.