Skip to main content

Numerical integration technique

Project description

https://raw.github.com/saullocastro/cubature/master/cubature_logo.png

Cubature

Build status

Coverage

What is Cubature?

It is a numerical integration technique. From MathWorld, Ueberhuber (1997, p. 71) and Krommer and Ueberhuber (1998, pp. 49 and 155-165) use the word “quadrature” to mean numerical computation of a univariate integral, and “cubature” to mean numerical computation of a multiple integral.

Documentation

Please, see the module documentation here.

Python wrapper for the Cubature package

From the Nanostructures and Computation Wiki at MIT, Steven W. Johnson has written a simple C package for adaptive multidimensional integration (cubature) of vector-valued functions over hypercubes and this is a Python wrapper for the referred C package.

Installation

Installation from source code …

You must have Cython installed. Then do:

python setup.py install

or (usually in Linux):

python3 setup.py install

Installation from pip repository …

Just do:

pip install cubature

or (usually in Linux):

pip3 install cubature

Running the tests

To run the tests you will have to download the source code. After installing as explained above, go to the source code root folder and run:

py.test .

The Python wrapper has been proven using test integrands from the C package and some additional testing functions from Genz. The integrands were implemented in Cython and verified with Mathematica.

Citing this Python wrapper for Cubature

We kindly ask you to cite this Python library properly. Also, it would be helpful if you could cite the papers where this methods has been applied as well.

Castro, S.G.P.; Loukianov, A.; et al. “Python wrapper for Cubature: adaptive multidimensional integration”. DOI:10.5281/zenodo.2541552. Version 0.14.3, 2020.

Citing Papers using this Python wrapper for Cubature

Used to integrate tangent stiffness matrices in computational solid mechanics

Castro, S.G.P. et al. “Evaluation of non-linear buckling loads of geometrically imperfect composite cylinders and cones with the Ritz method”. Composite Structures, Vol. 122, 284-299, 2015.

Castro, S.G.P. et al. “A semi-analytical approach for linear and non-linear analysis of unstiffened laminated composite cylinders and cones under axial, torsion and pressure loads”. Thin-Walled Structures, Vol. 90, 61-73, 2015.

Examples

Some examples are given in ./examples.

Fork me!

You are welcome to fork this repository and modify it in whatever way you want. It will also be nice if you could send a pull request here in case you think your modifications are valuable for another person.

License

This wrapper follows the GNU-GPL license terms of Steven G. Johnson described in the C Package.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cubature-0.14.5.tar.gz (15.6 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

cubature-0.14.5-cp38-cp38-win_amd64.whl (10.6 MB view details)

Uploaded CPython 3.8Windows x86-64

cubature-0.14.5-cp37-cp37m-win_amd64.whl (10.6 MB view details)

Uploaded CPython 3.7mWindows x86-64

cubature-0.14.5-cp36-cp36m-win_amd64.whl (10.6 MB view details)

Uploaded CPython 3.6mWindows x86-64

File details

Details for the file cubature-0.14.5.tar.gz.

File metadata

  • Download URL: cubature-0.14.5.tar.gz
  • Upload date:
  • Size: 15.6 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

File hashes

Hashes for cubature-0.14.5.tar.gz
Algorithm Hash digest
SHA256 e2e75bbdcb074f3d3b1f31747237946a37b43853a034e7daa0186fc5637075fc
MD5 b1bd27dcc89054a234cb1850e2f29f67
BLAKE2b-256 d032a9c6a9064d7def4e178a7eab54cd720909bca9bbe8bf5f2ae210719f6e36

See more details on using hashes here.

File details

Details for the file cubature-0.14.5-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: cubature-0.14.5-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 10.6 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for cubature-0.14.5-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 15091516b5309a8e315255d01a7a9562fb05c24764a2da0e3d950d016c50dfca
MD5 bea2e155dbc7887267be2ca8bd94a531
BLAKE2b-256 5a5749881d59a07c473f178ca9aa8993c941e2fa92462db13ad6c42dc5410ce3

See more details on using hashes here.

File details

Details for the file cubature-0.14.5-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: cubature-0.14.5-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 10.6 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

File hashes

Hashes for cubature-0.14.5-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 41742f8cc5f040fb9fbb9f4c171ac062b6a3b73a9889a838bf4d20b897beca59
MD5 c8b6ef5678b6a54109239647a0af38dc
BLAKE2b-256 3e2a076964a66c6b074af104b3370bf5d1932cf454571a50254e1a78d1c7d6f3

See more details on using hashes here.

File details

Details for the file cubature-0.14.5-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: cubature-0.14.5-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 10.6 MB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/40.6.2 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.8

File hashes

Hashes for cubature-0.14.5-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 e35f31a603084b7610513efc2b4042b5e961b69b0965fd990a8b14e446d7994b
MD5 203d6ee2be91dd5b554612a9b4548580
BLAKE2b-256 9f982edf464e811fd2306b7b1b85fea875e490acafe6a17c117ee96762d6b344

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page