login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A026568 Irregular triangular array T read by rows: T(i,0) = T(i,2i) = 1 for i >= 0; T(i,1) = T(i,2i-1) = [ (i+1)/2 ] for i >= 1; and for i >= 2 and 2 <=j <= i - 2, T(i,j) = T(i-1,j-2) + T(i-1,j-1) + T(i-1,j) if i + j is even, T(i,j) = T(i-1,j-2) + T(i-1,j) if i + j is odd. 25

%I #23 Dec 28 2015 16:46:03

%S 1,1,1,1,1,1,3,1,1,1,2,4,5,4,2,1,1,2,7,7,13,7,7,2,1,1,3,8,16,20,27,20,

%T 16,8,3,1,1,3,12,19,44,43,67,43,44,19,12,3,1,1,4,13,34,56,106,111,153,

%U 111,106,56,34,13,4,1,1,4,18,38,103,140,273

%N Irregular triangular array T read by rows: T(i,0) = T(i,2i) = 1 for i >= 0; T(i,1) = T(i,2i-1) = [ (i+1)/2 ] for i >= 1; and for i >= 2 and 2 <=j <= i - 2, T(i,j) = T(i-1,j-2) + T(i-1,j-1) + T(i-1,j) if i + j is even, T(i,j) = T(i-1,j-2) + T(i-1,j) if i + j is odd.

%C T(n, k) = number of strings s(0)..s(n) such that s(0) = 0, s(n) = n - k, |s(i)-s(i-1)| <= 1 if s(i-1) is even, |s(i)-s(i-1)| = 1 if s(i-1) is odd, for 1 <= i <= n.

%H Clark Kimberling, <a href="/A026568/b026568.txt">Rows 0..100, flattened</a>

%H <a href="/index/Pas#Pascal">Index entries for triangles and arrays related to Pascal's triangle</a>

%e First 5 rows:

%e 1

%e 1 1 1

%e 1 1 3 1 1

%e 1 2 4 5 4 2 1

%e 1 2 7 7 13 7 7 2 1

%t z = 12; t[n_, 0] := 1; t[n_, 1] := Floor[(n + 1)/2]; t[n_, k_] := t[n, k] = Which[k == 2 n, 1, k == 2 n - 1, Floor[(n + 1)/2], EvenQ[n + k], t[n - 1, k - 2] + t[n - 1, k - 1] + t[n - 1, k], OddQ[n + k], t[n - 1, k - 2] + t[n - 1, k]]; u = Table[t[n, k], {n, 0, z}, {k, 0, 2 n}];

%t TableForm[u] (* A026568 array *)

%t Flatten[u] (* A026568 sequence *)

%o (PARI) T(k,n)=if(n<0||n>2*k,0,if(n==0||n==2*k,1,if(k>0&&(n==1||n==2*k-1),(k+1)\2,T(k-1,n-2)+T(k-1,n)+if((k+n)%2==0,T(k-1,n-1))))) \\ _Ralf Stephan_

%Y Cf. A026519, A026536, A026552, A026584, A027926.

%Y Cf. T(n,n) is A026569.

%K nonn,tabf

%O 1,7

%A _Clark Kimberling_

%E Updated by _Clark Kimberling_, Aug 28 2014

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 05:56 EDT 2024. Contains 371964 sequences. (Running on oeis4.)