A325904 Generator sequence for A100982.
1, 0, -3, -8, 15, -91, -54, 2531, -17021, 43035, -66258, 1958757, -24572453, 146991979, -287482322, -3148566077, 35506973089, -198639977241, 1006345648929, -8250266425561, 76832268802555, -517564939540551, 1890772860334557, 3323588929061820, -104547561696315008, 907385094824827328, -6313246535826877248
Offset: 0
Keywords
Links
- Mike Winkler, The algorithmic structure of the finite stopping time behavior of the 3x + 1 function, arXiv:1709.03385 [math.GM], 2017.
Programs
-
Python
import math numberOfTerms = 20 L6 = [1,0] def c(n): return math.floor(n/(math.log2(3)-1)) def p(a,b): return math.factorial(a)/(math.factorial(a-b)*math.factorial(b)) def anotherTerm(newTermCount): global L6 for a in range(newTermCount+1-len(L6)): y = len(L6) newElement = 0 for k in range(y): newElement -= int(L6[k]*p(c(y)+y-k-2, c(y)-2)) L6.append(newElement) anotherTerm(numberOfTerms) print("A325904") for a in range(numberOfTerms+1): print(a, "|", L6[a])
-
SageMath
@cached_function def a(n): if n < 2: return 0^n A = floor(n/(log(3, 2) - 1)) - 2 return -sum(a(k)*binomial(A + n - k, A) for k in (0..n-1)) [a(n) for n in range(100)] # Peter Luschny, Sep 10 2019
Comments