Multiple nested integrals produces scalar error
情報
この質問は閉じられています。 編集または回答するには再度開いてください。
古いコメントを表示
Hi,
I am trying to integrated nested integrals of the following form:
pmax = @(x,y) y;
pmin = 0;
ymax = 1;
ymin = @(x) x;
xmax = 1;
xmin = 0;
s_min = 0;
s_max = lam;
t_min = 0;
t_max = pi;
eqn = integral(@(x) x.*integral(@(y) (1/y).*integral(@(p) (exp(-arrayfun(@(p,x,y)integral2(@(s,t)myfun(s,t,p,x,y),s_min,s_max,t_min,t_max),p,x,y)./(k.*T))),pmin,pmax,'Arrayvalued',true),ymin,ymax,'Arrayvalued',true),xmin,xmax,'Arrayvalued',true)
However, I get the error:
Error using integral (line 85) A and B must be floating point scalars.
I thought by adding 'Arrayvalued' for the single integrals and arrayfun for the double integral that this would not be a problem. Any idea why this isn't working?
0 件のコメント
回答 (0 件)
この質問は閉じられています。
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!