This site is supported by donations to The OEIS Foundation.

 Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing. Other ways to donate

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A078734 Start with 1,2, concatenate 2^k previous terms and change last term as follows: 1->2, 2->3, 3->1. 1
 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 2, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 3, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 2, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 2, 1, 2, 1, 3, 1, 2, 1, 1, 1, 2, 1, 3, 1, 2, 1, 3, 1, 2, 1, 3, 1, 2, 1, 1, 1 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 LINKS Andrew Howroyd, Table of n, a(n) for n = 1..1024 FORMULA Sum_{k=1..n} a(k))/n -> 1.57.... Multiplicative with a(2^e) = (e mod 3) + 1, a(p^e) = 1 for odd prime p. - Andrew Howroyd, Jul 31 2018 EXAMPLE Concatenating the first 2 terms 1,2 -> 1,2,1,2 and changing 2->3 gives the first 4 terms: 1,2,1,3. Concatenating those first 4 terms ->1,2,1,3,1,2,1,3 and changing 3->1 gives the first 8 terms: 1,2,1,3,1,2,1,1. PROG (PARI) seq(n)={my(v=[1, 2]); while(#v < n, v=concat(v, v); v[#v] = v[#v] % 3 + 1); vector(n, i, v[i])} \\ Andrew Howroyd, Jul 31 2018 (PARI) a(n) = valuation(n, 2) % 3 + 1; \\ Andrew Howroyd, Jul 31 2018 (MAGMA) [Valuation(n, 2) mod 3 + 1: n in [1..100]]; // Vincenzo Librandi, Aug 01 2018 CROSSREFS Cf. A056832, A035263. Sequence in context: A092412 A265578 A279288 * A028293 A092782 A119647 Adjacent sequences:  A078731 A078732 A078733 * A078735 A078736 A078737 KEYWORD nonn,mult AUTHOR Benoit Cloitre, Dec 21 2002 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.

Last modified December 13 22:55 EST 2019. Contains 329974 sequences. (Running on oeis4.)