I wanted to solve a parametric double integral. Matlab requires me to set these parameters (for my case x0, x1, x2, x3, x4, x5, x6, x7, x8 and x9). The variables are r and t. Is there a solution with Matlab to solve a double integral set without sett
이전 댓글 표시
I wanted to solve a parametric double integral. Matlab requires me to set these parameters (for my case x0, x1, x2, x3, x4, x5, x6, x7, x8 and x9).
The variables are r and t.
Is there a solution with Matlab to solve a double integral set without setting any values of the parameters.
here is the code:
------------------------------------
syms t r x0 x1 x2 x3 x4 x5 x6 x7 x8 x9;
tmin = 0;
tmax = 1;
rmin = 0;
rmax = 2*pi;
g = +(x0*cos(-2*t)-x5*sin(-2*t))*(1-r^(-2))+(x1*cos(-1*t) - x6*sin(-1*t))*(1-r^(-1))+(x2*cos(0*t)-x7*sin(0*t))*(1-r^(0))+(x3*cos(1*t)-x8*sin(1*t))*(1-r^(1))+(x4*cos(2*t)-x9*sin(2*t))*(1-r^(2));
h = +(x0*sin(-2*t)+x5*cos(-2*t))*(1-r^(-2))+(x1*sin(-1*t)+x6*cos(-1*t))*(1-r^(-1))+(x2*sin(0*t)+x7*cos(0*t))*(1-r^(0))+(x3*sin(1*t)+x8*cos(1*t))*(1-r^(1))+(x4*sin(2*t)+x9*cos(2*t))*(1-r^(2));
f = r*(g^2+h^2);
fun = @(t,r) f;
format long
J = integral2(fun,tmin,tmax,rmin,rmax,'Method','iterated','AbsTol',1e-12 ,'RelTol',1e-10)
---------------end-------------------
thank you in advance
채택된 답변
추가 답변 (1개)
Babacar Ndiaye
2016년 9월 15일
0 개 추천
댓글 수: 4
Walter Roberson
2016년 9월 15일
Maple says that the result of what you originally posted will be
signum((1/2)*x0^2+(1/2)*x5^2)*infinity
which turns out to depend only on x0 and x5
Babacar Ndiaye
2016년 9월 23일
편집: Walter Roberson
2016년 9월 23일
Walter Roberson
2016년 9월 23일
Although the result, J, shows up in terms of int(), if you simplify(J) then the closed form solution is returned.
Babacar Ndiaye
2016년 9월 24일
카테고리
도움말 센터 및 File Exchange에서 Assumptions에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!