%I #19 Jan 15 2020 07:52:37
%S 0,1,1,0,1,2,0,0,1,0,2,0,0,3,0,0,1,0,0,2,2,0,0,2,0,2,3,0,0,1,0,2,1,0,
%T 0,0,0,3,2,0,2,1,0,1,0,0,2,0,0,0,2,0,3,0,0,0,0,0,1,1,0,0,2,0,1,6,0,0,
%U 0,0,0,2,0,0,3,0,2,0,0,0,2,0,1,1,0,0,1,0,0,0,0,0,2,0,0,4,0,1,0,0,2,0,0,1,3
%N Shadow transform of A000522.
%H Alois P. Heinz, <a href="/A072453/b072453.txt">Table of n, a(n) for n = 0..10000</a>
%H Lorenz Halbeisen and Norbert Hungerbuehler, Number theoretic aspects of a combinatorial function, Notes on Number Theory and Discrete Mathematics 5 (1999) 138-150. (<a href="http://math.berkeley.edu/~halbeis/publications/psf/seq.ps">ps</a>, <a href="http://math.berkeley.edu/~halbeis/publications/pdf/seq.pdf">pdf</a>); see Definition 7 for the shadow transform.
%H OEIS Wiki, <a href="https://oeis.org/wiki/Shadow_transform">Shadow transform</a>.
%H N. J. A. Sloane, <a href="/transforms.txt">Transforms</a>.
%p A000522 := proc(n)
%p add(n!/k!,k=0..n) ;
%p end proc:
%p shadD := proc(a)
%p local s,n ;
%p s := {} ;
%p for n from 0 to a-1 do
%p if A000522(n) mod a = 0 then
%p s := s union {n} ;
%p end if;
%p end do:
%p s ;
%p end proc:
%p A072453 := proc(a)
%p nops(shadD(a)) ;
%p end proc: # _R. J. Mathar_, Jun 24 2013
%p # second Maple program:
%p b:= proc(n) option remember; n*b(n-1)+1 end: b(0):=1:
%p a:= n-> add(`if`(irem(b(j), n)=0, 1, 0), j=0..n-1):
%p seq(a(n), n=0..150); # _Alois P. Heinz_, Jun 28 2018
%t b[n_] := b[n] = n*b[n - 1] + 1 ; b[0] = 1;
%t a[n_] := Sum[If[Mod[b[j], n] == 0, 1, 0], {j, 0, n - 1}];
%t a /@ Range[0, 104] (* _Jean-François Alcover_, Jan 15 2020, after _Alois P. Heinz_ *)
%Y Cf. A000522, A072456.
%K nonn,mult,easy
%O 0,6
%A _N. J. A. Sloane_, Aug 02 2002
%E More terms from _Christian G. Bower_, Jun 08 2005