cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A368671 For any k >= 0, let P(k) = A368357(k) and P(-k) = A368358(k); for any n > 0, a(n) is the unique k such that P(k) = n.

Original entry on oeis.org

0, 1, 2, -1, -3, -2, -4, 3, 7, 5, 9, 4, 8, 6, 10, -5, -13, -9, -17, -7, -15, -11, -19, -6, -14, -10, -18, -8, -16, -12, -20, 11, 27, 19, 35, 15, 31, 23, 39, 13, 29, 21, 37, 17, 33, 25, 41, 12, 28, 20, 36, 16, 32, 24, 40, 14, 30, 22, 38, 18, 34, 26, 42, -21
Offset: 1

Views

Author

Rémy Sigrist, Jan 02 2024

Keywords

Comments

This sequence is a bijection from the positive integers to the integers (Z).

Examples

			P(2) = A368357(2) = 3, so a(3) = 2.
P(-4) = A368358(4) = 7, so a(7) = -4.
		

Crossrefs

Programs

  • PARI
    \\ See Links section.

Formula

Conjecture: a(n) = (-1)^(L(n)+1)*(A001045(L(n)+2) - A036044(n)/2 - 1) for n > 0 where L(n) = A000523(n). - Mikhail Kurkov, Dec 13 2024

A368357 Consider the doubly-infinite permutation P defined on page 87 of Davis et al. (1977); sequence gives the terms starting at and to the right of 1.

Original entry on oeis.org

1, 2, 3, 8, 12, 10, 14, 9, 13, 11, 15, 32, 48, 40, 56, 36, 52, 44, 60, 34, 50, 42, 58, 38, 54, 46, 62, 33, 49, 41, 57, 37, 53, 45, 61, 35, 51, 43, 59, 39, 55, 47, 63, 128, 192, 160, 224, 144, 208, 176, 240, 136, 200, 168, 232, 152, 216, 184, 248, 132, 196, 164, 228, 148, 212
Offset: 0

Views

Author

N. J. A. Sloane, Dec 31 2023

Keywords

Comments

P is a doubly-infinite sequence which is a permutation of the positive integers and contains no increasing or decreasing 4-term arithmetic progression.
A central portion of P, showing terms to the left (see A368358) and right (the present sequence) of the central 1:
..., 18, 28, 20, 24, 16, 7, 5, 6, 4, 1, 2, 3, 8, 12, 10, 14, 9, 13, 11, 15, ...
See the link for a larger portion.

Crossrefs

Cf. A003407, A368358 (the left-hand portion, reversed).
Showing 1-2 of 2 results.