First time here? Check out the FAQ!

Ask Your Question
0

TypeError: Computation failed since Maxima requested additional constraints

asked 13 years ago

ck gravatar image

updated 13 years ago

I have the following code:

 N, n, f  = var('N, n, f')
 assume(N>0)
 sum(binomial(N, n)*f^n*(1-f)^(N-n), n, (N+1)/2, N)

It gives me the following error message:

 TypeError: Computation failed since Maxima requested additional constraints (try the command  'assume(N+1>0)' before integral or limit evaluation, for example): Is  N+1  positive, negative, or zero?
Preview: (hide)

1 Answer

Sort by » oldest newest most voted
1

answered 13 years ago

kcrisman gravatar image

This is a typical error message from Sage via Maxima.

But maybe I need an update from you. I get

sage: N, n, f  = var('N, n, f')
sage:  assume(N>0)
sage:  sum(binomial(N, n)*f^n*(1-f)^(N-n), n, (N+1)/2, N)
sum((-f + 1)^(N - n)*f^n*binomial(N, n), n, 1/2*N + 1/2, N)
Preview: (hide)
link

Comments

For some reason, it works now for me as well. (Maybe I had some inconsistent variable definitions I did not flush out or something). Thanks for checking.

ck gravatar imageck ( 13 years ago )

Likely. Glad you're set now!

kcrisman gravatar imagekcrisman ( 13 years ago )

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 13 years ago

Seen: 1,320 times

Last updated: Sep 22 '11