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.

A338400 Inverse boustrophedon transform of the partition numbers.

Original entry on oeis.org

1, 0, 1, -2, 2, -19, 39, -257, 1113, -6829, 42399, -299550, 2281531, -18901042, 168402645, -1608304966, 16381456532, -177291076953, 2031597803009, -24573784682206, 312883002507064, -4182938253898882, 58584703430964506, -857812167322107132, 13106404407407087063
Offset: 0

Views

Author

Pontus von Brömssen, Oct 24 2020

Keywords

Crossrefs

Programs

  • Python
    import sympy
    def A338400(n):
      T=[]
      for k in range(n+1):
        T.append(sympy.npartitions(k))
        T.reverse()
        for i in range(k):
          T[i+1]=T[i]-T[i+1]
      return T[-1]
    
  • Python
    from itertools import islice, count, accumulate
    from operator import sub
    from sympy import npartitions
    def A338400_gen(): # generator of terms
        blist = tuple()
        for i in count(0):
            yield (blist := tuple(accumulate(reversed(blist),func=sub,initial=npartitions(i))))[-1]
    A338400_list = list(islice(A338400_gen(),20)) # Chai Wah Wu, Jun 10 2022

Formula

a(n) = Sum_{k=0..n} (-1)^(n-k) * binomial(n,k) * A000111(n-k) * A000041(k).