login
A203420
a(n) = A203418(n)/A000178(n).
4
1, 2, 8, 20, 40, 384, 10240, 126720, 1013760, 48660480, 7612661760, 473174507520, 16701626253312, 4036421002199040, 407426244909465600, 23814785343474892800, 932976775107465707520, 26694111965427724713984, 9044593230639040844267520
OFFSET
1,2
LINKS
R. Chapman, A polynomial taking integer values, Mathematics Magazine, 29 (1996), 121.
MATHEMATICA
composite = Select[Range[100], CompositeQ]; (* A002808 *)
z = 20;
f[j_]:= composite[[j]];
v[n_]:= Product[Product[f[k] - f[j], {j, 1, k - 1}], {k, 2, n}];
d[n_]:= Product[(i-1)!, {i, 1, n}];
Table[v[n], {n, z}] (* A203418 *)
Table[v[n+1]/v[n], {n, z}] (* A203419 *)
Table[v[n]/d[n], {n, z}] (* this sequence *)
PROG
(Magma)
A002808:=[n: n in [2..250] | not IsPrime(n)];
BarnesG:= func< n | (&*[Factorial(k): k in [0..n-2]]) >;
a:= func< n | n eq 1 select 1 else (&*[(&*[A002808[k+2] - A002808[j+1]: j in [0..k]]): k in [0..n-2]])/BarnesG(n+1) >;
[a(n): n in [1..40]]; // G. C. Greubel, Feb 24 2024
(SageMath)
A002808=[n for n in (2..250) if not is_prime(n)]
def BarnesG(n): return product(factorial(j) for j in range(1, n-1))
def a(n): return product(product(A002808[k+1] - A002808[j] for j in range(k+1)) for k in range(n-1))/BarnesG(n+1)
[a(n) for n in range(1, 41)] # G. C. Greubel, Feb 24 2024
KEYWORD
nonn
AUTHOR
Clark Kimberling, Jan 02 2012
STATUS
approved