Numerical integration

2 次查看(过去 30 天)
R yan
R yan 2011-7-27
I want to integrate numerically f(x,y) with respect to x keeping y constant. Can quad do it with some modifications?
Any other ideas??

回答(2 个)

Andrei Bobrov
Andrei Bobrov 2011-7-27
y = 5; %eg: y-constant
quad(@(x)f(x,y),xmin,xmax)
  4 个评论
R yan
R yan 2011-7-28
you mean to say:
int(int(f(x,y),x,a,b),y,a,b)=dblquad('f(x,y)',a,b,a,b)
valid for all f(x,y)?
Mike Hosea
Mike Hosea 2011-8-2
Not for *all* f(x,y), but almost certainly for *your* f(x,y). See Fubini's theorem, for example.

请先登录,再进行评论。


Innocent
Innocent 2011-8-2
Hi Yan, i did post an example of simple code under newsgroup follow the link bellow to check it out.

类别

Help CenterFile Exchange 中查找有关 Symbolic Math Toolbox 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by