Stacking Matryoshkas

The same split-apart nesting dolls, now with flat heads, so a smaller piece can also stand on a top half or a closed doll. Every configuration for N = 1 to 4 is drawn below.

The rules

The sequence

Further terms, N = 1…16:

2, 19, 312, 7643, 256020, 11096168, 598896401, 39139847188, 3031322144533, 273521581657006, 28358733352479982, 3339902710297719296, 442517243620250926437, 65415815270340860490360, 10712294881435175920813811, 1931132206343352778109827474

Not in the OEIS as of 2026-10-03. Without stacking the count is 2, 10, 75, 780, … (A124426, Bell(N)·Bell(N+1)). Insert the pieces from largest to smallest. Each one goes on the table or into a free slot: a flat head, an empty open bottom, the empty space inside a closed doll, or an empty top. Counting the free slots of each kind as you go gives a short recurrence. It matches a brute-force enumeration for N ≤ 5.