login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Row sums of triangle in A283321.
2

%I #13 Mar 16 2017 15:51:23

%S 1,2,4,22,149,1186,10807,110762,1260289,15757714,214703831,3165856882,

%T 50220944017,852735163034,15429720661279,296365775922106,

%U 6021825238479617,129039801791351842,2908148713706872999,68758376703814729154,1701649010958291917521,43990236798804135274282

%N Row sums of triangle in A283321.

%H Indranil Ghosh, <a href="/A283322/b283322.txt">Table of n, a(n) for n = 0..400</a>

%H G. N. Bakare, S. O. Makanjuola, <a href="http://kwsman.com/articles/Revised%20Bakare.pdf">Some Results on Properties of Alternating Semigroups</a>, Nigerian Journal of Mathematics and Applications Volume 24,(2015), 184-192.

%F Bakare et al. give a formula, see Theorem 3.2.

%e Row 3 of triangle A283321: 1, 3, 3, 9. So a(3) = 1 + 3 + 3 + 9 = 22. - _Indranil Ghosh_, Mar 16 2017

%t T[n_, k_]:=If[k==n, (n !/2), If[k==n - 1, n^2*(n - 1)!/2, Binomial[n,k]^2 * k !]]; t[n_,k_]:=If[n<2, 1, T[n, k]]; For[n=0, n<=20, Print[Sum[t[n, k], {k, 0, n}]," "]; n++] (* _Indranil Ghosh_, Mar 16 2017 *)

%o (PARI) T(n,k) = if(k==n, (n!/2), if(k==n - 1, n^2*(n - 1)!/2, binomial(n, k)^2 * k!));

%o t(n,k) = if(n<2, 1, T(n, k));

%o {for(n=0, 21, print1(sum(k=0, n, t(n,k)),", "))} \\ _Indranil Ghosh_, Mar 16 2017

%o (Python)

%o import math

%o f=math.factorial

%o def C(n,r): return f(n)/f(r)/f(n - r)

%o def T(n,k):

%o ....if k==n: return f(n)/2

%o ....elif k==n-1: return n**2 * f(n - 1) / 2

%o ....else: return C(n, k)**2 * f(k)

%o i=0

%o l=[]

%o for n in range(0,401):

%o ....for k in range(0, n+1):

%o ........if n<2: l+=[1,]

%o ........else: l+=[T(n,k),]

%o ....print str(i)+" "+str(sum(l))

%o ....l=[]

%o ....i+=1 # _Indranil Ghosh_, Mar 16 2017

%Y Cf. A283321.

%K nonn

%O 0,2

%A _N. J. A. Sloane_, Mar 15 2017