HANS
This code implements the Height-Averaged Navier-Stokes (HANS) scheme for two-dimensional lubrication problems as described in the following paper:
Holey, H. et al. (2022) Tribology Letters, 70(2), p. 36.
Installation
Packaged versions can be installed via
pip install hans
Multiscale simulations require a working installation of LAMMPS. New molecular dynamics runs are triggered using the Python interface of LAMMPS. Therefore LAMMPS has to be build as a shared library. Please follow the installation instructions of LAMMPS.
Examples
Run from the command line with
mpirun -n <NP> python3 -m hans -i <input_file> [-p] [-r <restart_file>]
where NP is the number of MPI processes. The plot option (-p, --plot) is only available for serial execution. Example input files as well as jupyter-notebooks can be found in the examples directory.
The command line interface contains some scripts for plotting and creating animations. For instance, 1D profiles of converged solutions can be displayed with
plot1D_last.py
Tests
Run all tests from the main source directory with
pytest
or append the path to the test definition file (located in tests) to run selected tests only.
Documentation
A Sphinx-generated documentation can be built locally with
cd doc
sphinx-apidoc -o . ../hans
make html
Funding
This work is funded by the German Research Foundation (DFG) through GRK 2450.
Metadata
Release files for hans 0.3.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| hans-0.3.2.tar.gz | 60.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hans-0.3.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 155.5 kB
Release files / hans-0.3.2.tar.gz
| Download URL | hans-0.3.2.tar.gz |
|---|---|
| Size | 60.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5e536d4d48536f0361cb972a82cae23615d14b2dc243d6606b295160936f6de1
|
|
BLAKE2b-256 checksum How to use checksums |
a42473870c3488ef043cf555cde4d87f3cc1deea145dc2e0fd516470c4671d21
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 3, 2025.
Transparency logRelease files / hans-0.3.2-py3-none-any.whl
| Download URL | hans-0.3.2-py3-none-any.whl |
|---|---|
| Size | 95.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9ecd82d5f30a0c7fa846e1517a1681f6dfc04363c9ced8731623d2c02905250e
|
|
BLAKE2b-256 checksum How to use checksums |
867aa520bb35c488cfb5ed17e093221b0c071cc8ac26faa64d376b2d2ca0975a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 3, 2025.
Transparency log