OFFSET
1,3
COMMENTS
The n-th term of this sequence a(n) = AR(n) gives the total number of aperiodic k-reverses of n for k=1,2,...,n. It is the sum of the n-th row of the 'AR(n,k)' triangle from sequence A180279.
See sequence A180279 for the definition of an aperiodic k-reverse of n.
Briefly, a k-reverse of n is a k-composition of n whose reverse is cyclically equivalent to itself, and an aperiodic k-reverse of n is a k-reverse of n which is also aperiodic.
For example a(6)=21 because there are 21 aperiodic k-reverses of n=6 for k=1,2,3,4,5, or 6.
They are, in cyclically equivalent classes: {6}, {15,51}, {24,42}, {114,411,141}, {1113,3111,1311,1131}, {1122,2112,2211,1221},{11112,21111,12111,11211,11121}.
REFERENCES
John P. McSorley: Counting k-compositions with palindromic and related structures. Preprint, 2010.
LINKS
Andrew Howroyd, Table of n, a(n) for n = 1..200
FORMULA
a(n) = n * A056493(n) / 2. - Andrew Howroyd, Oct 07 2017
MATHEMATICA
a[n_] := n*Sum[MoebiusMu[n/d]*If[OddQ[d], 2, 3]*2^Quotient[d-1, 2], {d, Divisors[n]}]/2;
Array[a, 40] (* Jean-François Alcover, Jul 06 2018, after Andrew Howroyd *)
PROG
(PARI)
a(n) = n * sumdiv(n, d, moebius(n/d) * if(d%2, 2, 3) * 2^((d-1)\2)) / 2; \\ Andrew Howroyd, Oct 07 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
John P. McSorley, Aug 27 2010
EXTENSIONS
Terms a(11) and beyond from Andrew Howroyd, Oct 07 2017
STATUS
approved