{"id":14673135,"url":"https://github.com/jorgensd/dolfinx-tutorial","last_synced_at":"2025-10-09T02:38:56.681Z","repository":{"id":37091595,"uuid":"316747023","full_name":"jorgensd/dolfinx-tutorial","owner":"jorgensd","description":"A reimplementation of the Springer book: https://github.com/hplgit/fenics-tutorial/, covering new topics as well as transitioning from dolfin to dolfinx","archived":false,"fork":false,"pushed_at":"2025-10-01T18:52:41.000Z","size":408404,"stargazers_count":145,"open_issues_count":16,"forks_count":73,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-10-01T20:39:48.308Z","etag":null,"topics":["fenics","fenicsx","finite-element-methods","tutorial"],"latest_commit_sha":null,"homepage":"https://jorgensd.github.io/dolfinx-tutorial/","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jorgensd.png","metadata":{"files":{"readme":"README.md","changelog":"Changelog.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-11-28T14:05:33.000Z","updated_at":"2025-10-01T18:52:53.000Z","dependencies_parsed_at":"2023-02-17T10:45:57.856Z","dependency_job_id":"4f9873d2-8050-4ea7-ab45-4127359c99a5","html_url":"https://github.com/jorgensd/dolfinx-tutorial","commit_stats":null,"previous_names":[],"tags_count":13,"template":false,"template_full_name":null,"purl":"pkg:github/jorgensd/dolfinx-tutorial","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgensd%2Fdolfinx-tutorial","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgensd%2Fdolfinx-tutorial/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgensd%2Fdolfinx-tutorial/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgensd%2Fdolfinx-tutorial/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jorgensd","download_url":"https://codeload.github.com/jorgensd/dolfinx-tutorial/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgensd%2Fdolfinx-tutorial/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000776,"owners_count":26082906,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fenics","fenicsx","finite-element-methods","tutorial"],"created_at":"2024-09-12T06:03:37.651Z","updated_at":"2025-10-09T02:38:56.670Z","avatar_url":"https://github.com/jorgensd.png","language":"Jupyter Notebook","readme":"# The DOLFINx tutorial\n\n[![Test, build and publish](https://github.com/jorgensd/dolfinx-tutorial/actions/workflows/deploy.yml/badge.svg)](https://github.com/jorgensd/dolfinx-tutorial/actions/workflows/deploy.yml)\n[![Test release branch against DOLFINx nightly build](https://github.com/jorgensd/dolfinx-tutorial/actions/workflows/test_nightly.yml/badge.svg)](https://github.com/jorgensd/dolfinx-tutorial/actions/workflows/test_nightly.yml)\n\nAuthor: Jørgen S. Dokken\n\nThis is the source code for the dolfinx-tutorial [webpage](https://jorgensd.github.io/dolfinx-tutorial/).\nIf you have any comments, corrections or questions, please submit an issue in the issue tracker.\n\n## Contributing\n\nIf you want to contribute to this tutorial, please make a fork of the repository, make your changes, and test that the CI passes. \n\nAlternatively, if you want to add a separate chapter, a Jupyter notebook can be added to a pull request, without integrating it into the tutorial. If so, the notebook will be reviewed and modified to be included in the tutorial.\n\nAny code added to the tutorial should work in parallel. If any changes are made to `ipynb` files, please ensure that these changes are reflected in the corresponding `py` files by using [`jupytext`](https://jupytext.readthedocs.io/en/latest/faq.html#can-i-use-jupytext-with-jupyterhub-binder-nteract-colab-saturn-or-azure):\n\n\n## Building the book and running code\nThe book is built using [jupyterbook](https://jupyterbook.org/). The following environment variables should be set if you want to build the book\n```bash\nPYVISTA_OFF_SCREEN=false\nPYVISTA_JUPYTER_BACKEND=\"html\"\nJUPYTER_EXTENSION_ENABLED=true\nLIBGL_ALWAYS_SOFTWARE=1\n```\n\nIf you run the tutorial using `jupyter-lab`, for instance through `conda`, one should set the following environment variables\n```bash\nPYVISTA_OFF_SCREEN=false\nPYVISTA_JUPYTER_BACKEND=\"trame\"\nJUPYTER_EXTENSION_ENABLED=true\nLIBGL_ALWAYS_SOFTWARE=1\n```\nIf you use docker to run your code, you should set the following variables:\n```bash\ndocker run -ti -e DISPLAY=$DISPLAY -e LIBGL_ALWAYS_SOFTWARE=1 -e PYVISTA_OFF_SCREEN=false -e PYVISTA_JUPYTER_BACKEND=\"trame\" -e JUPYTER_EXTENSION_ENABLED=true --network=host -v $(pwd):/root/shared -w /root/shared  ....\n```\n\nTo run python scripts, either choose `PYVISTA_OFF_SCREEN=True` to get screenshots, or render interactive plots with `PYVISTA_OFF_SCREEN=False`\n\n\n```bash\npython3 -m jupytext --sync  */*.ipynb --set-formats ipynb,py:light\n```\nor\n```bash\npython3 -m jupytext --sync  */*.py --set-formats ipynb,py:light\n```\n\nAny code added to the tutorial should work in parallel.\n\nTo strip notebook output, one can use pre-commit.\n\n```bash\npre-commit run --all-files\n```\n\n## Dependencies\n\nIt is adviced to use a pre-installed version of DOLFINx, for instance through conda or docker. Remaining dependencies can be installed with\n\n```bash\npython3 -m pip install --no-binary=h5py -e .\n```\n\n# Docker images\n\nDocker images for this tutorial can be found in the [packages tab](https://github.com/jorgensd/dolfinx-tutorial/pkgs/container/dolfinx-tutorial)\n\nAdditional requirements on top of the `dolfinx/lab:nightly` images can be found at [Dockerfile](docker/Dockerfile) and [pyproject.toml](./pyproject.toml)\n\n##\n\nAn image building DOLFINx, Basix, UFL and FFCx from source can be built using:\n\n```bash\ndocker build -f ./docker/Dockerfile -t local_lab_env .\n```\n\nfrom the root of this repository, and run\n\n```bash\n docker run --rm -ti -v $(pwd):/root/shared -w /root/shared  --init -p 8888:8888 local_lab_env\n```\n\nfrom the main directory.\n","funding_links":[],"categories":["Tutorial"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjorgensd%2Fdolfinx-tutorial","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjorgensd%2Fdolfinx-tutorial","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjorgensd%2Fdolfinx-tutorial/lists"}