MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   资料存档 (https://www.labfans.com/bbs/forumdisplay.php?f=72)
-   -   How to avoid Singularity in numirical integration (https://www.labfans.com/bbs/showthread.php?t=22188)

poster 2019-11-27 16:22

How to avoid Singularity in numirical integration
 
<p>I want to numerically integrate the following with Matlab: </p>

<pre><code> fun=@(t) (((1 - (-1)^n*cos(n*pi*t/R)))./t);

hn = integral(fun,0,(sqrt(R^2-x^2)));
</code></pre>

<p>For now, I just avoided to evaluate the integral in 0, are they any way to encounter the singularity at this point.</p>

<p>Thank you.</p>



[url=https://stackoverflow.com/questions/59065717/how-to-avoid-singularity-in-numirical-integration]More answer...[/url]


所有时间均为北京时间。现在的时间是 21:21

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.