A324015 Number of nonempty subsets of {1, ..., n} containing no two cyclically successive elements.
0, 1, 2, 3, 6, 10, 17, 28, 46, 75, 122, 198, 321, 520, 842, 1363, 2206, 3570, 5777, 9348, 15126, 24475, 39602, 64078, 103681, 167760, 271442, 439203, 710646, 1149850, 1860497, 3010348, 4870846, 7881195, 12752042, 20633238, 33385281, 54018520, 87403802
Offset: 0
Keywords
Examples
The a(6) = 17 stable subsets: {1}, {2}, {3}, {4}, {5}, {6}, {1,3}, {1,4}, {1,5}, {2,4}, {2,5}, {2,6}, {3,5}, {3,6}, {4,6}, {1,3,5}, {2,4,6}.
Programs
-
Mathematica
stabsubs[g_]:=Select[Rest[Subsets[Union@@g]],Select[g,Function[ed,UnsameQ@@ed&&Complement[ed,#]=={}]]=={}&]; Table[Length[stabsubs[Partition[Range[n],2,1,1]]],{n,0,10}]
Formula
For n <= 3, a(n) = n. Otherwise, a(n) = a(n - 1) + a(n - 2) + 1.
Comments