login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A045674 Number of 2n-bead balanced binary necklaces which are equivalent to their reverse, complement and reversed complement. 12
1, 1, 2, 2, 4, 4, 6, 8, 12, 16, 20, 32, 38, 64, 72, 128, 140, 256, 272, 512, 532, 1024, 1056, 2048, 2086, 4096, 4160, 8192, 8264, 16384, 16512, 32768, 32908, 65536, 65792, 131072, 131344, 262144, 262656, 524288, 524820, 1048576, 1049600 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
FORMULA
a(2n) = a(n) + 2^(n-1), a(2n+1) = 2^n. - Ralf Stephan, Nov 01 2003
MATHEMATICA
a[0] = 1; a[n_] := a[n] = If[EvenQ[n], 2^(n/2-1) + a[n/2], 2^((n-1)/2)]; Table[a[n], {n, 0, 42}] (* Jean-François Alcover, Sep 30 2017 *)
PROG
(PARI) a(n) = if(n<1, n==0, my(t=0, r=n); while(r%2==0, r=r/2; t+=2^(r-1)); t + 2^(r\2)); \\ Andrew Howroyd, Sep 29 2017
CROSSREFS
Cf. A045654.
Sequence in context: A094858 A327851 A029940 * A276065 A325253 A143483
KEYWORD
nonn
AUTHOR
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 28 14:33 EDT 2024. Contains 371254 sequences. (Running on oeis4.)