I get the following error in certain sums when starting at k=0:
(1) -> sum(4^k/binomial(2*k, k), k=0..n)
>> Error detected within library code:
catdef: division by zero
eval(4^k/binomial(2*k, k),k=0) --> 1
eval(4^k/binomial(2*k, k),k=-1) --> above error message
I suspect the error could be triggered in innersum(x, k) in
combfunc.spad (line 2785/eval k::F-1 ??) but am not sure.
-----------------------------------
--- the result is correct otherwise
(2) -> S:=1+sum(4^k/binomial(2*k, k), k=1..n)
2 n n
( ) + (2 n + 2)4
n
(2) -------------------
2 n
3 ( )
n
Type:
Expression(Integer)
(3) -> Sexpected:=4/3*4^n*(2*n+1)/binomial(2*n+2,n+1)+1/3
2 n + 2 n
( ) + (8 n + 4)4
n + 1
(67) -----------------------
2 n + 2
3 ( )
n + 1
Type:
Expression(Integer)
(4) -> test(normalize(S-Sexpected)=0)
(4) true
Type:
Boolean
--
You received this message because you are subscribed to the Google Groups "FriCAS -
computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion visit
https://groups.google.com/d/msgid/fricas-devel/92fac8d1-39bc-40fe-bbeb-15f40f7d441b%40gmail.com.