Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • Sparse
  • WallLaw
  • improved_comm
  • master
  • mr_refactor_wfb
  • suffa/cumulantfourth_order_correction_with_psm
  • release/0.2.1
  • release/0.2.10
  • release/0.2.11
  • release/0.2.12
  • release/0.2.13
  • release/0.2.14
  • release/0.2.15
  • release/0.2.2
  • release/0.2.3
  • release/0.2.4
  • release/0.2.5
  • release/0.2.6
  • release/0.2.7
  • release/0.2.8
  • release/0.2.9
  • release/0.3.0
  • release/0.3.1
  • release/0.3.2
  • release/0.3.3
  • release/0.3.4
  • release/0.4.0
  • release/0.4.1
  • release/0.4.2
  • release/0.4.3
  • release/0.4.4
  • release/1.0
  • release/1.0.1
  • release/1.1
  • release/1.1.1
  • release/1.2
  • release/1.3
  • release/1.3.1
  • release/1.3.2
  • release/1.3.3
  • release/1.3.4
  • release/1.3.5
  • release/1.3.6
  • release/1.3.7
44 results

Target

Select target project
No results found
Select Git revision
  • central_moments
  • csebug
  • improved_comm
  • master
  • test_martin
  • win
  • windows
  • release/0.2.1
  • release/0.2.10
  • release/0.2.11
  • release/0.2.12
  • release/0.2.13
  • release/0.2.14
  • release/0.2.15
  • release/0.2.2
  • release/0.2.3
  • release/0.2.4
  • release/0.2.5
  • release/0.2.6
  • release/0.2.7
  • release/0.2.8
  • release/0.2.9
  • release/0.3.0
  • release/0.3.1
  • release/0.3.2
25 results
Show changes

Commits on Source 447

347 additional commits have been omitted to prevent performance issues.
353 files
+ 54110
12280
Compare changes
  • Side-by-side
  • Inline

Files

.flake8

0 → 100644
+5 −0
Original line number Diff line number Diff line
[flake8]
max-line-length=120
exclude=src/lbmpy/plot.py
        src/lbmpy/session.py
ignore = W293 W503 W291 C901 E741

.gitattributes

0 → 100644
+1 −0
Original line number Diff line number Diff line
src/lbmpy/_version.py export-subst

.gitignore

0 → 100644
+32 −0
Original line number Diff line number Diff line
__pycache__
.ipynb_checkpoints
.coverage*
*.pyc
*.vti
/build
/html_doc
/dist
*.egg-info
.cache
_build
/.idea
_local_tmp
**/.vscode
**/pylintrc
*.bak
*.tmp
/tests/db
doc/bibtex.json
/db
/src/lbmpy/phasefield/simplex_projection.*.so
/src/lbmpy/phasefield/simplex_projection.c

test-report
report.xml

# macOS
**/.DS_Store
*.uuid

# benchmark database
/tests/benchmark/db
 No newline at end of file

.gitlab-ci.yml

0 → 100644
+231 −0
Original line number Diff line number Diff line
stages:
  - "Code Quality"
  - "Tests"
  - "Prerelease-Tests"
  - integration
  - nightly
  - docs
  - deploy

# --------------------------  Code Quality --------------------------------------------------------------------------------


# Linter for code formatting
flake8-lint:
  stage: "Code Quality"
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
  script:
    - nox -s lint
  tags:
    - docker


# --------------------------  Tests --------------------------------------------------------------------------------

# Normal test - runs on every commit all but "long run" tests
testsuite-cuda-py3.10:
  stage: "Tests"
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:ubuntu24.04-cuda12.6
  needs: []
  script:
    - mkdir -p ~/.config/matplotlib
    - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
    - nox -s "testsuite_gpu-3.10(cupy12)"
  tags:
    - docker
    - cuda
    - cudaComputeCapability6.1
    - AVX
  coverage: /Total coverage:\s\d+.\d+\%/
  artifacts:
    when: always
    paths:
      - coverage_report
      - test-report
    reports:
      coverage_report:
        coverage_format: cobertura
        path: coverage.xml
      junit: report.xml


testsuite-cpu-py3.13:
  stage: "Tests"
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
  needs: []
  script:
    - mkdir -p ~/.config/matplotlib
    - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
    - nox -s "testsuite_cpu-3.13"
  tags:
    - docker
    - AVX
  artifacts:
    when: always
    paths:
      - test-report
    reports:
      junit: report.xml


# Normal test with longruns
tests-and-coverage-with-longrun:
  stage: "Tests"
  when: manual
  allow_failure: true
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
  script:
    # - pip install sympy --upgrade
    - export NUM_CORES=$(nproc --all)
    - mkdir -p ~/.config/matplotlib
    - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
    - mkdir public
    - pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
    - env
    - pip list
    - py.test -v -n $NUM_CORES
  tags:
    - docker
    - cuda
    - cudaComputeCapability6.1
    - AVX

# --------------------------  Nightly and Pre-Release Tests --------------------------------------------------------------------------------

# Test against latest pystencils 2.0 development version
pystencils-2.0dev:
  stage: "Prerelease-Tests"
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:ubuntu24.04-cuda12.6
  allow_failure: true
  needs: []
  script:
    - mkdir -p ~/.config/matplotlib
    - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
    - nox -s "testsuite_pystencils2(cupy12)"
  tags:
    - docker
    - AVX
    - cuda
    - cudaComputeCapability6.1
  artifacts:
    when: always
    paths:
      - test-report
    reports:
      junit: report.xml

minimal-sympy-master:
  stage: "Prerelease-Tests"
  needs: []
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
  script:
    - nox -s quicktest -P 3.13 -- --sympy-master
  allow_failure: true
  tags:
    - docker

# pycodegen-integration:
#   image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
#   stage: integration
#   when: manual
#   allow_failure: true
#   script:
#     - env
#     - pip list
#     - git clone https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pycodegen.git
#     - cd pycodegen
#     - git submodule sync --recursive
#     - git submodule update --init --recursive
#     - git submodule foreach git fetch origin   # compare the latest master version!
#     - git submodule foreach git reset --hard origin/master
#     - cd lbmpy
#     - git remote add test $CI_REPOSITORY_URL
#     - git fetch test
#     - git reset --hard $CI_COMMIT_SHA
#     - cd ..
#     - pip install -e pystencils/
#     - pip install -e lbmpy/
#     - ./install_walberla.sh
#     # build all integration tests
#     - cd walberla/build/
#     - make -j $NUM_CORES MicroBenchmarkGpuLbm LbCodeGenerationExample
#     - cd apps/benchmarks/UniformGridGPU
#     - make -j $NUM_CORES
#     - cd ../UniformGridCPU
#     - make -j $NUM_CORES

#   tags:
#     - docker
#     - cuda
#     - cudaComputeCapability6.1
#     - AVX


# -------------------- Scheduled Tasks --------------------------------------------------------------------------


nightly-sympy:
  stage: nightly
  rules:
    - if: $CI_PIPELINE_SOURCE == "schedule"
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/latest_python
  before_script:
    - pip install -e .
    - pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
    - pip install --upgrade --pre sympy
  script:
    - env
    - pip list
    - export NUM_CORES=$(nproc --all)
    - mkdir -p ~/.config/matplotlib
    - echo "backend:template" > ~/.config/matplotlib/matplotlibrc
    - mkdir public
    - pytest -v -n $NUM_CORES -m "not longrun" --junitxml=report.xml
  tags:
    - docker
    - AVX
    - cuda
    - cudaComputeCapability6.1
  artifacts:
    when: always
    reports:
      junit: report.xml


# -------------------- Documentation and deploy ------------------------------------------------------------------------

build-documentation:
  stage: docs
  needs: []
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/documentation
  before_script:
    - pip install -e .
  script:
    - export PYTHONPATH=`pwd`
    - pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
    - mkdir html_doc
    - sphinx-build -W -b html doc html_doc
  tags:
    - docker
    - cuda
    - cudaComputeCapability6.1
  artifacts:
    paths:
      - html_doc


pages:
  image: i10git.cs.fau.de:5005/pycodegen/pycodegen/full
  rules:
    - if: '$CI_PIPELINE_SOURCE != "schedule" && $CI_PROJECT_PATH == "pycodegen/lbmpy" && $CI_COMMIT_BRANCH == "master"'
  stage: deploy
  needs: ["testsuite-cuda-py3.10", "build-documentation"]
  script:
    - ls -l
    - mv coverage_report html_doc
    - mv html_doc public  # folder has to be named "public" for gitlab to publish it
  artifacts:
    paths:
      - public
  tags:
    - docker

.isort.cfg

0 → 100644
+4 −0
Original line number Diff line number Diff line
[settings]
line_length=100
balanced_wrapping=True
multi_line_output=4

AUTHORS.txt

0 → 100644
+14 −0
Original line number Diff line number Diff line

Contributors:
-------------

  - Martin Bauer <martin.bauer@fau.de>
  - Markus Holzer <markus.holzer@fau.de>
  - Michael Kuron <mkuron@icp.uni-stuttgart.de>
  - Stephan Seitz <stephan.seitz@fau.de>
  - Frederik Hennig <frederik.hennig@fau.de>
  - Helen Schottenhamml <helen.schottenhamml@fau.de>
  - Rudolf Weeber <weeber@icp.uni-stuttgart.de>
  - Christian Godenschwager <christian.godenschwager@fau.de>
  - Jan Hönig <jan.hoenig@fau.de>
  - Philipp Suffa <philipp.suffa@fau.de>

CHANGELOG.md

0 → 100644
+6 −0
Original line number Diff line number Diff line
# Change Log

## Unreleased

### Removed
* Removing OpenCL support because it is not supported by pystencils anymore

CONTRIBUTING.md

0 → 100644
+3 −0
Original line number Diff line number Diff line
# Contributing

lbmpy is built on the open-source python framework [pystencils](https://pypi.org/project/pystencils/). Please consider the [contribution guideline](https://i10git.cs.fau.de/pycodegen/pystencils/-/blob/master/CONTRIBUTING.md) of pystencils for contributing to lbmpy.
 No newline at end of file
+3 −2
Original line number Diff line number Diff line
include README.md
include COPYING.txt
include AUTHORS.txt
include CONTRIBUTING.md
include CHANGELOG.md
+55 −6
Original line number Diff line number Diff line
lbmpy
=====

Run fast fluid simulations based on the lattice Boltzmann method in Python.
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/mabau/lbmpy/master?filepath=doc%2Fnotebooks)
[![Docs](https://img.shields.io/badge/read-the_docs-brightgreen.svg)](http://pycodegen.pages.i10git.cs.fau.de/lbmpy)
[![pipeline status](https://i10git.cs.fau.de/pycodegen/lbmpy/badges/master/pipeline.svg)](https://i10git.cs.fau.de/pycodegen/lbmpy/commits/master)
[![coverage report](https://i10git.cs.fau.de/pycodegen/lbmpy/badges/master/coverage.svg)](http://pycodegen.pages.i10git.cs.fau.de/lbmpy/coverage_report)

![alt text](doc/img/logo.png)

Run fast fluid simulations based on the lattice Boltzmann method in Python on CPUs and GPUs.
lbmpy creates highly optimized LB compute kernels in C or CUDA, for a wide variety of different collision operators, including MRT,
entropic, and cumulant schemes.

All collision operators can be easily adapted, for example, to integrate turbulence models, custom force terms, or multi-phase models. 
It even comes with an integrated Chapman Enskog analysis based on sympy!

Common test scenarios can be set up quickly:
```python
from pystencils import Target
from lbmpy.session import *

ch = create_channel(domain_size=(300, 100, 100), force=1e-7, method=Method.TRT,
                    equilibrium_order=2, compressible=True,
                    relaxation_rates=[1.97, 1.6], optimization={'target': Target.GPU})
```

To find out more, check out the interactive [tutorial notebooks online with binder](https://mybinder.org/v2/gh/mabau/lbmpy/master?filepath=doc%2Fnotebooks).


Installation
------------

For local installation use pip:

```bash
export PIP_EXTRA_INDEX_URL=https://www.walberla.net/pip
pip install lbmpy[interactive]
```

@@ -18,17 +40,44 @@ pip install lbmpy[interactive]
Without `[interactive]` you get a minimal version with very little dependencies.

All options:
-  `gpu`: use this if nVidia GPU is available and CUDA is installed
- `gpu`: use this if a NVIDIA GPU is available and CUDA is installed
- `opencl`: use this to enable the target `opencl` (execution using OpenCL)
- `alltrafos`: pulls in additional dependencies for loop simplification e.g. libisl
- `interactive`: installs dependencies to work in Jupyter including image I/O, plotting etc.

Options can be combined e.g.
```bash
pip install pystencils[interactive,gpu,doc]
pip install lbmpy[interactive,gpu,doc]
```


Documentation
-------------

Read the docs [here](http://software.pages.walberla.net/pystencils/lbmpy)
Read the docs [here](http://pycodegen.pages.i10git.cs.fau.de/lbmpy) and
check out the Jupyter notebooks in `doc/notebooks`. 

Contributing
-------
To see how to open issues, submit bug reports, create feature requests or submit your additions to lbmpy please refer to
[contribution documentation](https://i10git.cs.fau.de/pycodegen/pystencils/-/blob/master/CONTRIBUTING.md) of pystencils since lbmpy is heavily build on pystencils.


Many thanks go to the [contributors](https://i10git.cs.fau.de/pycodegen/lbmpy/-/blob/master/AUTHORS.txt) of lbmpy.


### Please cite us

If you use lbmpy in a publication, please cite the following articles:

Overview:
  - F. Hennig et al, Advanced Automatic Code Generation for Multiple Relaxation-Time Lattice Boltzmann Methods. SIAM Journal on Scientific Computing, 2023. https://doi.org/10.1137/22M1531348 ([Preprint](https://arxiv.org/abs/2211.02435))
  - M. Bauer et al, lbmpy: Automatic code generation for efficient parallel lattice Boltzmann methods. Journal of Computational Science, 2021. https://doi.org/10.1016/j.jocs.2020.101269 ([Preprint](https://arxiv.org/abs/2001.11806))

Multiphase:
   - M. Holzer et al, Highly efficient lattice Boltzmann multiphase simulations of immiscible fluids at high-density ratios on CPUs and GPUs through code generation. The International Journal of High Performance Computing Applications, 2021. https://doi.org/10.1177/10943420211016525


### Further Reading

- F. Hennig et al, Automatic Code Generation for the Cumulant Lattice Boltzmann Method. ICMMES, 2021. [Poster Link](https://www.researchgate.net/publication/353224406_Automatic_Code_Generation_for_the_Cumulant_Lattice_Boltzmann_Method)

binder/apt.txt

0 → 100644
+3 −0
Original line number Diff line number Diff line
build-essential
graphviz
ffmpeg

binder/environment.yml

0 → 100644
+36 −0
Original line number Diff line number Diff line

# ----------------------------------------------------------------------------------------------------------------------
# Environment with all dependencies to use pystencils
#
#
# Download conda at https://conda.io/miniconda.html and create this environment by running:
#     conda env create -f conda_environment_user.yml
#     . activate pystencils
#
# If you have CUDA or ROCm installed and want to use your GPU, uncomment the last line to install cupy
#
# ----------------------------------------------------------------------------------------------------------------------

name: pystencils
dependencies:
  # Basic dependencies:
  - python >= 3.6
  - numpy
  - sympy >= 1.1
  - appdirs # to find default cache directory on each platform
  - joblib # caching on hard-disk, this is optional, but if not installed lbmpy is really slow
  - cython # speed up boundary list computation (optional)
  - matplotlib
  - imageio
  - pandas
  - scipy
  - pip
  - pip:
      - islpy # used to optimize staggered kernels
      - py-cpuinfo # get cpu info like cache sizes, supported vector instruction sets, ...
      - graphviz  # can show abstract syntax trees as formatted graphs
      - ipy_table  # HTML tables for jupyter notebooks
      - pyevtk # VTK output for serial simulations
      - blitzdb # file-based No-SQL database to store simulation results
      - pystencils
      #- cupy # add this if you have CUDA or ROCm installed

binder/start

0 → 100755
+6 −0
Original line number Diff line number Diff line
#!/bin/bash

python3 setup.py develop

export MPMATH_NOGMPY=1
exec "$@"
 No newline at end of file

conftest.py

0 → 100644
+177 −0
Original line number Diff line number Diff line
import os
import pytest
import tempfile
import runpy
import sys
import warnings
import platform
import pathlib

import nbformat
import nbconvert
import sympy

from lbmpy._compat import IS_PYSTENCILS_2

# Trigger config file reading / creation once - to avoid race conditions when multiple instances are creating it
# at the same time
if not IS_PYSTENCILS_2:
    from pystencils.cpu import cpujit

# trigger cython imports - there seems to be a problem when multiple processes try to compile the same cython file
# at the same time
try:
    import pyximport

    pyximport.install(language_level=3)
    from lbmpy.phasefield.simplex_projection import simplex_projection_2d  # NOQA
except ImportError:
    pass

SCRIPT_FOLDER = os.path.dirname(os.path.realpath(__file__))
sys.path.insert(0, os.path.abspath('lbmpy'))

# the Ubuntu pipeline uses an older version of pytest which uses deprecated functionality.
# This leads to many warinings in the test and coverage pipeline.
pytest_numeric_version = [int(x, 10) for x in pytest.__version__.split('.')]
pytest_numeric_version.reverse()
pytest_version = sum(x * (100 ** i) for i, x in enumerate(pytest_numeric_version))


def add_path_to_ignore(path):
    if not os.path.exists(path):
        return
    global collect_ignore
    collect_ignore += [os.path.join(SCRIPT_FOLDER, path, f) for f in os.listdir(os.path.join(SCRIPT_FOLDER, path))]


collect_ignore = [os.path.join(SCRIPT_FOLDER, "doc", "conf.py"),
                  os.path.join(SCRIPT_FOLDER, "doc", "img", "mb_discretization", "maxwell_boltzmann_stencil_plot.py")]
add_path_to_ignore('_local_tmp')

if IS_PYSTENCILS_2:
    #   TODO: Fix these step-by-step
    collect_ignore += [
        os.path.join(SCRIPT_FOLDER, "doc", "notebooks", "10_tutorial_conservative_allen_cahn_two_phase.ipynb"),
        os.path.join(SCRIPT_FOLDER, "tests", "test_compiled_in_boundaries.ipynb")
    ]

try:
    import cupy
except ImportError:
    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_cpu_gpu_equivalence.py")]

try:
    import waLBerla
except ImportError:
    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_datahandling_parallel.py")]

try:
    import blitzdb
except ImportError:
    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/benchmark"),
                       os.path.join(SCRIPT_FOLDER,
                                    "tests/full_scenarios/kida_vortex_flow/scenario_kida_vortex_flow.py"),
                       os.path.join(SCRIPT_FOLDER, "tests/full_scenarios/shear_wave/scenario_shear_wave.py"),
                       os.path.join(SCRIPT_FOLDER, "tests/test_json_serializer.py"),
                       os.path.join(SCRIPT_FOLDER, "src/lbmpy/db.py")]

if platform.system().lower() == 'windows':
    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_quicktests.py")]

sver = sympy.__version__.split(".")
if int(sver[0]) == 1 and int(sver[1]) < 2:
    add_path_to_ignore('tests/phasefield')
    collect_ignore += [os.path.join(SCRIPT_FOLDER, "tests/test_n_phase_boyer_noncoupled.ipynb")]

collect_ignore += [os.path.join(SCRIPT_FOLDER, 'setup.py')]

for root, sub_dirs, files in os.walk('.'):
    for f in files:
        if f.endswith(".ipynb") and not any(f.startswith(k) for k in ['demo', 'tutorial', 'test', 'doc']):
            collect_ignore.append(f)


class IPythonMockup:
    def run_line_magic(self, *args, **kwargs):
        pass

    def run_cell_magic(self, *args, **kwargs):
        pass

    def magic(self, *args, **kwargs):
        pass

    def __bool__(self):
        return False


class IPyNbTest(pytest.Item):
    def __init__(self, name, parent, code):
        super(IPyNbTest, self).__init__(name, parent)
        self.code = code
        self.add_marker('notebook')

    def runtest(self):
        global_dict = {'get_ipython': lambda: IPythonMockup(),
                       'is_test_run': True}

        # disable matplotlib output
        exec("import matplotlib.pyplot as p; "
             "p.close('all'); "
             "p.switch_backend('Template')", global_dict)

        # in notebooks there is an implicit plt.show() - if this is not called a warning is shown when the next
        # plot is created. This warning is suppressed here
        # Also animations cannot be shown, which also leads to a warning.
        exec("import warnings;"
             "warnings.filterwarnings('ignore', 'Adding an axes using the same arguments as a previous.*');"
             "warnings.filterwarnings('ignore', 'Animation was deleted without rendering anything.*');",
             global_dict)
        with tempfile.NamedTemporaryFile() as f:
            f.write(self.code.encode())
            f.flush()
            runpy.run_path(f.name, init_globals=global_dict, run_name=self.name)

        #   Close any open figures
        exec("import matplotlib.pyplot as p; "
             "p.close('all')", global_dict)


class IPyNbFile(pytest.File):
    def collect(self):
        exporter = nbconvert.PythonExporter()
        exporter.exclude_markdown = True
        exporter.exclude_input_prompt = True

        notebook_contents = self.fspath.open(encoding='utf-8')

        with warnings.catch_warnings():
            warnings.filterwarnings("ignore", "IPython.core.inputsplitter is deprecated")
            notebook = nbformat.read(notebook_contents, 4)
            code, _ = exporter.from_notebook_node(notebook)
            if pytest_version >= 50403:
                yield IPyNbTest.from_parent(name=self.name, parent=self, code=code)
            else:
                yield IPyNbTest(self.name, self, code)

    def teardown(self):
        pass


if pytest_version >= 70000:
    #   Since pytest 7.0, usage of `py.path.local` is deprecated and `pathlib.Path` should be used instead
    import pathlib

    def pytest_collect_file(file_path: pathlib.Path, parent):
        glob_exprs = ["*demo*.ipynb", "*tutorial*.ipynb", "test_*.ipynb"]
        if any(file_path.match(g) for g in glob_exprs):
            return IPyNbFile.from_parent(path=file_path, parent=parent)
else:
    def pytest_collect_file(path, parent):
        glob_exprs = ["*demo*.ipynb", "*tutorial*.ipynb", "test_*.ipynb"]
        if any(path.fnmatch(g) for g in glob_exprs):
            if pytest_version >= 50403:
                return IPyNbFile.from_parent(fspath=path, parent=parent)
            else:
                return IPyNbFile(path, parent)
+56 −5
Original line number Diff line number Diff line
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
#
import datetime
import sphinx_rtd_theme
import os
import sys
import re
import lbmpy

sys.path.insert(0, os.path.abspath('..'))
sys.path.insert(0, os.path.abspath('../../pystencils'))
sys.path.insert(0, os.path.abspath('../..'))
from sphinx_doc_conf import *
sys.path.insert(0, os.path.abspath('.'))

extensions = [
    'sphinx.ext.autodoc',
    'sphinx.ext.doctest',
    'sphinx.ext.intersphinx',
    'sphinx.ext.mathjax',
    'sphinx.ext.napoleon',
    'nbsphinx',
    'sphinxcontrib.bibtex',
    'sphinx_autodoc_typehints',
]

add_module_names = False
templates_path = ['_templates']
source_suffix = '.rst'
master_doc = 'index'

copyright = f'{datetime.datetime.now().year}, Martin Bauer, Markus Holzer, Frederik Hennig'
author = 'Martin Bauer, Markus Holzer, Frederik Hennig'
# The short X.Y version (including .devXXXX, rcX, b1 suffixes if present)
version = re.sub(r'(\d+\.\d+)\.\d+(.*)', r'\1\2', lbmpy.__version__)
version = re.sub(r'(\.dev\d+).*?$', r'\1', version)
# The full version, including alpha/beta/rc tags.
release = lbmpy.__version__
language = 'en'
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', '**.ipynb_checkpoints']
default_role = 'any'
pygments_style = 'sphinx'
todo_include_todos = False

# Options for HTML output

html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
html_theme = 'sphinx_rtd_theme'
htmlhelp_basename = 'pystencilsdoc'
html_sidebars = {'**': ['globaltoc.html', 'relations.html', 'sourcelink.html', 'searchbox.html']}

# NbSphinx configuration
nbsphinx_execute = 'never'
nbsphinx_codecell_lexer = 'python3'

# Example configuration for intersphinx: refer to the Python standard library.
intersphinx_mapping = {'python': ('https://docs.python.org/3.6', None),
                       'numpy': ('https://docs.scipy.org/doc/numpy/', None),
                       'matplotlib': ('https://matplotlib.org/', None),
                       'sympy': ('https://docs.sympy.org/latest/', None),
                       }

autodoc_member_order = 'bysource'
bibtex_bibfiles = ['sphinx/lbmpy.bib']

project = 'lbmpy'
html_logo = "img/logo.png"
html_logo = 'img/logo.png'

doc/img/Boundary.svg

0 → 100644
+149 −0

File added.

Preview size limit exceeded, changes collapsed.

doc/img/lbmpy-logo.svg

0 → 100644
+794 −0

File added.

Preview size limit exceeded, changes collapsed.

+262 −32
Original line number Diff line number Diff line
@@ -2,23 +2,23 @@
<!-- Created with Inkscape (http://www.inkscape.org/) -->

<svg
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:cc="http://creativecommons.org/ns#"
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:svg="http://www.w3.org/2000/svg"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   width="53.913788mm"
   height="53.913788mm"
   viewBox="0 0 53.913788 53.913788"
   version="1.1"
   id="svg834"
   inkscape:version="0.92.3 (2405546, 2018-03-11)"
   inkscape:version="1.4.2 (ebf0e940d0, 2025-05-08)"
   sodipodi:docname="logo.svg"
   inkscape:export-filename="/local/bauer/code/lbmpy/lbmpy/doc/img/logo.png"
   inkscape:export-xdpi="70.669998"
   inkscape:export-ydpi="70.669998">
   inkscape:export-ydpi="70.669998"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:svg="http://www.w3.org/2000/svg"
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:cc="http://creativecommons.org/ns#"
   xmlns:dc="http://purl.org/dc/elements/1.1/">
  <defs
     id="defs828">
    <marker
@@ -480,6 +480,158 @@
       effect="spiro"
       id="path-effect4188-7"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-3"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         id="path1421-6"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)"
         inkscape:connector-curvature="0" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-75"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-3"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-5"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-6"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-6-2"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-7-9"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-7-1"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-2-27"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-2-0"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-3-9"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-2-6-36"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-2-5-0"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-3-7-6"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-2-6-3-2"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-2-5-9-61"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-3-7-4-8"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-2-2-7"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-2-8-9"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-3-4-2"
       is_visible="true" />
    <marker
       inkscape:stockid="Arrow1Send"
       orient="auto"
       refY="0"
       refX="0"
       id="Arrow1Send-8-6-9-0"
       style="overflow:visible"
       inkscape:isstock="true">
      <path
         inkscape:connector-curvature="0"
         id="path1421-2-7-4-2"
         d="M 0,0 5,-5 -12.5,0 5,5 Z"
         style="fill:#dddddd;fill-opacity:1;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.00000003pt;stroke-opacity:1"
         transform="matrix(-0.2,0,0,-0.2,-1.2,0)" />
    </marker>
    <inkscape:path-effect
       effect="spiro"
       id="path-effect1404-7-7-5-3"
       is_visible="true" />
  </defs>
  <sodipodi:namedview
     id="base"
@@ -488,26 +640,32 @@
     borderopacity="1.0"
     inkscape:pageopacity="0.0"
     inkscape:pageshadow="2"
     inkscape:zoom="0.98994949"
     inkscape:cx="159.4121"
     inkscape:cy="-32.506835"
     inkscape:zoom="1.4"
     inkscape:cx="158.21429"
     inkscape:cy="251.78571"
     inkscape:document-units="mm"
     inkscape:current-layer="layer1"
     showgrid="false"
     inkscape:window-width="498"
     inkscape:window-height="394"
     inkscape:window-x="2210"
     inkscape:window-y="646"
     inkscape:window-width="1557"
     inkscape:window-height="1122"
     inkscape:window-x="0"
     inkscape:window-y="0"
     inkscape:window-maximized="0"
     fit-margin-top="0"
     fit-margin-left="0"
     fit-margin-right="0"
     fit-margin-bottom="0">
     fit-margin-bottom="0"
     inkscape:showpageshadow="0"
     inkscape:pagecheckerboard="1"
     inkscape:deskcolor="#d1d1d1">
    <inkscape:grid
       type="xygrid"
       id="grid1886"
       originx="-9.8407853"
       originy="-227.28709" />
       originy="-227.28709"
       spacingy="1"
       spacingx="1"
       units="mm" />
  </sodipodi:namedview>
  <metadata
     id="metadata831">
@@ -536,21 +694,11 @@
       ry="3.0735996"
       inkscape:export-xdpi="188.45"
       inkscape:export-ydpi="188.45" />
    <text
       xml:space="preserve"
       style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:2.11666656px;line-height:125%;font-family:'Latin Modern Mono Light';-inkscape-font-specification:'Latin Modern Mono Light, ';letter-spacing:0px;word-spacing:0px;fill:#ffffff;fill-opacity:1;stroke:none;stroke-width:0.26458332px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
       x="13.547134"
       y="63.204773"
    <path
       style="font-weight:bold;font-size:16.9333px;line-height:125%;font-family:'Latin Modern Mono Light';-inkscape-font-specification:'Latin Modern Mono Light, Bold';letter-spacing:0px;word-spacing:0px;fill:#ffffff;stroke-width:0.264583px"
       d="m 21.505785,62.578241 c 0,-0.626532 -0.474132,-0.643466 -0.795865,-0.643466 h -2.015062 v -8.26345 c 0,-0.609599 -0.118533,-0.812798 -0.795865,-0.812798 h -2.607729 c -0.321732,0 -0.812798,0.01693 -0.812798,0.643465 0,0.609599 0.507999,0.626532 0.795865,0.626532 h 2.015063 v 7.806251 h -1.99813 c -0.321732,0 -0.812798,0.01693 -0.812798,0.643466 0,0.609599 0.507999,0.626532 0.795865,0.626532 h 5.435589 c 0.3048,0 0.795865,-0.01693 0.795865,-0.626532 z m 9.228643,-3.064927 c 0,-2.116663 -1.54093,-3.776126 -3.352793,-3.776126 -0.728132,0 -1.405464,0.237066 -1.964263,0.643465 v -2.709328 c 0,-0.609599 -0.118533,-0.812798 -0.795865,-0.812798 h -1.202265 c -0.321732,0 -0.812798,0.01693 -0.812798,0.643465 0,0.609599 0.507999,0.626532 0.795865,0.626532 h 0.609599 v 8.263451 c 0,0.406399 0.01693,0.812798 0.711198,0.812798 0.524933,0 0.660399,-0.237066 0.677332,-0.575732 0.643466,0.541865 1.303865,0.677332 1.79493,0.677332 1.862663,0 3.53906,-1.625597 3.53906,-3.793059 z m -1.388531,0 c 0,1.49013 -1.083731,2.523061 -2.184395,2.523061 -1.202265,0 -1.727197,-1.371597 -1.727197,-2.116662 v -1.202265 c 0,-0.914398 0.897465,-1.710263 1.862663,-1.710263 1.151464,0 2.048929,1.151465 2.048929,2.506129 z m 10.820373,3.064927 c 0,-0.558799 -0.321733,-0.643466 -0.931331,-0.643466 v -3.860792 c 0,-0.355599 -0.03387,-2.336795 -1.608664,-2.336795 -0.474132,0 -1.117598,0.186266 -1.608663,0.745065 -0.287867,-0.491066 -0.745066,-0.745065 -1.269998,-0.745065 -0.491066,0 -0.948265,0.169333 -1.337731,0.474132 -0.118533,-0.372533 -0.440265,-0.389466 -0.745065,-0.389466 h -0.524932 c -0.3048,0 -0.812799,0.03387 -0.812799,0.626532 0,0.558799 0.321733,0.643466 0.931332,0.643466 v 4.842923 c -0.609599,0 -0.931332,0.08467 -0.931332,0.643466 0,0.609599 0.524933,0.626532 0.812799,0.626532 h 1.43933 c 0.3048,0 0.761999,-0.01693 0.761999,-0.626532 0,-0.558799 -0.270933,-0.643466 -0.880532,-0.643466 v -2.827861 c 0,-1.354664 0.575732,-2.099729 1.219198,-2.099729 0.321733,0 0.474132,0.270933 0.474132,1.219198 v 3.708392 c -0.355599,0.01693 -0.677332,0.1016 -0.677332,0.643466 0,0.609599 0.474133,0.626532 0.761999,0.626532 h 1.236131 c 0.304799,0 0.761998,-0.01693 0.761998,-0.626532 0,-0.558799 -0.287866,-0.643466 -0.897465,-0.643466 v -2.827861 c 0,-1.354664 0.592666,-2.099729 1.219198,-2.099729 0.338666,0 0.474132,0.270933 0.474132,1.219198 v 3.708392 c -0.338666,0.01693 -0.660398,0.1016 -0.660398,0.643466 0,0.609599 0.474132,0.626532 0.745065,0.626532 h 1.236131 c 0.304799,0 0.812798,-0.01693 0.812798,-0.626532 z m 9.829776,-3.064927 c 0,-2.116663 -1.540931,-3.776126 -3.352794,-3.776126 -0.728132,0 -1.422397,0.237066 -1.981196,0.660398 -0.01693,-0.389466 -0.169333,-0.575732 -0.778932,-0.575732 H 42.68086 c -0.321733,0 -0.812798,0.03387 -0.812798,0.643466 0,0.609598 0.507999,0.626532 0.795865,0.626532 h 0.609598 v 8.500516 H 42.68086 c -0.321733,0 -0.812798,0.01693 -0.812798,0.643466 0,0.609598 0.507999,0.626532 0.795865,0.626532 h 2.624661 c 0.287866,0 0.795865,-0.01693 0.795865,-0.626532 0,-0.626532 -0.491065,-0.643466 -0.812798,-0.643466 h -0.592666 v -2.963327 c 0.643466,0.558799 1.286931,0.677332 1.777997,0.677332 1.862663,0 3.53906,-1.625597 3.53906,-3.793059 z m -1.388531,0 c 0,1.49013 -1.083731,2.523061 -2.184396,2.523061 -1.202264,0 -1.727196,-1.371597 -1.727196,-2.116662 v -1.202265 c 0,-0.914398 0.897465,-1.710263 1.862663,-1.710263 1.151464,0 2.048929,1.151465 2.048929,2.506129 z M 59.08922,56.46532 c 0,-0.626533 -0.474133,-0.643466 -0.795865,-0.643466 h -1.930397 c -0.304799,0 -0.795865,0.03387 -0.795865,0.626532 0,0.626532 0.474133,0.643466 0.795865,0.643466 h 0.270933 l -1.456264,4.419591 -1.676396,-4.419591 h 0.220133 c 0.304799,0 0.795865,-0.01693 0.795865,-0.626532 0,-0.626533 -0.474133,-0.643466 -0.795865,-0.643466 h -1.930397 c -0.321732,0 -0.795865,0.01693 -0.795865,0.643466 0,0.609598 0.491066,0.626532 0.795865,0.626532 H 52.2143 l 2.370662,5.977455 c -0.06773,0.186266 -0.423333,1.371597 -0.609599,1.744129 -0.338666,0.643466 -0.863598,1.032932 -1.185331,1.032932 0.01693,-0.06773 0.186266,-0.118533 0.186266,-0.372533 0,-0.491066 -0.355599,-0.846665 -0.846665,-0.846665 -0.524932,0 -0.846665,0.355599 -0.846665,0.846665 0,0.761999 0.609599,1.490131 1.490131,1.490131 1.69333,0 2.523062,-2.252129 2.590795,-2.438396 l 2.523061,-7.433718 h 0.4064 c 0.304799,0 0.795865,-0.01693 0.795865,-0.626532 z"
       id="text1392"
       inkscape:export-xdpi="188.45"
       inkscape:export-ydpi="188.45"><tspan
         sodipodi:role="line"
         id="tspan1390"
         x="13.547134"
         y="63.204773"
         style="font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;font-size:16.93333244px;font-family:'Latin Modern Mono Light';-inkscape-font-specification:'Latin Modern Mono Light, Bold';fill:#ffffff;stroke-width:0.26458332px">lbm<tspan
   style="font-size:2.82222223px"
   id="tspan1398"> </tspan>py</tspan></text>
       aria-label="lbm py" />
    <path
       style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-6-9)"
       d="M 36.797679,33.475 H 23.568513"
@@ -622,5 +770,87 @@
         d="m 36.797679,33.475 11.90625,13.229166"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-2-2)" />
    </g>
    <rect
       style="opacity:1;fill:#646ecb;fill-opacity:1;stroke:#d2d2d2;stroke-width:0.5091567;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1"
       id="rect1396-7"
       width="53.404633"
       height="53.404633"
       x="9.9747782"
       y="82.509102"
       ry="3.0735996"
       inkscape:export-xdpi="188.45"
       inkscape:export-ydpi="188.45" />
    <path
       style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:1.22452438;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-6-9-0)"
       d="M 36.299116,109.56879 H 17.132601"
       id="path1402-8-0-4-2"
       inkscape:connector-curvature="0"
       inkscape:path-effect="#path-effect1404-7-7-5-3"
       inkscape:original-d="m 36.299116,109.56879 c -6.171351,0.0481 -12.995819,-0.0487 -19.166515,0"
       sodipodi:nodetypes="cc"
       inkscape:export-xdpi="188.45"
       inkscape:export-ydpi="188.45" />
    <g
       id="g9842-8"
       inkscape:export-xdpi="188.45"
       inkscape:export-ydpi="188.45"
       transform="matrix(1.4488076,0,0,1.4488076,-17.013641,61.069964)">
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="m 36.797679,33.475 c 2.23e-4,-4.259735 2.23e-4,-8.969879 0,-13.229167"
         inkscape:path-effect="#path-effect1404-75"
         inkscape:connector-curvature="0"
         id="path1402-9"
         d="M 36.797679,33.475 V 20.245833"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-3)" />
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="m 36.797679,33.475 c 4.259736,2.23e-4 8.969879,2.23e-4 13.229167,0"
         inkscape:path-effect="#path-effect1404-7-6"
         inkscape:connector-curvature="0"
         id="path1402-8-7"
         d="M 36.797679,33.475 H 50.026846"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-3)" />
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="m 36.797679,33.475 c 0.03317,4.259607 -0.03362,8.97001 0,13.229166"
         inkscape:path-effect="#path-effect1404-7-7-1"
         inkscape:connector-curvature="0"
         id="path1402-8-0-3"
         d="M 36.797679,33.475 V 46.704166"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-6-2)" />
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="m 36.797679,33.475 c 4.259736,2.23e-4 8.13389,-13.228083 12.393178,-13.228306"
         inkscape:path-effect="#path-effect1404-7-3-9"
         inkscape:connector-curvature="0"
         id="path1402-8-9-6"
         d="M 36.797679,33.475 49.190857,20.246694"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-2-27)" />
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="M 36.797679,33.475 C 32.537943,33.475223 27.827801,20.246056 23.568513,20.245833"
         inkscape:path-effect="#path-effect1404-7-3-7-6"
         inkscape:connector-curvature="0"
         id="path1402-8-9-4-1"
         d="M 36.797679,33.475 23.568513,20.245833"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-2-6-36)" />
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="M 36.797679,33.475 C 32.537943,33.474776 27.827801,46.703943 23.568513,46.704166"
         inkscape:path-effect="#path-effect1404-7-3-7-4-8"
         inkscape:connector-curvature="0"
         id="path1402-8-9-4-4-2"
         d="M 36.797679,33.475 23.568513,46.704166"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-2-6-3-2)" />
      <path
         sodipodi:nodetypes="cc"
         inkscape:original-d="m 36.797679,33.475 c 4.259736,-2.23e-4 7.646962,13.228943 11.90625,13.229166"
         inkscape:path-effect="#path-effect1404-7-3-4-2"
         inkscape:connector-curvature="0"
         id="path1402-8-9-3-9"
         d="m 36.797679,33.475 11.90625,13.229166"
         style="fill:none;fill-rule:evenodd;stroke:#dddddd;stroke-width:0.84519458;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Send-8-2-2-7)" />
    </g>
  </g>
</svg>
+3 −0
Original line number Diff line number Diff line
@@ -6,6 +6,9 @@ lbmpy
    :maxdepth: 2

    sphinx/tutorials.rst
    sphinx/methods.rst
    sphinx/boundary_conditions.rst
    sphinx/forcemodels.rst
    sphinx/api.rst


Original line number Diff line number Diff line
@@ -5,13 +5,13 @@ API Reference
   :maxdepth: 1

   scenarios.rst
   kernelcreation.rst
   methodcreation.rst
   enums.rst
   stencils.rst
   methods.rst
   kernelcreation.rst
   equilibrium.rst
   moment_transforms.rst
   maxwellian_equilibrium.rst
   continuous_distribution_measures.rst
   moments.rst
   cumulants.rst
   forcemodels.rst
   zbibliography.rst
+6 −0
Original line number Diff line number Diff line
*******************
Boundary Conditions
*******************

.. automodule:: lbmpy.boundaries.boundaryconditions
   :members:

doc/sphinx/enums.rst

0 → 100644
+6 −0
Original line number Diff line number Diff line
************
Enumerations
************

.. automodule:: lbmpy.enums
   :members:
+33 −0
Original line number Diff line number Diff line
*********************************************
Equilibrium Distributions (lbmpy.equilibrium)
*********************************************

.. automodule:: lbmpy.equilibrium


Abstract Base Class
===================

.. autoclass:: lbmpy.equilibrium.AbstractEquilibrium
    :members:
    :private-members: _monomial_raw_moment, _monomial_central_moment, _monomial_cumulant

Generic Discrete Equilibria
===========================

Use the following class for custom discrete equilibria.

.. autoclass:: lbmpy.equilibrium.GenericDiscreteEquilibrium
    :members:

Maxwellian Equilibria for Hydrodynamics
=======================================

The following classes represent the continuous and the discrete variant of the Maxwellian equilibrium for
hydrodynamics.

.. autoclass:: lbmpy.equilibrium.ContinuousHydrodynamicMaxwellian
    :members:

.. autoclass:: lbmpy.equilibrium.DiscreteHydrodynamicMaxwellian
    :members:

File changed.

Preview size limit exceeded, changes collapsed.

Original line number Diff line number Diff line
**********************
Maxwellian Equilibrium
**********************
*******************************
Maxwellian Equilibrium (Legacy)
*******************************

.. automodule:: lbmpy.maxwellian_equilibrium
    :members:
@@ -11,7 +11,7 @@ Maxwellian Equilibrium

    .. autofunction:: lbmpy.maxwellian_equilibrium.continuous_maxwellian_equilibrium

    .. autofunction:: lbmpy.maxwellian_equilibrium.get_moments_of_continuous_maxwellian_equilibrium
    .. autofunction:: lbmpy.maxwellian_equilibrium.get_equilibrium_values_of_maxwell_boltzmann_function

    .. autofunction:: lbmpy.maxwellian_equilibrium.get_moments_of_discrete_maxwellian_equilibrium

doc/sphinx/methodcreation.rst

deleted100644 → 0
+0 −8
Original line number Diff line number Diff line
Creating LBM methods
====================

This module is a lower level API to construct methods.
When possible use the high level API.

.. automodule:: lbmpy.methods.creationfunctions
    :members:
Original line number Diff line number Diff line
@@ -2,4 +2,4 @@ Bibliography
------------

.. bibliography:: lbmpy.bib
   :cited:
 No newline at end of file
   :all:
 No newline at end of file

lbmpy/boundaries/__init__.py

deleted100644 → 0
+0 −4
Original line number Diff line number Diff line
from lbmpy.boundaries.boundaryconditions import NoSlip, UBB, FixedDensity, NeumannByCopy, StreamInConstant
from lbmpy.boundaries.boundaryhandling import LatticeBoltzmannBoundaryHandling

__all__ = ['NoSlip', 'UBB', 'FixedDensity', 'NeumannByCopy', 'LatticeBoltzmannBoundaryHandling', 'StreamInConstant']

lbmpy/creationfunctions.py

deleted100644 → 0
+0 −565

File deleted.

Preview size limit exceeded, changes collapsed.

lbmpy/forcemodels.py

deleted100644 → 0
+0 −207

File deleted.

Preview size limit exceeded, changes collapsed.

lbmpy/methods/__init__.py

deleted100644 → 0
+0 −12
Original line number Diff line number Diff line
from lbmpy.methods.momentbased import RelaxationInfo, AbstractLbMethod, AbstractConservedQuantityComputation, \
    MomentBasedLbMethod
from .conservedquantitycomputation import DensityVelocityComputation
from lbmpy.methods.creationfunctions import create_srt, create_trt, create_trt_with_magic_number, create_trt_kbc, \
    create_mrt_orthogonal, create_mrt_raw, create_mrt3, \
    create_with_continuous_maxwellian_eq_moments, create_with_discrete_maxwellian_eq_moments

__all__ = ['RelaxationInfo', 'AbstractLbMethod',
           'AbstractConservedQuantityComputation', 'DensityVelocityComputation', 'MomentBasedLbMethod',
           'create_srt', 'create_trt', 'create_trt_with_magic_number', 'create_trt_kbc',
           'create_mrt_orthogonal', 'create_mrt_raw', 'create_mrt3',
           'create_with_continuous_maxwellian_eq_moments', 'create_with_discrete_maxwellian_eq_moments']

lbmpy/stencils.py

deleted100644 → 0
+0 −87

File deleted.

Preview size limit exceeded, changes collapsed.

lbmpy/turbulence_models.py

deleted100644 → 0
+0 −43

File deleted.

Preview size limit exceeded, changes collapsed.

noxfile.py

0 → 100644
+170 −0

File added.

Preview size limit exceeded, changes collapsed.

pyproject.toml

0 → 100644
+92 −0

File added.

Preview size limit exceeded, changes collapsed.

pytest.ini

0 → 100644
+61 −0

File added.

Preview size limit exceeded, changes collapsed.

quicktest.py

0 → 100644
+22 −0

File added.

Preview size limit exceeded, changes collapsed.

+19 −31

File changed.

Preview size limit exceeded, changes collapsed.

src/lbmpy/__init__.py

0 → 100644
+61 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/_compat.py

0 → 100644
+42 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/_version.py

0 → 100644
+683 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/db.py

0 → 100644
+47 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/enums.py

0 → 100644
+238 −0

File added.

Preview size limit exceeded, changes collapsed.

+597 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/oldroydb.py

0 → 100644
+210 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/stencils.py

0 → 100644
+687 −0

File added.

Preview size limit exceeded, changes collapsed.

src/lbmpy/utils.py

0 → 100644
+28 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/__init__.py

0 → 100644
+0 −0
Original line number Diff line number Diff line

tests/poiseuille.py

0 → 100644
+132 −0

File added.

Preview size limit exceeded, changes collapsed.

+155 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_entropic.py

0 → 100644
+22 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_force.py

0 → 100644
+419 −0

File added.

Preview size limit exceeded, changes collapsed.

+80 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_oldroydb.py

0 → 100755
+267 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_psm.py

0 → 100644
+68 −0

File added.

Preview size limit exceeded, changes collapsed.

+213 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_stencils.py

0 → 100644
+110 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_weights.py

0 → 100644
+34 −0

File added.

Preview size limit exceeded, changes collapsed.

tests/test_welford.py

0 → 100644
+92 −0

File added.

Preview size limit exceeded, changes collapsed.