A350438 a(n) is the number of integers that can be represented in a 7-segment display by using only n segments (version A010371).
0, 0, 1, 1, 3, 6, 11, 14, 23, 39, 71, 118, 195, 317, 537, 906, 1533, 2550, 4261, 7119, 11973, 20073, 33650, 56277, 94286, 157960, 264843, 443656, 743269, 1244915, 2085970, 3494922, 5855965, 9810370, 16436113, 27536138, 46135634, 77295509, 129501787, 216963199, 363500178
Offset: 0
Examples
a(7) = 14 since -111, -71, -41, -17, -14, -9, -6, 8, 12, 13, 15, 21, 31 and 51 are displayed by 7 segments. __ __ __ | | | __ | | | __ |__| | __ | | | __ | |__| | | | | | | | | | | | (-111) (-71) (-41) (-17) (-14) __ __ __ __ __ __ __ __ |__| __ |__ |__| | __| | __| | |__ __| | __| |__| |__| | |__ | __| | __| |__ | (-9) (-6) (8) (12) (13) (15) (21) __ __ __| | |__ | __| | __| | (31) (51)
Links
Programs
-
Mathematica
P[x_]:=x^2+2x^4+3x^5+3x^6+x^7; c[n_]:=Coefficient[Sum[P[x]^k, {k, Max[1, Ceiling[n/7]], Floor[n/2]}], x, n]; b[n_]:=c[n]-c[n-6]; (* A331530 *) a[n_]:=If[n!=7,b[n]+b[n-1],14]; Array[a, 41, 0]
Comments