login
This site is supported by donations to The OEIS Foundation.

 

Logo

Annual Appeal: Please make a donation to keep the OEIS running. In 2018 we replaced the server with a faster one, added 20000 new sequences, and reached 7000 citations (often saying "discovered thanks to the OEIS").
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A007148 Number of self-complementary 2-colored bracelets (turn over necklaces) with 2n beads.
(Formerly M0774)
8
1, 2, 3, 6, 10, 20, 37, 74, 143, 284, 559, 1114, 2206, 4394, 8740, 17418, 34696, 69194, 137971, 275280, 549258, 1096286, 2188333, 4369162, 8724154, 17422652, 34797199, 69505908, 138845926, 277383872, 554189329, 1107297290, 2212558942 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

REFERENCES

N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

LINKS

Vincenzo Librandi, Table of n, a(n) for n = 1..1000

E. M. Palmer and R. W. Robinson, Enumeration of self-dual configurations Pacific J. Math., 110 (1984), 203-221.

F. Ruskey, Necklaces, Lyndon words, De Bruijn sequences, etc.

Index entries for sequences related to bracelets

F. Ruskey, Necklaces, Lyndon words, De Bruijn sequences, etc. [Cached copy, with permission, pdf format only]

FORMULA

a(n) = 2^(n-2) + (1/(4n)) * Sum_{d|n} phi(2d)*2^(n/d). - N. J. A. Sloane, Sep 25 2012

a(n) = (1/2)*(A000079(n-1) + A000013(n)).

MAPLE

# see A245558

L := proc(n, k)

    local a, j ;

    a := 0 ;

    for j in numtheory[divisors](igcd(n, k)) do

        a := a+numtheory[mobius](j)*binomial(n/j, k/j) ;

    end do:

    a/n ;

end proc:

A007148 := proc(n)

    local a, k, l;

    a := 0 ;

    for k from 1 to n do

        for l in numtheory[divisors](igcd(n, k)) do

            a := a+L(n/l, k/l)*ceil(k/2/l) ;

        end do:

    end do:

    a;

end proc:

seq(A007148(n), n=1..20) ; # R. J. Mathar, Jul 23 2017

MATHEMATICA

a[n_] := (1/2)*(2^(n-1) + Total[ EulerPhi[2*#]*2^(n/#) &  /@ Divisors[n]]/(2*n)); Table[ a[n], {n, 1, 33}] (* Jean-Fran├žois Alcover, Oct 25 2011 *)

PROG

(PARI) a(n)= (1/2) *(2^(n-1)+sumdiv(n, k, eulerphi(2*k)*2^(n/k))/(2*n))

(Python)

from sympy import divisors, totient

def a(n): return 2**(n - 2) + sum([totient(2*d)*2**(n/d) for d in divisors(n)])/(4*n)

print map(a, xrange(1, 51)) # Indranil Ghosh, Jul 24 2017

CROSSREFS

Cf. A000013, A000079, A007147.

Different from, but easily confused with, A045690 and A093371.

Sequence in context: A164047 A158291 A045690 * A093371 A003214 A123423

Adjacent sequences:  A007145 A007146 A007147 * A007149 A007150 A007151

KEYWORD

nonn,nice,easy

AUTHOR

N. J. A. Sloane

EXTENSIONS

Description corrected by Christian G. Bower

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified December 18 12:36 EST 2018. Contains 318229 sequences. (Running on oeis4.)