login
Necklaces with n beads of 6 colors, no 2 adjacent beads the same color.
4

%I #40 Jul 02 2018 09:34:40

%S 6,15,40,165,624,2635,11160,48915,217040,976887,4438920,20346485,

%T 93900240,435970995,2034505656,9536767665,44878791360,211927736135,

%U 1003867701480,4768372070757,22706531350480,108372083629275

%N Necklaces with n beads of 6 colors, no 2 adjacent beads the same color.

%H Andrew Howroyd, <a href="/A106368/b106368.txt">Table of n, a(n) for n = 1..200</a>

%H M. Bernstein and N. J. A. Sloane, <a href="https://doi.org/10.1016/0024-3795(94)00245-9">Some canonical sequences of integers</a>, Vol. 226-228 (1995), 57-72.

%H Petros Hadjicostas, <a href="/A106368/a106368.pdf">Proof of an explicit formula for Bower's CycleBG transform</a>.

%H <a href="/index/Ne#necklaces">Index entries for sequences related to necklaces</a>

%F CycleBG transform of (6, 0, 0, 0, ...)

%F CycleBG transform T(A) = invMOEBIUS(invEULER(Carlitz(A)) + A(x^2) - A) + A.

%F Carlitz transform T(A(x)) has g.f. 1/(1-Sum_{k>0}(-1)^(k+1)*A(x^k)).

%F General formula for the CycleBG transform: T(A)(x) = A(x) - Sum_{k>=0} A(x^{2k+1}) + Sum_{k>=1} (phi(k)/k)*log(Carlitz(A)(x^k)). For a proof, see the links. (For this sequence, A(x) = 6*x.) - _Petros Hadjicostas_, Sep 16 2017

%F a(n) = (1/n) * Sum_{d | n} totient(n/d) * (5*(-1)^d + 5^d) for n > 1. - _Andrew Howroyd_, Mar 12 2017

%F G.f.: m*x - Sum_{k>=1} (phi(k)/k)*((m-1)*B(x^k)+C(x^k)) = m*x - (m-1)*x/(1-x^2) - Sum_{k>=1} (phi(k)/k)*C(x^k), where B(x) = log(1+x) and C(x) = log(1-(m-1)*x). Here m=6 is the number of colors. - _Petros Hadjicostas_, Sep 16 2017

%t a[1] = 6;

%t a[n_] := (1/n) Sum[EulerPhi[n/d]*(5*(-1)^d + 5^d), {d, Divisors[n]}];

%t Array[a, 30] (* _Jean-François Alcover_, Jul 02 2018, after _Andrew Howroyd_ *)

%o (PARI) a(n) = if(n==1, 6, sumdiv(n, d, eulerphi(n/d)*(5*(-1)^d + 5^d))/n); \\ _Andrew Howroyd_, Oct 14 2017

%Y Column 6 of A208535.

%Y Cf. A000031.

%K nonn

%O 1,1

%A _Christian G. Bower_, Apr 29 2005