The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A163542 The relative direction (0=straight ahead, 1=turn right, 2=turn left) taken by the type I Hilbert's Hamiltonian walk A163357 at the step n. 7
 1, 1, 2, 0, 2, 2, 1, 1, 2, 2, 0, 2, 1, 1, 0, 1, 2, 2, 1, 0, 1, 1, 2, 2, 1, 1, 0, 1, 2, 2, 0, 0, 2, 2, 1, 0, 1, 1, 2, 2, 1, 1, 0, 1, 2, 2, 1, 0, 1, 1, 2, 0, 2, 2, 1, 1, 2, 2, 0, 2, 1, 1, 2, 0, 2, 2, 1, 0, 1, 1, 2, 2, 1, 1, 0, 1, 2, 2, 0, 2, 1, 1, 2, 0, 2, 2, 1, 1, 2, 2, 0, 2, 1, 1, 0, 0, 1, 1, 2, 0, 2, 2 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,3 COMMENTS a(16*n) = a(256*n) for all n. LINKS A. Karttunen, Table of n, a(n) for n = 1..65536 FORMULA a(n) = A163241((A163540(n+1)-A163540(n)) modulo 4). MATHEMATICA HC = {L[n_ /; IntegerQ[n/2]] :> {F[n], L[n], L[n + 1], R[n + 2]},    R[n_ /; IntegerQ[(n + 1)/2]] :> {F[n], R[n], R[n + 3], L[n + 2]},    R[n_ /; IntegerQ[n/2]] :> {L[n], R[n + 1], R[n], F[n + 3]},    L[n_ /; IntegerQ[(n + 1)/2]] :> {R[n], L[n + 3], L[n], F[n + 1]},    F[n_ /; IntegerQ[n/2]] :> {L[n], R[n + 1], R[n], L[n + 3]},    F[n_ /; IntegerQ[(n + 1)/2]] :> {R[n], L[n + 3], L[n], R[n + 1]}}; a[1] = L[0]; Map[(a[n_ /; IntegerQ[(n - #)/16]] :=     Part[Flatten[a[(n + 16 - #)/16] /. HC /. HC], #]) &, Range[16]]; Part[a[#] & /@ Range[4^4] /. {L[_] -> 2, R[_] -> 1, F[_] -> 0}, 2 ;; -1] (* Bradley Klee, Aug 07 2015 *) PROG (Scheme:) (define (A163542 n) (A163241 (modulo (- (A163540 (1+ n)) (A163540 n)) 4))) CROSSREFS a(n) = A014681(A163543(n)). See also A163540. Sequence in context: A344319 A236998 A297116 * A061895 A129678 A261773 Adjacent sequences:  A163539 A163540 A163541 * A163543 A163544 A163545 KEYWORD nonn AUTHOR Antti Karttunen, Aug 01 2009 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 June 23 05:01 EDT 2021. Contains 345395 sequences. (Running on oeis4.)