I have some problems in my scientific research with numerical modeling in Python. I do my research in Jupyter notebook (Anaconda).
I have a difficult integral that includes other integrals: Big integral[Integral]https://i.stack.imgur.com/fE3kS.jpg[/img]
Where S(x) and E(x) are integrals too: S-integral [S-integral]https://i.stack.imgur.com/lBasi.jpg[/img] E-integral [E-integral]https://i.stack.imgur.com/N3CNL.jpg[/img]
And S' is a derivative S(x) with respect to x.
My to-do list includes:
1.To make a numerical model of s-integral:
To Make a numerical model of E-integral. (I think I have right solution although I don't have any confirmation in book.)
To get a derivative of S(x) with respect to x. How Can I do it without manual calculation? It is a problem because integrand is rather big for numerical methods (or I don't know how I can do it).
After uniting this functions I have to calculate indefinite integral, but when I do it manually, jupyter gives a NaN massive with big amount of warnings such as overflow encountered in exp, in double scalars and slowly convergent integrals.
I'm soory for URL's:
Main int:
![[Image: fE3kS.jpg]](https://i.stack.imgur.com/fE3kS.jpg)
S int:
![[Image: lBasi.jpg]](https://i.stack.imgur.com/lBasi.jpg)
E-int:
![[Image: N3CNL.jpg]](https://i.stack.imgur.com/N3CNL.jpg)
Warnings:
I have a difficult integral that includes other integrals: Big integral[Integral]https://i.stack.imgur.com/fE3kS.jpg[/img]
Where S(x) and E(x) are integrals too: S-integral [S-integral]https://i.stack.imgur.com/lBasi.jpg[/img] E-integral [E-integral]https://i.stack.imgur.com/N3CNL.jpg[/img]
And S' is a derivative S(x) with respect to x.
My to-do list includes:
1.To make a numerical model of s-integral:
def s(x): def spec(y,x): y2=z**2 x2=x**2 k=np.sqrt(y2+x2) e=np.exp(k) return (k+y2/(3*k))*y2/(e+1) i=quad(spec, 0, np.inf, args=(x)) return 1+(45/2pi**4)*i[0]This part is certainly correct. (When I tried x=0 then s(x)=2.75)
To Make a numerical model of E-integral. (I think I have right solution although I don't have any confirmation in book.)
To get a derivative of S(x) with respect to x. How Can I do it without manual calculation? It is a problem because integrand is rather big for numerical methods (or I don't know how I can do it).
After uniting this functions I have to calculate indefinite integral, but when I do it manually, jupyter gives a NaN massive with big amount of warnings such as overflow encountered in exp, in double scalars and slowly convergent integrals.
I'm soory for URL's:
Main int:
![[Image: fE3kS.jpg]](https://i.stack.imgur.com/fE3kS.jpg)
S int:
![[Image: lBasi.jpg]](https://i.stack.imgur.com/lBasi.jpg)
E-int:
![[Image: N3CNL.jpg]](https://i.stack.imgur.com/N3CNL.jpg)
Warnings:
Error:C:\Users\Enitorc\Anaconda3\lib\site-packages\ipykernel\__main__.py:40: RuntimeWarning: overflow encountered in double_scalars
C:\Users\Enitorc\Anaconda3\lib\site-packages\ipykernel\__main__.py:39: RuntimeWarning: overflow encountered in exp
C:\Users\Enitorc\Anaconda3\lib\site-packages\ipykernel\__main__.py:40: RuntimeWarning: invalid value encountered in double_scalars
C:\Users\Enitorc\Anaconda3\lib\site-packages\scipy\integrate\quadpack.py:356: IntegrationWarning: The occurrence of roundoff error is detected, which prevents
the requested tolerance from being achieved. The error may be
underestimated.
warnings.warn(msg, IntegrationWarning)