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.dev439.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.dev439-cp312-cp312-win_amd64.whl (740.8 kB view details)

Uploaded CPython 3.12Windows x86-64

ngstents-0.1.dev439-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.dev439-cp312-cp312-macosx_10_15_universal2.whl (3.8 MB view details)

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

ngstents-0.1.dev439-cp311-cp311-win_amd64.whl (739.2 kB view details)

Uploaded CPython 3.11Windows x86-64

ngstents-0.1.dev439-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.dev439-cp311-cp311-macosx_10_15_universal2.whl (3.8 MB view details)

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

ngstents-0.1.dev439-cp310-cp310-win_amd64.whl (736.9 kB view details)

Uploaded CPython 3.10Windows x86-64

ngstents-0.1.dev439-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.dev439-cp310-cp310-macosx_10_15_universal2.whl (3.8 MB view details)

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

ngstents-0.1.dev439-cp39-cp39-win_amd64.whl (734.9 kB view details)

Uploaded CPython 3.9Windows x86-64

ngstents-0.1.dev439-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.dev439-cp39-cp39-macosx_10_15_universal2.whl (3.8 MB view details)

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

File details

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

File metadata

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

File hashes

Hashes for ngstents-0.1.dev439.tar.gz
Algorithm Hash digest
SHA256 912a91fd8560e072dba86029077163244c5336e01fc1b6fae2ae288c2b130bee
MD5 5e8093e5e8a1b91c9e8b2cdff9886f8b
BLAKE2b-256 09809899cdf321b5bb7386b24b71f0ba037061002a90c79f9efbc73a37a508e2

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 d60d4cb08683bc678fcef80f217bddc055c841b230be9225712b4860a2bec7d0
MD5 2a72356695a07d541640cae8bc6e82b4
BLAKE2b-256 035d16d8133e94064763b49820564b839ca2f7124eb8c4ba2b244f5244f85d74

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp312-cp312-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e27d47abb4a138a9a5ea0d5adf58d0b9d69ab4dc5dd7e90f3662b3107f80cd92
MD5 99758de301d0e25c91319473aa8bf2eb
BLAKE2b-256 2f724f63640378c6cb615f15c97c69e6e8f56074c5a8f4bbf94a31954a64f066

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp312-cp312-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 b800f92d77080cb6cd15d2926ce50d6fb4875e5f46a89049f471a6ed8db4f5e7
MD5 cb49d9c726301f703ce2f87218bb2268
BLAKE2b-256 a40c4e24e9310cfb916baa6cc0841be70423810da2138704ac7e8df13c718877

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 c342b8c94b1e75d60c09df0f55f0de0bc031b12fd9585a5b44aa89e4efef22c1
MD5 1d094715b6542c9fdd7238b3eab0e72c
BLAKE2b-256 8b8de6b4a19ca980d8ff6d67d0425145756e1397bc06143d2b8f6c4466a04da6

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp311-cp311-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 d709f41fbc2e92bfaab94ec2a7512961d75118bad51ea3e19b6f5e8f8172de38
MD5 97353911e8d6ab283e5621438e9bc8c7
BLAKE2b-256 3b46bb94f686753dc3d3184cea9472f7e1009a6727207b214bed45b6b337a97a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp311-cp311-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 923996534e2973614eeee2c4ae6fbfed93ce5803619a18d0b2c7443293d08dad
MD5 51c66b03bcad0531f09ec998acb73297
BLAKE2b-256 f6b7fc00b1545dda6d71f949f03368e291737269e90aa44dd1090c0cbffb6d01

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 a70b5f3c31d7d46ee73c68fae2b7b49df7c2f993524810906f0d5eac933b1743
MD5 f07dfa738b352a5c6f10bd3d54f49dad
BLAKE2b-256 0a4b43a52f25e08fa18d58f3fd419e8e2b9c6f1d1de357d0771897ab44b72ba7

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp310-cp310-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 2f13f7667edbfadb5d569f058a1f1e975dc784fe04c153c2826abbea4f4f712c
MD5 bfd477f8c54abe81028b67a8bf50b03e
BLAKE2b-256 f006ed63664ecad3ead574a8976ff69bc9f7fce64319716cf57dedced9ba1d9c

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp310-cp310-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 95614c22fbba5f523d0b18f56eb8a09af4d7f5c85d1af7fa6acd7c50e1efc8d6
MD5 47403b0cdd13c5bb83e9312ccd13e6ca
BLAKE2b-256 fefeb58868a96c04de40599db8cc279292795787b5b9f359cb86e7cc8202179a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 89b20a3e11d9e81afd47211c20a34b03581b6045d92a1bd74984df8aefa73ac3
MD5 27a8e4b90a4b6dd960724ea8d25367f5
BLAKE2b-256 917afd22b9591144c7a3771b7f7c51e5ba73c7a48a7d8c4e7bf6d1c2cdf02de0

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp39-cp39-manylinux_2_28_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ba9caff6646346b68e9a36d99825e7ed4b7f312e0a518975943133538730072e
MD5 efa68e0768a781c1309868f8d6728e82
BLAKE2b-256 ad697ec827af2581eac702fa46385dfb2d76e5f4163a1afdbaefe3fb4ef268b3

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for ngstents-0.1.dev439-cp39-cp39-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 c0f62f5d8c619d97c717ac7516b0f4091a5009ca6f23c42f25098d0d053d62c9
MD5 55808009a9936e6832123875ecfaf9d5
BLAKE2b-256 c0f9d33b51612a5ab3fd2d7c18bcfd404d51bc9350dc676b937d46fb11d9739e

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