필터 지우기
필터 지우기

Gaussian quadrature with change of variables

조회 수: 7 (최근 30일)
Melanie Wroblewski
Melanie Wroblewski 2022년 11월 29일
답변: Andreas Apostolatos 2022년 11월 29일
I need help writing a matlab function that numerically integrates any continuous function f (x, y) over the parallelogram (1, 1), (3, 2), (4, 4) and (6, 5) using Gaussian quadrature with m × n points. The inputs of your function must be f , m and n.

답변 (1개)

Andreas Apostolatos
Andreas Apostolatos 2022년 11월 29일
Hi Melanie,
There are serveral submissions on File Exchange that you can use to compute integrals using the Gauss Quadrature rule. Please check the following post on MATLAB Answers and in particular the comprehensive answer from John D'Errico:
Among other, he also shows comprehensive examples on how this can be done for one-dimensional functions f(x). For two-dimensional functions f(x,y) you simply needed a nested loop. This is also very nicely shown in the following MATLAB Answers post,
I hope this helps.
Kind regards
Andreas

카테고리

Help CenterFile Exchange에서 Numerical Integration and Differential Equations에 대해 자세히 알아보기

제품


릴리스

R2022b

Community Treasure Hunt

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

Start Hunting!

Translated by