cubature rules on triangles
Project description
Triangle Cubature Rules
This repo serves as a collection of well-tested triangle cubature rules, i.e. numerical integration schemes for integrals of the form
$$ \int_K f(x, y) ~\mathrm{d}x ~\mathrm{d}y, $$
where $K \subset \mathbb{R}^2$ is a triangle. All cubature rules are based on [1].
(Unit) Tests
To run auto tests, you do
python -m unittest discover tests/auto/
The unit tests use
sympy
to verify the degree of exactness of the implemented cubature rules, i.e. creates random polynomials $p_d$ of the expected degree of exactness $d$ and compares the exact result of $\int_K p_d(x, y) ~\mathrm{d}x ~\mathrm{d}y$ to the value obtained with the cubature rule at hand.
References
- [1] Stenger, Frank. 'Approximate Calculation of Multiple Integrals (A. H. Stroud)'. SIAM Review 15, no. 1 (January 1973): 234-35. https://doi.org/10.1137/1015023. p. 306-315
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file triangle_cubature-0.0.2.tar.gz
.
File metadata
- Download URL: triangle_cubature-0.0.2.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3a4acef42948db8a545c371088f28fbc3544e6bb484782602fe92e45c8b3a428 |
|
MD5 | 8d52c54fd25702ff9466500afe54b531 |
|
BLAKE2b-256 | 9db2c951b9edacbe1a5f960cf67b63d986119c2ab06cdd1fc116c2e2dcf72e76 |
File details
Details for the file triangle_cubature-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: triangle_cubature-0.0.2-py3-none-any.whl
- Upload date:
- Size: 5.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.9.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b8662d83bff9f3aad5270e8e11b3312a96c19766c08964ef19e31e09ba3d1999 |
|
MD5 | f0602c16513bc16115709c83e4045725 |
|
BLAKE2b-256 | f06a139eebd18eed466ad448dd91b8ef791fc36998d3187b6c51fdef21468db9 |