Skip to main content

Spacetime tent facilities for solving hyperbolic equations

Project description

Spacetime Tents in NGSolve

This NGS-Tents (ngstents) package is a c++ extension of the NGSolve finite element library, designed to ease experimentation with solvers based on spacetime tents for hyperbolic systems. A python front-end allows new equations (linear or nonlinear conservation laws) to be solved by easily defining required fluxes and numerical fluxes in a few lines of code.

Install

Build using pip

On a computer with a build system (compiler etc), you can install NGS-Tents by

python3 -m pip install git+https://github.com/jayggg/ngstents.git

If you do not have the dependency ngsolve installed, this command will attempt to install ngsolve first, before proceeding to install ngstents. If you prefer to use your own existing install of ngsolve, please use the --no-build-isolation argument:

python3 -m pip install --no-build-isolation git+https://github.com/jayggg/ngstents.git

Build using CMake

If you built ngsolve from source, you can also build and install ngstents in the traditional manner. After cloning this repository, compile the c++ code here and install as follows:

cd src
mkdir build && cd build
cmake -DNGSolve_DIR=<Path2YourNGSolveInstallCMake>  ..
make install

(Often CMake is able to correctly detect the path to your NGSolve installation in which case you do not have to specify the NGSolve_DIR variable.)

Binary install

If you do not have a compiler, then you can install NGS-Tents using a binary installer. To do so on linux, mac, and windows (with python>= 3.9), use the following command.

pip install --pre ngstents

Use

To start using this code's python interface, import the module after installation:

import ngstents

It contains classes named Tent and TentSlab used to partition spacetime into tents. It also has a submodule named conslaw which contains specific pre-programmed hyperbolic equations and also facilities to define and solve new hyperbolic systems using the python interface. Use python's help system to query for documentation on each object. The demo folder contains example scripts. The docs folder contains more documentation, explained next.

Documentation

Read the docs online. This documentation is generated from hands-on style tutorial notebooks in the docs folder.

Offline, to build and test the docs locally, navigate to the ngstents/docs folder and run these:

pip install -r requirements.txt
sphinx-build -b html . _build_docs

You can then open the docs from ngstents/docs/_build_docs/INDEX.html.

Alternately, you can build a jupyter book of the documentation by navigating to the ngstents/docs folder and issuing

jupyter-book build .

which creates documentation in ngstents/docs/_build/INDEX.html.

Check

If you extend the code, your new code changes can be cross-checked against a test suite provided in the 'tests' folder. For example, if you have pytest installed, move to the ngstents/tests folder and use pytest:

pytest .

Organization

  • src: c++ source code
  • py: python packaging files
  • doc: tutorials and explanations
  • demo: examples of applications
  • tests: test suite

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

ngstents-0.1.dev443.tar.gz (353.1 kB view details)

Uploaded Source

Built Distributions

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

ngstents-0.1.dev443-cp312-cp312-win_amd64.whl (729.1 kB view details)

Uploaded CPython 3.12Windows x86-64

ngstents-0.1.dev443-cp312-cp312-manylinux_2_28_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

ngstents-0.1.dev443-cp312-cp312-macosx_10_15_universal2.whl (3.1 MB view details)

Uploaded CPython 3.12macOS 10.15+ universal2 (ARM64, x86-64)

ngstents-0.1.dev443-cp311-cp311-win_amd64.whl (728.1 kB view details)

Uploaded CPython 3.11Windows x86-64

ngstents-0.1.dev443-cp311-cp311-manylinux_2_28_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

ngstents-0.1.dev443-cp311-cp311-macosx_10_15_universal2.whl (3.1 MB view details)

Uploaded CPython 3.11macOS 10.15+ universal2 (ARM64, x86-64)

ngstents-0.1.dev443-cp310-cp310-win_amd64.whl (726.5 kB view details)

Uploaded CPython 3.10Windows x86-64

ngstents-0.1.dev443-cp310-cp310-manylinux_2_28_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

ngstents-0.1.dev443-cp310-cp310-macosx_10_15_universal2.whl (3.1 MB view details)

Uploaded CPython 3.10macOS 10.15+ universal2 (ARM64, x86-64)

ngstents-0.1.dev443-cp39-cp39-win_amd64.whl (730.1 kB view details)

Uploaded CPython 3.9Windows x86-64

ngstents-0.1.dev443-cp39-cp39-manylinux_2_28_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.28+ x86-64

ngstents-0.1.dev443-cp39-cp39-macosx_10_15_universal2.whl (3.1 MB view details)

Uploaded CPython 3.9macOS 10.15+ universal2 (ARM64, x86-64)

File details

Details for the file ngstents-0.1.dev443.tar.gz.

File metadata

  • Download URL: ngstents-0.1.dev443.tar.gz
  • Upload date:
  • Size: 353.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for ngstents-0.1.dev443.tar.gz
Algorithm Hash digest
SHA256 452fa988fa36ecdc7f242bf610466aa26ab2a9a38edb44ba9421932afaf1c401
MD5 5087777d87883d771f47c9e7cfee788b
BLAKE2b-256 6e90e8e4a39b09e10b7f5d59299977726b71843ff94092e2cbb0f983bd54db3e

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 21aca1abe9aa5e65df7f99b1de1f165663da23b5cbc30bdf32fa54782c4ba8c5
MD5 28c07832f425d0e78955670f97a93794
BLAKE2b-256 5c826c8480a7a73b5effeccd1d97c8620660ddc4cd97a325892d457b28b8d7b1

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp312-cp312-manylinux_2_28_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp312-cp312-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 95554429b5609873302e768c1b1e4117233d9570cfe082a8ae29ad77209743d4
MD5 919c00f98a51c4e7b7bea79b62fcb8d5
BLAKE2b-256 961e793a531511c0f18f7784ebbc2c0108cb699cbb50aaaff0819ca65f6dba3b

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp312-cp312-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp312-cp312-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 abf9f405076f7693a0f44edc3685a4c81a6510ca704c2f3dd3b084ef99a14c99
MD5 205801aa758d6598d8950e875fb045b5
BLAKE2b-256 057969021532c1d65e557b1e228d68a66e32390b1ea87f4a3be3cde33963c0c8

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 ce7cea58a83536872629b8f7d9c6a5bdfdb0b296aaf06aab62dad74d2874c3aa
MD5 e319c9684a61b24a1af4e6f2c6b64967
BLAKE2b-256 b73b3d7222834e98b8c5ebff9bb7a502c35147bc8933906dec0df4a327b58cfa

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp311-cp311-manylinux_2_28_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp311-cp311-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f2df4508287821bebbea7605bc73b4ea79d32aab9120016a46047508174d94b4
MD5 42d593caefae5493f98c61f84a1a77db
BLAKE2b-256 339c39f45a065ee5ab30d0499eb0a7bec85b20794a18ca310286d4146a5dba8f

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp311-cp311-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp311-cp311-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 6a59ed03f18107c03f8417fcfa7e0782d385297882c4d39c13a22b3f4dff4f32
MD5 2c483ee51e0006bc7e8967be6d3fd7f7
BLAKE2b-256 db847c8627a6ba5ad278d801a167d4ddd00a616072ccab1a8fb1f26c7a1ce20c

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 a80845dd45f79d10a60c9a1baaabd365ab1f8641d2c5afb2787e42894bba8c7e
MD5 211253512b60ad66ffd946884db8f8b3
BLAKE2b-256 ec46ce316489b206f695517f9b23ca8a7058c3bcdf9338c559fc79d1dc16758a

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp310-cp310-manylinux_2_28_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp310-cp310-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 0bdde1c0b8083cbf411a313f6e6a9159b0de59c922b6c10eab137af136545eee
MD5 74a165e2ff2f118462285245665d96ab
BLAKE2b-256 ae186703d490407085d67981e05764d4977c4323ab5f405479e0a486b8ace2ec

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp310-cp310-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp310-cp310-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 d7471403e8ce5b1e8424bb20873732696d0de306b5f10222845ba8ea6b78ec77
MD5 7f53ffb6d858e8473e33f38d905450bb
BLAKE2b-256 263866f987da4f704d222ba817b201e3a066eba8cf94c4d38a349440601a81ff

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp39-cp39-win_amd64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 e8c1568fdf8f32728778c275356e441a8b7d24e7e97fbd282c0ebdb3e399e814
MD5 860b4dbfc7432a9edbad58cd7989fb8e
BLAKE2b-256 521034eb8a8ecae6c669d5a3281921ba2ebeea8ec9889221e4d6fdc4ab269a21

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp39-cp39-manylinux_2_28_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp39-cp39-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 052b8e79b6bae1e671e5994960712115e97ec28ff4dec90e77a7f70be85ba17b
MD5 c908ab1659b3aaeb59b4444fdd721348
BLAKE2b-256 65d574501ef96e7b6fdf6e616fb8eb84e8d294aca22cde20a71fa12e29def638

See more details on using hashes here.

File details

Details for the file ngstents-0.1.dev443-cp39-cp39-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for ngstents-0.1.dev443-cp39-cp39-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 d16bbc2703d47a8ccd25898596c77f81e61731b3838b159bfa9c79d639b1cab1
MD5 2024ea1631d4366aa9777d24d842b188
BLAKE2b-256 91582bffd41c64a284a65fb47640c859aa9490c8c9e8146ccf206ba2250c6d7e

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