triangle_dunavant_rule, a MATLAB code which returns a Dunavant quadrature rules over the interior of a triangle in 2D.
These rules are almost optimal, in the sense that, for each polynomial degree, the number of points used in the rule is close to, or equal to, the theoretical minimum possible value.
A few of the rules include one or two points which are "slightly" outside the triangle; a few of the rules include weights which are negative. Both of these occurrences are generally undesirable.
The information on this web page is distributed under the MIT license.
triangle_dunavant_rule is available in a C++ version and a Fortran90 version and a MATLAB version and an Octave version.
matlab_rule, a MATLAB code which computes a quadrature rule which estimates the integral of a function f(x), which might be defined over a one dimensional region (a line) or more complex shapes such as a circle, a triangle, a quadrilateral, a polygon, or a higher dimensional region, and which might include an associated weight function w(x).