How to perform surface integral using an interpolation function?
Show older comments
I have an interpolation function generated with "interp2":
G=@(x,y)interp2(xData,yData,zData,x,y);
when I try to integrate such function with "integral2" I either get some warning about failing to converge, or the computation time becomes extremely large. As an example:
A = integral2(G,xmin,xmax,ymin,ymax,'RelTol',1e-10,'AbsTol',1e-10,'method', 'auto');
Warning: Reached the maximum number of function evaluations (10000). The
result fails the global error test.
> In funfun\private\integral2Calc>integral2t at 130
In funfun\private\integral2Calc at 10
In integral2 at 106
Accepted Answer
More Answers (0)
Categories
Find more on Interpolation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!