login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A226197 Numbers of vectors with 2*n integers such that each element is either 1 or -1, and their sum > n. 1
1, 1, 7, 9, 56, 79, 470, 697, 4048, 6196, 35443, 55455, 313912, 499178, 2804012, 4514873, 25211936, 40999516, 227881004, 373585604, 2068564064, 3414035527, 18844224462, 31278197839, 172186125456, 287191809724, 1577401391626, 2642070371194, 14483100716176, 24347999094724 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,3

LINKS

Table of n, a(n) for n=1..30.

FORMULA

a(n) = sum_{k = 1+floor(n/2)...n} binomial(2n,n-k), sum of the n/2 rightmost elements of row n of A094527. - Giovanni Resta, May 31 2013

EXAMPLE

With n=3 there are 7 vectors with sum bigger than 3:

{1, 1, 1, 1, 1, 1}

{-1, 1, 1, 1, 1, 1}

{1, -1, 1, 1, 1, 1}

{1, 1, -1, 1, 1, 1}

{1, 1, 1, -1, 1, 1}

{1, 1, 1, 1, -1, 1}

{1, 1, 1, 1, 1, -1}

So a(3) = 7.

MAPLE

A226197 := proc(n)

    add( A094527(n, k), k=1+floor(n/2)..n) ;

end proc: # R. J. Mathar, Jun 04 2013

MATHEMATICA

a[n_] := Sum[(2*n)!/((n-k)!*(n+k)!), {k, 1 + Floor[n/2], n}]; Array[a, 30] (* Giovanni Resta, May 31 2013 *)

PROG

(C)

#include <stdio.h>

long long count, n;

void addOne(long long sum, long long added) {

  if (added==n*2) {

    if (sum>n) ++count;

    return;

  }

  ++added;

  addOne(sum+1, added);

  addOne(sum-1, added);

}

int main() {

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

    count = 0;

    addOne(0, 0);

    printf("%llu, ", count);

  }

  return 0;

}

CROSSREFS

Sequence in context: A038275 A261669 A299913 * A263836 A087336 A178427

Adjacent sequences:  A226194 A226195 A226196 * A226198 A226199 A226200

KEYWORD

nonn

AUTHOR

Alex Ratushnyak, May 31 2013

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 5 21:18 EDT 2020. Contains 336213 sequences. (Running on oeis4.)