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!)
A308431 For any Gaussian integer z, let f(z) = z / (1+i) when z is a multiple of 1+i and f(z) = z+1 otherwise (where i denotes the imaginary unit). a(n) gives the number of iterations of the map f, starting with n, needed to reach a cycle. 1
0, 2, 1, 6, 5, 9, 8, 11, 10, 10, 9, 12, 11, 14, 13, 11, 10, 15, 14, 12, 11, 14, 13, 18, 17, 15, 14, 19, 18, 21, 20, 10, 9, 22, 21, 11, 10, 13, 12, 17, 16, 14, 13, 18, 17, 20, 19, 15, 14, 21, 20, 16, 15, 18, 17, 21, 20, 19, 18, 22, 21, 24, 23, 14, 13, 25, 24 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
COMMENTS
Iterating the map f always ends in one of the following cycles: (0) or (-i, -i+1).
We can build a variant of this sequence by replacing the constant 1+i appearing in the name by any Gaussian integer, say d, such that gcd(Re(d), Im(d)) = 1 and norm(d) > 1.
This sequence has similarities with A061313.
LINKS
EXAMPLE
For n = 4:
- 4 is a multiple of 1+i, hence f(4) = 4/(1+i) = 2-2*i,
- 2-2*i is a multiple of 1+i, hence f(2-2*i) = (2-2*i)/(1+i) = -2*i,
- -2*i is a multiple of 1+i, hence f(-2*i) = -2*i/(1+i) = -1-i,
- -1-i is a multiple of 1+i, hence f(-1-i) = (-1-i)/(1+i) = -1,
- -1 is not multiple of 1+i, hence f(-1) = -1+1 = 0,
- 0 belongs to the cycle (0), hence a(4) = 5.
PROG
(PARI) a(z) = for (k=0, oo, if (z==0||z==-I||z==-I+1, return (k), if ((real(z)+imag(z))%2, z++, z/=(1+I))))
CROSSREFS
Cf. A061313.
Sequence in context: A011018 A346963 A156993 * A292667 A030770 A307048
KEYWORD
nonn
AUTHOR
Rémy Sigrist, May 26 2019
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 April 25 08:27 EDT 2024. Contains 371964 sequences. (Running on oeis4.)