login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A180880 Number of permutations p() of 1..n+3 with centered difference p(i+1)-p(i-1) < 0 exactly twice 1
6, 50, 360, 1960, 10010, 45738, 203616, 854700, 3560172, 14299428, 57595824, 226022940, 895687650, 3473777450, 13672916400, 52745436172, 207268333844, 798176908620, 3139574496240, 12092845015888, 47667323303236 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Column 3 of A180887

LINKS

R. H. Hardin, Table of n, a(n) for n=1..100

PROG

/* bc , formula r(n, k) from A000892 */

define factorial(n) {

auto prod;

prod=1;

while(n>=2)prod*=n--;

return prod;

}

define binomial(n, i) {

if(i<0||i>n)return 0;

return factorial(n)/(factorial(i)*factorial(n-i));

}

define r(n, k) {

auto j, sum;

sum=0;

for(j=0; j<=k+1; j++) {

sum+=(-1)^j*(k+1-j)^n*binomial(n+1, j);

}

return sum;

}

define t(n, k) {

auto sum, i;

sum=0;

for(i=0; i<=(k-1); i++)sum+=r((n+k)/2, i)*r((n+k)-(n+k)/2, (k-1)-i);

return sum*binomial((n+k), (n+k)/2);

}

for(n=1; n<=100; n++) {

print n, " ", t(n, 3), "\n";

}

quit

CROSSREFS

Sequence in context: A220887 A213807 A223816 * A027330 A090409 A212233

Adjacent sequences:  A180877 A180878 A180879 * A180881 A180882 A180883

KEYWORD

nonn

AUTHOR

R. H. Hardin Sep 23 2010

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified May 18 14:19 EDT 2013. Contains 225419 sequences.