Numerical integration

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일

0 개 추천

y = 5; %eg: y-constant
quad(@(x)f(x,y),xmin,xmax)

댓글 수: 4

R yan
R yan 2011년 7월 27일
My aim to get the value of the integral in terms of y. So that it can be again integrated with respect to y in the next step.
I have tried symbolic it works. But I need it numerical.
Andrei Bobrov
Andrei Bobrov 2011년 7월 27일
doc dblquad
q = dblquad(f,xmin,xmax,ymin,ymax)
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일

0 개 추천

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

카테고리

도움말 센터File Exchange에서 Propagation and Channel Models에 대해 자세히 알아보기

질문:

2011년 7월 27일

Community Treasure Hunt

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

Start Hunting!

Translated by