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!)
 A318438 For any n >= 0 with binary expansion Sum_{k=0..w} b_k * 2^k, let h(n) = Sum_{k=0..w} b_k * (i-1)^k (where i denotes the imaginary unit); a(n) is the real part of h(n). 6
 0, 1, -1, 0, 0, 1, -1, 0, 2, 3, 1, 2, 2, 3, 1, 2, -4, -3, -5, -4, -4, -3, -5, -4, -2, -1, -3, -2, -2, -1, -3, -2, 4, 5, 3, 4, 4, 5, 3, 4, 6, 7, 5, 6, 6, 7, 5, 6, 0, 1, -1, 0, 0, 1, -1, 0, 2, 3, 1, 2, 2, 3, 1, 2, 0, 1, -1, 0, 0, 1, -1, 0, 2, 3, 1, 2, 2, 3, 1, 2 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,9 COMMENTS See A318439 for the imaginary part of h. See A318479 for the square of the modulus of h. The function h corresponds to the interpretation of the binary representation of a number in base -1+i and defines a bijection from the nonnegative integers to the Gaussian integers. The function h has nice fractal features (see scatterplot in Links section). This sequence has similarities with A316657. LINKS Rémy Sigrist, Table of n, a(n) for n = 0..10000 Rémy Sigrist, Colored scatterplot of (a(n), A318439(n)) for n = 0..2^20-1 (where the hue is function of n) Wikipedia, Base -1+/-i FORMULA a(2^k) = A009116(k) for any k >= 0. PROG (PARI) a(n) = my (d=Vecrev(digits(n, 2))); real(sum(i=1, #d, d[i]*(I-1)^(i-1))) CROSSREFS Cf. A009116, A318439 (imaginary part), A318479 (norm), A340669 (negation). Cf. A316657 (base 2+i). Sequence in context: A194298 A194306 A283325 * A294233 A121884 A079087 Adjacent sequences:  A318435 A318436 A318437 * A318439 A318440 A318441 KEYWORD sign,look,base AUTHOR Rémy Sigrist, Aug 26 2018 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 September 24 06:13 EDT 2021. Contains 347623 sequences. (Running on oeis4.)