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.

A230416 The infinite trunk of factorial beanstalk (A219666) with reversed subsections.

This page as a plain text file.
%I A230416 #9 Oct 30 2013 11:51:01
%S A230416 0,1,5,2,23,17,12,10,7,119,109,102,97,92,85,79,74,70,63,57,52,48,46,
%T A230416 40,35,30,28,25,719,704,693,680,670,658,648,641,630,623,612,605,597,
%U A230416 584,574,562,552,545,534,527,516,509,501,492,486,481,476,465,455,443
%N A230416 The infinite trunk of factorial beanstalk (A219666) with reversed subsections.
%C A230416 Can be viewed also as an irregular table: after the initial zero on row 0, start each row n with (n!)-1 and subtract repeatedly the sum of factorial expansion digits (A034968) to get successive terms, until the number that has already been listed [which is always (n-1)!-1] is encountered, which is not listed second time, but instead, the current row is finished and the next row starts with ((n+1)!-1), with the same process repeated.
%C A230416 Contains the terms in the infinite trunk of factorial beanstalk (A219666) listed in partially reversed manner: after the initial zero each subsequence lists A219661(n) successive terms from A219666, descending from (n!)-1 downwards.
%H A230416 Antti Karttunen, <a href="/A230416/b230416.txt">Rows 0..7, flattened</a>
%F A230416 For n < 3, a(n) = (n+1)!-1, and for n >= 3, a(n) = (k+2)!-1 if A219651(a(n-1)) is of form k!-1, otherwise just A219651(a(n-1)).
%F A230416 a(n) = A219666(A230432(n)). [Consequence of the definitions]
%e A230416 This irregular table begins as:
%e A230416 0;
%e A230416 1;
%e A230416 5, 2;
%e A230416 23, 17, 12, 10, 7;
%e A230416 119, 109, 102, 97, 92, 85, 79, 74, 70, 63, 57, 52, 48, 46, 40, 35, 30, 28, 25;
%e A230416 ...
%e A230416 After the initial zero (on row 0), each row n is A219661(n) elements long.
%o A230416 (Scheme, with _Antti Karttunen_'s IntSeq-library for memoizing definec-macro)
%o A230416 (definec (A230416 n) (cond ((< n 3) (- (A000142 (+ 1 n)) 1)) ((A219651 (A230416 (-1+ n))) => (lambda (next) (cond ((which_in_A000142? (+ 1 next)) => (lambda (k) (- (A000142 (+ k 2)) 1))) (else next))))))
%o A230416 (define (which_in_A000142? n) (and (> n 0) (let loop ((n n) (i 2)) (cond ((= 1 n) (- i 1)) ((not (zero? (modulo n i))) #f) (else (loop (/ n i) (1+ i)))))))
%Y A230416 Cf. A219666, A219661, A000142, A219651.
%Y A230416 The rows are the initial portions of every (n!-1)th row in A219659.
%Y A230416 Analogous sequence for binary system: A218616.
%K A230416 nonn,tabf
%O A230416 0,3
%A A230416 _Antti Karttunen_, Oct 22 2013