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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A199397 Binary XOR of 3^k as k varies from 0 to n. 3
1, 2, 11, 16, 65, 178, 619, 2784, 4929, 24482, 47371, 133872, 659713, 1196754, 5945771, 8408000, 34643073, 94509378, 313886731, 1475558352, 2552700993, 12739900146, 24581737195, 70102639264, 350315469377, 639249412322, 3139708751627, 4623469310128, 18666316402561 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

COMMENTS

Appears to be a self-convolution of an integer sequence (true for at least the initial 761 terms).

LINKS

Paul D. Hanna, Table of n, a(n) for n = 0..300

EXAMPLE

a(2) = 1 XOR 3 = 2; a(3) = 1 XOR 3 XOR 9 = 11; a(4) = 1 XOR 3 XOR 9 XOR 27 = 16.

MAPLE

A[0]:= 1:

for n from 1 to 40 do

  A[n]:= Bits:-Xor(A[n-1], 3^n)

od:

seq(A[i], i=0..40); # Robert Israel, Nov 02 2015

MATHEMATICA

FoldList[BitXor, 3^Range[0, 28]] (* Vladimir Reshetnikov, Nov 02 2015 *)

PROG

(PARI) {a(n)=if(n<0, 0, bitxor(a(n-1), 3^n))}

CROSSREFS

Cf. A199396.

Sequence in context: A272883 A257283 A091211 * A012019 A012185 A012253

Adjacent sequences:  A199394 A199395 A199396 * A199398 A199399 A199400

KEYWORD

nonn,base

AUTHOR

Paul D. Hanna, Nov 05 2011

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 February 16 09:23 EST 2019. Contains 320161 sequences. (Running on oeis4.)