How can I Numerically integrate a function multiplied with a dirac delta function?
6 次查看(过去 30 天)
显示 更早的评论
for instance, integrate f=x.^2.*dirac(x), type function from -1 to 1.
Thanks
0 个评论
回答(1 个)
Roger Stafford
2017-3-18
编辑:Roger Stafford
2017-3-18
The integral of f(x) = x.^2.*dirac(x) w.r. x from -1 to +1 is zero. That is because the dirac(x) function is considered 0 at all points x except at x = 0, and at x = 0 its value is so large that the integral across the single point x = 0 is just 1. However in the case of your f(x) that one is multiplied by x^2 so that makes the integral zero. If you had a function g(x) = cos(x)*dirac(x), its integral from -1 to +1 would be just cos(0)*1 = 1.
Obviously this cannot be justified in the ordinary numerical sense with finite numbers and only has its basis in what mathematicians call “measure theory”. In particular, you cannot obtain the correct answer using numerical integration.
2 个评论
Walter Roberson
2017-3-18
And if you must integrate it numerically then you are going to have to use one of the approximations to the dirac delta; https://en.wikipedia.org/wiki/Dirac_delta_function#Approximations_to_the_identity
Roger Stafford
2018-1-3
编辑:Walter Roberson
2018-1-3
@Mostafa A. Jouybari: In answer to your question concerning this "Answers" entry, you can find the following sentence, "A rigorous approach to regarding the Dirac delta function as a mathematical object in its own right requires measure theory or the theory of distributions" at the Wikipedia website
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!