Integral of the product of integrals

조회 수: 1 (최근 30일)
Morteza
Morteza 2022년 1월 16일
편집: Torsten 2022년 1월 17일
I1 = integral [f1(x,y), x, a, b]
I2 = integral [f2(x,y), x, a, b]
I3 = integral [f3(x,y), x, a, b]
integral(I1*I2*I3, y, c, d)
Note that a,b,c,d are constant. Integrals have no analytical solution.

채택된 답변

Matt J
Matt J 2022년 1월 16일
편집: Matt J 2022년 1월 16일
I=@(y,f) integral( @(x)f(x,y), a, b);
I123=@(y) I(y,f1) .* I(y,f2) .* I(y,f3);
integral(I123, c, d)
  댓글 수: 2
Morteza
Morteza 2022년 1월 17일
f1= @(y, teta) y.*exp(teta.^2);
f2=@(y, teta) y.*exp(teta.^3);
f3=@(y, teta) y.*exp(teta.^4);
I=@(teta,f) integral( @(y)f(y, teta), 0, 50);
I123=@(teta) I(teta,f1) .* I(teta,f2) .* I(teta,f3);
integral(I123, 0, 50 )
This is an example based on your code. Error:
Error using integralCalc/finalInputChecks (line 515)
Output of the function must be the same size as the input. If FUN is an array-valued integrand,
set the 'ArrayValued' option to true.
Torsten
Torsten 2022년 1월 17일
편집: Torsten 2022년 1월 17일
integral(I123, 0, 50,'ArrayValued',true )
And you shouldn't integrate exp(teta^2),exp(teta^3) or exp(teta^4) up to teta = 50.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Numerical Integration and Differentiation에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by