--- /srv/reproducible-results/rbuild-debian/r-b-build.Fn23RIaf/b1/fenics-dolfinx_0.8.0-11_arm64.changes +++ /srv/reproducible-results/rbuild-debian/r-b-build.Fn23RIaf/b2/fenics-dolfinx_0.8.0-11_arm64.changes ├── Files │ @@ -1,9 +1,9 @@ │ │ - 89885bc94ba16d81f037605465c16a40 1200124 doc optional dolfinx-doc_0.8.0-11_all.deb │ + ff698895cab073527de6e23435932480 1200060 doc optional dolfinx-doc_0.8.0-11_all.deb │ e615d017f09091ec23c4fe5a241359f6 46804 libdevel optional libdolfinx-complex-dev_0.8.0-11_arm64.deb │ ee3676b36f6aec48e372335c05f56c8f 12151648 debug optional libdolfinx-complex0.8-dbgsym_0.8.0-11_arm64.deb │ 286182914802e9e11d922e97a623850e 532300 libs optional libdolfinx-complex0.8_0.8.0-11_arm64.deb │ 0ec9d47a0ac1720a7386f83e95f9d6be 207932 libdevel optional libdolfinx-dev_0.8.0-11_arm64.deb │ 11f0dec6431f198720fc7c917a3ab82f 46820 libdevel optional libdolfinx-real-dev_0.8.0-11_arm64.deb │ 8a413548518f54ff9afdda6f15f0f59e 12153604 debug optional libdolfinx-real0.8-dbgsym_0.8.0-11_arm64.deb │ 7ebe6a7a8a4a93eafe1aa38607bba7ff 532756 libs optional libdolfinx-real0.8_0.8.0-11_arm64.deb ├── dolfinx-doc_0.8.0-11_all.deb │ ├── file list │ │ @@ -1,3 +1,3 @@ │ │ -rw-r--r-- 0 0 0 4 2024-08-28 09:59:47.000000 debian-binary │ │ -rw-r--r-- 0 0 0 21596 2024-08-28 09:59:47.000000 control.tar.xz │ │ --rw-r--r-- 0 0 0 1178336 2024-08-28 09:59:47.000000 data.tar.xz │ │ +-rw-r--r-- 0 0 0 1178272 2024-08-28 09:59:47.000000 data.tar.xz │ ├── control.tar.xz │ │ ├── control.tar │ │ │ ├── ./md5sums │ │ │ │ ├── ./md5sums │ │ │ │ │┄ Files differ │ ├── data.tar.xz │ │ ├── data.tar │ │ │ ├── file list │ │ │ │ @@ -886,17 +886,17 @@ │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/56ce7e71d8c71b4d8ef7c699176dd4fd/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 19145 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/56ce7e71d8c71b4d8ef7c699176dd4fd/demo_stokes.py │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/67f8546536727bd5386a27073bd16e12/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 8030 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/67f8546536727bd5386a27073bd16e12/demo_elasticity.py │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/6ad57720b461988475bd5c9286e3f111/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 7392 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/6ad57720b461988475bd5c9286e3f111/demo_types.py │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/9561cf6cd1a70079b986f4eb31580cbd/ │ │ │ │ --rw-r--r-- 0 root (0) root (0) 3865 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/9561cf6cd1a70079b986f4eb31580cbd/demo_poisson_matrix_free.ipynb.gz │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 3868 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/9561cf6cd1a70079b986f4eb31580cbd/demo_poisson_matrix_free.ipynb.gz │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/9ed4657d08dda04de30e6463e2f58d75/ │ │ │ │ --rw-r--r-- 0 root (0) root (0) 2602 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/9ed4657d08dda04de30e6463e2f58d75/demo_mixed-poisson.ipynb.gz │ │ │ │ +-rw-r--r-- 0 root (0) root (0) 2603 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/9ed4657d08dda04de30e6463e2f58d75/demo_mixed-poisson.ipynb.gz │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/b94ac7be61dc3726ca331afd20f195d2/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 5600 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/b94ac7be61dc3726ca331afd20f195d2/demo_poisson.py │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/e8140d02a100265518e126a3cfe79d8e/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 3877 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/e8140d02a100265518e126a3cfe79d8e/demo_interpolation-io.py │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/e8b180b39a27d7b04c2f666d14475ee3/ │ │ │ │ -rw-r--r-- 0 root (0) root (0) 11162 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/e8b180b39a27d7b04c2f666d14475ee3/demo_cahn-hilliard.py │ │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2024-08-28 09:59:47.000000 ./usr/share/doc/dolfinx-doc/python/_downloads/f6f3cc4d9540871af057920d1ddb5561/ │ │ │ ├── ./usr/share/doc/dolfinx-doc/python/_downloads/9561cf6cd1a70079b986f4eb31580cbd/demo_poisson_matrix_free.ipynb.gz │ │ │ │ ├── demo_poisson_matrix_free.ipynb │ │ │ │ │ ├── Pretty-printed │ │ │ │ │ │┄ Similarity: 0.9876077586206897% │ │ │ │ │ │┄ Differences: {"'cells'": "{0: {'id': '6ebf7713'}, 1: {'id': '3fd8f953'}, 2: {'id': 'f59e69b7'}, 3: {'id': " │ │ │ │ │ │┄ "'bfc71c38'}, 4: {'id': '15095f3b'}, 5: {'id': '90fe387c'}, 6: {'id': 'b8c130f7'}, 7: " │ │ │ │ │ │┄ "{'id': '3da8c199'}, 8: {'id': '9f6d1b88'}, 9: {'id': '907b71c9'}, 10: {'id': " │ │ │ │ │ │┄ "'6207bc2a'}, 11: {'id': '5094a8d2'}, 12: {'id': 'd0d11a21'}, 13: {'id': '28d02ac2'}, " │ │ │ │ │ │┄ "14: {'id': '5af2ea3c'}, 15: {'id': 'ceebcfab'}, 16: {'id': '67db3fb5'}, 17: {'id': " │ │ │ │ │ │┄ "'461ec7b2'}, 1 […] │ │ │ │ │ │ @@ -1,12 +1,12 @@ │ │ │ │ │ │ { │ │ │ │ │ │ "cells": [ │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "39b96bfc", │ │ │ │ │ │ + "id": "6ebf7713", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Matrix-free conjugate gradient solver for the Poisson equation\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ "This demo illustrates how to solve the Poisson equation using a\n", │ │ │ │ │ │ "matrix-free conjugate gradient (CG) solver. In particular, it\n", │ │ │ │ │ │ "illustrates how to\n", │ │ │ │ │ │ @@ -68,84 +68,84 @@ │ │ │ │ │ │ "\n", │ │ │ │ │ │ "The modules that will be used are imported:" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "49e47488", │ │ │ │ │ │ + "id": "3fd8f953", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "from mpi4py import MPI" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "e60fd4b2", │ │ │ │ │ │ + "id": "f59e69b7", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "import numpy as np" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "442e6cd7", │ │ │ │ │ │ + "id": "bfc71c38", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "import dolfinx\n", │ │ │ │ │ │ "import ufl\n", │ │ │ │ │ │ "from dolfinx import fem, la\n", │ │ │ │ │ │ "from ufl import action, dx, grad, inner" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "db864fb7", │ │ │ │ │ │ + "id": "15095f3b", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "We begin by using {py:func}`create_rectangle\n", │ │ │ │ │ │ "` to create a rectangular\n", │ │ │ │ │ │ "{py:class}`Mesh ` of the domain, and creating a\n", │ │ │ │ │ │ "finite element {py:class}`FunctionSpace `\n", │ │ │ │ │ │ "on the mesh." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "364a1f00", │ │ │ │ │ │ + "id": "90fe387c", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "dtype = dolfinx.default_scalar_type\n", │ │ │ │ │ │ "real_type = np.real(dtype(0.0)).dtype\n", │ │ │ │ │ │ "comm = MPI.COMM_WORLD\n", │ │ │ │ │ │ "mesh = dolfinx.mesh.create_rectangle(comm, [[0.0, 0.0], [1.0, 1.0]], [10, 10], dtype=real_type)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "7f8e06eb", │ │ │ │ │ │ + "id": "b8c130f7", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Create function space\n", │ │ │ │ │ │ "degree = 2\n", │ │ │ │ │ │ "V = fem.functionspace(mesh, (\"Lagrange\", degree))" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "ea4c1eb7", │ │ │ │ │ │ + "id": "3da8c199", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "The second argument to {py:class}`functionspace\n", │ │ │ │ │ │ "` is a tuple consisting of `(family,\n", │ │ │ │ │ │ "degree)`, where `family` is the finite element family, and `degree`\n", │ │ │ │ │ │ "specifies the polynomial degree. In this case `V` consists of\n", │ │ │ │ │ │ "third-order, continuous Lagrange finite element functions.\n", │ │ │ │ │ │ @@ -156,94 +156,94 @@ │ │ │ │ │ │ "and then retrieving all facets on the boundary using\n", │ │ │ │ │ │ "{py:func}`exterior_facet_indices `." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "66d154a7", │ │ │ │ │ │ + "id": "9f6d1b88", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "tdim = mesh.topology.dim\n", │ │ │ │ │ │ "mesh.topology.create_connectivity(tdim - 1, tdim)\n", │ │ │ │ │ │ "facets = dolfinx.mesh.exterior_facet_indices(mesh.topology)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "7e474c1a", │ │ │ │ │ │ + "id": "907b71c9", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "We now find the degrees of freedom that are associated with the boundary\n", │ │ │ │ │ │ "facets using\n", │ │ │ │ │ │ "{py:func}`locate_dofs_topological `" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "db0bfb2f", │ │ │ │ │ │ + "id": "6207bc2a", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "dofs = fem.locate_dofs_topological(V=V, entity_dim=tdim - 1, entities=facets)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "ef5fa2dc", │ │ │ │ │ │ + "id": "5094a8d2", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "and use {py:func}`dirichletbc ` to define the\n", │ │ │ │ │ │ "essential boundary condition. On the boundary we prescribe the\n", │ │ │ │ │ │ "{py:class}`Function ` `uD`, which we create by\n", │ │ │ │ │ │ "interpolating the expression $u_{\\rm D}$ in the finite element space\n", │ │ │ │ │ │ "$V$." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "c377c805", │ │ │ │ │ │ + "id": "d0d11a21", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "uD = fem.Function(V, dtype=dtype)\n", │ │ │ │ │ │ "uD.interpolate(lambda x: 1 + x[0] ** 2 + 2 * x[1] ** 2)\n", │ │ │ │ │ │ "bc = fem.dirichletbc(value=uD, dofs=dofs)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "287151ba", │ │ │ │ │ │ + "id": "28d02ac2", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "Next, we express the variational problem using UFL." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "e42c4296", │ │ │ │ │ │ + "id": "5af2ea3c", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "x = ufl.SpatialCoordinate(mesh)\n", │ │ │ │ │ │ "u = ufl.TrialFunction(V)\n", │ │ │ │ │ │ "v = ufl.TestFunction(V)\n", │ │ │ │ │ │ "f = fem.Constant(mesh, dtype(-6.0))\n", │ │ │ │ │ │ "a = inner(grad(u), grad(v)) * dx\n", │ │ │ │ │ │ "L = inner(f, v) * dx\n", │ │ │ │ │ │ "L_fem = fem.form(L, dtype=dtype)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "820d1aa8", │ │ │ │ │ │ + "id": "ceebcfab", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "For the matrix-free solvers we also define a second linear form `M` as\n", │ │ │ │ │ │ "the {py:class}`action ` of the bilinear form $a$ on an\n", │ │ │ │ │ │ "arbitrary {py:class}`Function ` `ui`. This linear\n", │ │ │ │ │ │ "form is defined as\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ @@ -251,78 +251,78 @@ │ │ │ │ │ │ "M(v) = a(u_i, v) \\quad \\text{for} \\; \\ u_i \\in V.\n", │ │ │ │ │ │ "$$" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "70ef1be9", │ │ │ │ │ │ + "id": "67db3fb5", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "ui = fem.Function(V, dtype=dtype)\n", │ │ │ │ │ │ "M = action(a, ui)\n", │ │ │ │ │ │ "M_fem = fem.form(M, dtype=dtype)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "e685041f", │ │ │ │ │ │ + "id": "461ec7b2", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "### Matrix-free conjugate gradient solver\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ "The right hand side vector $b - A x_{\\rm bc}$ is the assembly of the linear\n", │ │ │ │ │ │ "form $L$ where the essential Dirichlet boundary conditions are implemented\n", │ │ │ │ │ │ "using lifting. Since we want to avoid assembling the matrix `A`, we compute\n", │ │ │ │ │ │ "the necessary matrix-vector product using the linear form `M` explicitly." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "6aa3e446", │ │ │ │ │ │ + "id": "91809c2f", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Apply lifting: b <- b - A * x_bc\n", │ │ │ │ │ │ "b = fem.assemble_vector(L_fem)\n", │ │ │ │ │ │ "ui.x.array[:] = 0.0\n", │ │ │ │ │ │ "fem.set_bc(ui.x.array, [bc], scale=-1.0)\n", │ │ │ │ │ │ "fem.assemble_vector(b.array, M_fem)\n", │ │ │ │ │ │ "b.scatter_reverse(la.InsertMode.add)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "5e81249c", │ │ │ │ │ │ + "id": "fbb7247b", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Set BC dofs to zero on right hand side\n", │ │ │ │ │ │ "fem.set_bc(b.array, [bc], scale=0.0)\n", │ │ │ │ │ │ "b.scatter_forward()" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "7ff784d9", │ │ │ │ │ │ + "id": "a35cef52", │ │ │ │ │ │ "metadata": { │ │ │ │ │ │ "lines_to_next_cell": 2 │ │ │ │ │ │ }, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "To implement the matrix-free CG solver using *DOLFINx* vectors, we define the\n", │ │ │ │ │ │ "function `action_A` to compute the matrix-vector product $y = A x$." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "cb736a12", │ │ │ │ │ │ + "id": "4d1693b8", │ │ │ │ │ │ "metadata": { │ │ │ │ │ │ "lines_to_next_cell": 2 │ │ │ │ │ │ }, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "def action_A(x, y):\n", │ │ │ │ │ │ " # Set coefficient vector of the linear form M and ensure it is updated\n", │ │ │ │ │ │ @@ -337,15 +337,15 @@ │ │ │ │ │ │ "\n", │ │ │ │ │ │ " # Set BC dofs to zero\n", │ │ │ │ │ │ " fem.set_bc(y.array, [bc], scale=0.0)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "0474ca03", │ │ │ │ │ │ + "id": "4504208f", │ │ │ │ │ │ "metadata": { │ │ │ │ │ │ "lines_to_next_cell": 2 │ │ │ │ │ │ }, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "### Basic conjugate gradient solver\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ "Solves the problem `A x = b`, using the function `action_A` as the operator,\n", │ │ │ │ │ │ @@ -353,15 +353,15 @@ │ │ │ │ │ │ "vector. `comm` is the MPI Communicator, `max_iter` is the maximum number of\n", │ │ │ │ │ │ "iterations, `rtol` is the relative tolerance." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "f692ac20", │ │ │ │ │ │ + "id": "fa0a917f", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "def cg(comm, action_A, x: la.Vector, b: la.Vector, max_iter: int = 200, rtol: float = 1e-6):\n", │ │ │ │ │ │ " rtol2 = rtol**2\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ " nr = b.index_map.size_local\n", │ │ │ │ │ │ @@ -399,61 +399,61 @@ │ │ │ │ │ │ " p.array[:] = beta * p.array + r\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ " raise RuntimeError(f\"Solver exceeded max iterations ({max_iter}).\")" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "28aad92f", │ │ │ │ │ │ + "id": "7f9a2e05", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "This matrix-free solver is now used to compute the finite element solution.\n", │ │ │ │ │ │ "The finite element solution's approximation error as compared with the\n", │ │ │ │ │ │ "exact solution is measured in the $L_2$-norm." │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "760d68d8", │ │ │ │ │ │ + "id": "e61bb7ce", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "rtol = 1e-6\n", │ │ │ │ │ │ "u = fem.Function(V, dtype=dtype)\n", │ │ │ │ │ │ "iter_cg1 = cg(mesh.comm, action_A, u.x, b, max_iter=200, rtol=rtol)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "5b03f348", │ │ │ │ │ │ + "id": "68cc4440", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Set BC values in the solution vector\n", │ │ │ │ │ │ "fem.set_bc(u.x.array, [bc], scale=1.0)" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "b74aed42", │ │ │ │ │ │ + "id": "1f4e2835", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "def L2Norm(u):\n", │ │ │ │ │ │ " val = fem.assemble_scalar(fem.form(inner(u, u) * dx, dtype=dtype))\n", │ │ │ │ │ │ " return np.sqrt(comm.allreduce(val, op=MPI.SUM))" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "1f45d76e", │ │ │ │ │ │ + "id": "af416002", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Print CG iteration number and error\n", │ │ │ │ │ │ "error_L2_cg1 = L2Norm(u - uD)\n", │ │ │ │ │ │ "if mesh.comm.rank == 0:\n", │ │ │ │ │ │ " print(\"Matrix-free CG solver using DOLFINx vectors:\")\n", │ │ │ ├── ./usr/share/doc/dolfinx-doc/python/_downloads/9ed4657d08dda04de30e6463e2f58d75/demo_mixed-poisson.ipynb.gz │ │ │ │ ├── demo_mixed-poisson.ipynb │ │ │ │ │ ├── Pretty-printed │ │ │ │ │ │┄ Similarity: 0.9856770833333333% │ │ │ │ │ │┄ Differences: {"'cells'": "{0: {'id': '7cab5e6a'}, 1: {'id': '281a6650'}, 2: {'id': '2d5da8d8'}, 3: {'id': " │ │ │ │ │ │┄ "'244025a9'}}"} │ │ │ │ │ │ @@ -1,32 +1,32 @@ │ │ │ │ │ │ { │ │ │ │ │ │ "cells": [ │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "24031cdd", │ │ │ │ │ │ + "id": "7cab5e6a", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "# Mixed formulation for the Poisson equation" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "f6f6c35f", │ │ │ │ │ │ + "id": "281a6650", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "This demo illustrates how to solve Poisson equation using a mixed\n", │ │ │ │ │ │ "(two-field) formulation. In particular, it illustrates how to\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ "* Use mixed and non-continuous finite element spaces.\n", │ │ │ │ │ │ "* Set essential boundary conditions for subspaces and $H(\\mathrm{div})$ spaces.\n" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "markdown", │ │ │ │ │ │ - "id": "fcba1cb2", │ │ │ │ │ │ + "id": "2d5da8d8", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "```{admonition} Download sources\n", │ │ │ │ │ │ ":class: download\n", │ │ │ │ │ │ "\n", │ │ │ │ │ │ "* {download}`Python script <./demo_mixed-poisson.py>`\n", │ │ │ │ │ │ "* {download}`Jupyter notebook <./demo_mixed-poisson.ipynb>`\n", │ │ │ │ │ │ @@ -99,15 +99,15 @@ │ │ │ │ │ │ "\n", │ │ │ │ │ │ "## Implementation" │ │ │ │ │ │ ] │ │ │ │ │ │ }, │ │ │ │ │ │ { │ │ │ │ │ │ "cell_type": "code", │ │ │ │ │ │ "execution_count": null, │ │ │ │ │ │ - "id": "be14b9b8", │ │ │ │ │ │ + "id": "244025a9", │ │ │ │ │ │ "metadata": {}, │ │ │ │ │ │ "outputs": [], │ │ │ │ │ │ "source": [ │ │ │ │ │ │ "\n", │ │ │ │ │ │ "from mpi4py import MPI\n", │ │ │ │ │ │ "from petsc4py import PETSc\n", │ │ │ │ │ │ "\n",