symsum with multiple summation
조회 수: 1 (최근 30일)
이전 댓글 표시
To produce and solve following equation
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/188461/image.png)
I have written following equations
syms a d d1 k Nt PSI p Pi1 i
A=symsum( nchoosek(d,k) * PSI ( (1-PSI)^(d-k) ) nchoosek(k,a) (p^a)(1-p)^(k-a),d,0,Nt);
B=symsum ( (nchoosek(i,d1) * nchoosek(Nt-i,d-d1) (Pi1^d) (1-Pi1)^(Nt-d) ) * A ,i,0,Nt );
C=symsum( B, a,0,d);
M=symsum( C, d1,0,i )
where limits of summation for variables are as follows
Nt = 10 constant
d from 0 to Nt
d1 (d bar) from 0 to min(i,d), min gives error in symsum Error using symengine Input arguments must be convertible to floating-point numbers.
a from 0 to d
i from 0 to Nt
without using min() for limit of d1 script runs fine but can any one tell me that implementation i have done for multiple summation and their limits fine or limits or summation should follow any order also how can i add min(i,d) for d1 limit.
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Calculus에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!