OFFSET
1,2
COMMENTS
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..10000
EXAMPLE
Irregular triangle by consecutive odds and evens.
1, 3,
4, 6,
7, 9, 11,
12, 14, 16, 18,
19, 21, 23, 25, 27, 29,
30, 32, 34, 36, 38, 40, 42, 44,
etc.
Hence the unknown sequence b(n)=2, 2, 3, 4, 6, 8, 12, 15,... .
MATHEMATICA
$RecursionLimit = 1000; b[n_, i_, t_] := b[n, i, t] = If[n == 0, If[t == 0, 1, 0], If[i<1, 0, b[n, i-1, t]+If[i>n, 0, b[n-i, i, t-If[t>0 && PrimeQ[i], 1, 0]]]]]; a[n_] := a[n] = Module[{k}, For[k=a[n-1], b[k, k, n]<n, k++]; k]; a[0]=0; A236019 = Table[a[n], {n, 0, 100}] ; A236444 = Complement[Range[A236019 // Last], A236019] (* Jean-François Alcover, Dec 17 2014, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Paul Curtz, Jan 26 2014
EXTENSIONS
Offset corrected by Michel Marcus, Feb 12 2018
STATUS
approved