Need help with the integral
古いコメントを表示
Hello, how to write a code to find an excat value of this integral?
8 件のコメント
Walter Roberson
2019 年 3 月 20 日
How do you want the exact value expressed? erf? hypergeometric function? Fresnel C function?
Erika Plekaviciute
2019 年 3 月 20 日
編集済み: Erika Plekaviciute
2019 年 3 月 20 日
Walter Roberson
2019 年 3 月 20 日
That isn't the exact value. The exact value is likely an irrational number when expressed in decimal; sqrt(pi) is part of the expression of it. Any finite truncation of it would be only an approximation.
What is your numeric approximation code? You only need 9 terms to get that particular numeric value.
Torsten
2019 年 3 月 21 日
Because you write down a series representation of the integral, maybe your task is to add up until you get the required accuracy ?
Walter Roberson
2019 年 3 月 21 日
You are just doing a summation of values at end points as if the value were constant for the entire interval. That is not going to be accurate. You should look at the trapizoid rule for greater accuracy. trapz()
Torsten
2019 年 3 月 21 日
You are trying to approximate the integral, not summing up the series.
James Tursa
2019 年 3 月 21 日
Erika, it is very poor online etiquette to delete your question after there have been comments and answers posted. This is a disservice to the Answers community.
Rena Berman
2019 年 4 月 2 日
(Answers Dev) Restored edit
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Numerical Integration and Differentiation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!