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.

A356185 The difference between number of even and number of odd Grassmannian permutations of size n.

Original entry on oeis.org

1, 1, 0, 1, 0, 3, 2, 9, 8, 23, 22, 53, 52, 115, 114, 241, 240, 495, 494, 1005, 1004, 2027, 2026, 4073, 4072, 8167, 8166, 16357, 16356, 32739, 32738, 65505, 65504, 131039, 131038, 262109, 262108, 524251, 524250, 1048537, 1048536, 2097111, 2097110, 4194261, 4194260
Offset: 0

Views

Author

Per W. Alexandersson, Jul 28 2022

Keywords

Comments

A permutation is Grassmann if it has at most one descent. A closed-form formula was proved by J. B. Gil and J. A. Tomasko.

Examples

			For n=3, 123, 231, 312 are even Grassmann permutations, and 132, 213 are the odd ones. Hence a(3) = 1.
		

Crossrefs

Bisections give: A005803 (even part), A183155 (odd part).

Programs

  • Mathematica
    Table[2^Floor[1 + (n - 1)/2] - n, {n, 1, 80}]

Formula

a(n) = 2^(1+floor((n-1)/2))-n.
From Alois P. Heinz, Jul 28 2022: (Start)
G.f.: -(4*x^3-3*x^2-x+1)/((2*x^2-1)*(x-1)^2).
a(n) = A000325(n) - A233411(n) = A060546(n) - n = 2^ceiling(n/2) - n.
a(n) = A000325(n) - 2*A032085(n) = A000325(n) - 2*A122746(n-2) for n>=2. (End)