2D Simpson's Integrator

版本 1.0.0.0 (2.8 KB) 作者: Whayne Padden
Fully vectorised 2D integrator based on the Simpson's method
2.3K 次下载
更新时间 2009/3/5

查看许可证

Fast, fully vectorised version of the Simpson's method for 2D domains. This code avoids the use of any for loops etc. For a given level of accuracy it can be an order of magnitude or more faster than dblquad.

Examples are provided within the code.

Useage:

ans = simp2D('func',xs,xe,ys,ye,NX,NY)

Input parameters:

func - 2D function that accepts vector inputs (otherwise
incorrect results can occur)
xs, xe - x-limits of integration
ys, ye - y-limits of integration
NX - number of integration intervals in the x-direction (should be even)
NY - number of integration intervals in the y-direction (should be even)

引用格式

Whayne Padden (2024). 2D Simpson's Integrator (https://www.mathworks.com/matlabcentral/fileexchange/23204-2d-simpson-s-integrator), MATLAB Central File Exchange. 检索时间: .

MATLAB 版本兼容性
创建方式 R2006b
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Numerical Integration and Differential Equations 的更多信息

Community Treasure Hunt

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

Start Hunting!
版本 已发布 发行说明
1.0.0.0