변수 x에 대한 정적분이 시간이 너무 오래걸립니다. 해결할 수 있는 방법이 없을까요?

2 次查看(过去 30 天)
명규 김
명규 김 2022-8-15
omega = [1:1:500]
syms x
d_x = 1 + (1 - 0).*x./1;
k_x = d_x.*sqrt(omega)./2;
sigma_x = pi.*(d_x./2).^2;
taper = 1./sigma_x.*(1 - (2.*besselj(1,k_x.*sqrt(-i)))./(k_x.*sqrt(-i).*besselj(0,k_x.*sqrt(-i)))).^-1;
int(taper,0,20)

回答(1 个)

Sai Teja G
Sai Teja G 2023-9-7
Hi,
답변은 영어로 작성되었으며 가장 빠른 답변을 제공하도록 설계되었습니다.
I understand that you want to optimize the execution speed of your code.
Unfortunately, there are no alternative methods available to optimize the execution time of your code. The integral function itself takes time to execute for the range of 1 to 500 symbols of 'x', and there are no other alternatives that can significantly improve the execution speed.
Hope it helps!

类别

Help CenterFile Exchange 中查找有关 수학 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!