无法找到显式积分

时间:2013-11-19 21:36:20

标签: matlab integration numerical explicit integral

如果我尝试评估以下积分,我会得到一个众所周知的“无法找到显式积分”的错误

syms z;
funz=1./(1+exp((z*z-0.5)/0.1));
Integ2=int(funz,z,0,inf)

我收到警告:

Warning: Explicit integral could not be found.        
Integ2 =   
int(1/(exp(10*z^2 - 5) + 1), z == 0..Inf)

Mathematica将此积分评估为0.693

我尝试将较低的积分限制替换为某个小的有限数(0.001),但这没有用。 请帮助确定此问题的修复程序。 任何帮助表示赞赏。 非常感谢!

1 个答案:

答案 0 :(得分:2)

尝试variable-precision arithmeticvpa

syms z; 
funz=1./(1+exp((z*z-0.5)/0.1));

Integ2=int(funz,z,0,inf)
Warning: Explicit integral could not be found. 

Integ2 =
int(1/(exp(10*z^2 - 5) + 1), z = 0..Inf)

vpa(Integ2,5)  % 5 is the number of significant digits
ans =     
0.69305

参见documentation中的最后一个例子,“近似定积分”。 引用:

  

如果int无法计算定积分的闭合形式,请尝试   使用vpa以数字方式逼近该积分。

相关问题