Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

Error occurs while 3d integration

조회 수: 1 (최근 30일)
dont panic
dont panic 2013년 9월 26일
마감: MATLAB Answer Bot 2021년 8월 20일
Hello everybody,
I'm trying to run a 3d integration programm while keeping field parameters and at a few field points i get the following error message:
Warning: Reached the limit on the maximum number of intervals in use. Approximate bound on
error is 1.1e-04. The integral may not exist, or it may be difficult to approximate
numerically to the requested accuracy.
The function with the integral looks like this :
mp=zeros(size(R));
for k=1 : numel(mp)
k
f= @(r,phi,z)(M/(4*pi))*((Z(k)-z).*r)./(R(k)^2-2.*r*R(k).*cos(phis-phi)+r.^2+(Z(k)-z).^2).^(3/2);
mp(k)=integral3(f,R1,R2,phi1,phi2,Z1,Z2,'Method','iterated');
end
I have just copied the integral function as the rest of the code works and is not well structured. The problem is that the field points in which this errors occur are left blank in the surf plot and therefore the result is pretty useless.
Thank you for your help in advance
  댓글 수: 1
Walter Roberson
Walter Roberson 2013년 9월 26일
What can we assume about the values? Are R1, R2, phi1, phi2, Z1, Z2 all real-valued, with R1 <= R2, phi1 <= phi2, Z1 <= Z2? And are M, Z(k), R(k), phis all real-valued? Are all the Z(k) < Z1, or are they all > Z2, or are there some from [Z1, Z2] ?
When cos(phis-phi) is +/- 1, then there are additional solutions not otherwise available.

답변 (0개)

제품

Community Treasure Hunt

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

Start Hunting!

Translated by