I'm trying to do the following sum:

NSum[((50000 - x) choose x)*(1/3^15)^x*((3^15 - x)/3^15)^(50000 - x), {x, 1, 4}]

But I keep getting an error saying:

"Summand (or its derivative) ((50000-x)\ choose\ x)\ (1/3^15)^x\ \((3^15-x)/3^15)^(50000-x) is not numerical at point x = 1."

Does anyone know what might be wrong?


  • 1
    $\begingroup$ what's choose? $\endgroup$
    – Verbeia
    Dec 7, 2014 at 7:10
  • $\begingroup$ @Verbeia Isn't n choose r C(n, r)? $\endgroup$
    – Kar
    Dec 7, 2014 at 7:13
  • 1
    $\begingroup$ Not in Mathematica syntax, it isn't. I think you need Binomial. $\endgroup$
    – Verbeia
    Dec 7, 2014 at 7:14

1 Answer 1


You are most likely hitting this problem because choose is not defined to be a numerical quantity. NSum requires a summation where each part evaluates to something numerical, not algebraic. Deleting the choose gives a result:

In[1]:= NSum[((50000 - x)  x)*(1/3^15)^
   x*((3^15 - x)/3^15)^(50000 - x), {x, 1, 4}]

Out[1]= 0.0034724


Based on the additional information you have provided, you might be looking for Binomial.

NSum[Binomial[(50000 - x) , x]*(1/3^15)^x*((3^15 - x)/3^15)^(50000 - x), {x, 1, 4}]

(* 0.00347843 *)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.