This question is closed. Reopen it to edit or answer.

How to apply Gauss quadrature method to integrate rapid varying functions?

4 views (last 30 days)
Hi, I have a rapidly varying function that i need to integrate over (-1,2) using gauss quadrature method (this is a must).The function is a combination of sinx and cosx. I've been told that simple integration will not do. What do you suggest?
Thanks, B
  1 Comment
John D'Errico
John D'Errico on 8 Apr 2016
Edited: John D'Errico on 8 Apr 2016
Well, one would assume that integration between various sets of limits is additive. At least it was when I went to school. Thus, if you have an integral between limits of [a,c] then...
int(f,a,c) = int(f,a,b) + int(f,b,c)
The point is, you can reduce the interval length to be as short as you need it, breaking it down into smaller manageable sub-problems.
Anyway, this is not a MATLAB question.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!