Skip to content

2026.09.28 v0.2.1

Latest

Choose a tag to compare

@Shizheng-Wen Shizheng-Wen released this 28 Sep 18:44
e1f5e5c

TensorMesh 0.2.1 is a correctness release: two silent discretisation bugs surfaced by a downstream Stokes pipeline are fixed, the hollow-domain generators work again, and every example now ships as a Colab notebook.

Fixes

  • Boundary masks are detected topologically (Mesh.topological_boundary_mask()). Nodes that gmsh places one ulp off a curved boundary were missing from is_boundary (gen_circle: 7/53 at order 1, 16/106 at order 2) and their Dirichlet condition was silently dropped. mesh.boundary_mask now falls back to the topological mask on imported meshes; per-side masks are tolerance predicates restricted to the boundary; the hollow generators expose is_inner_boundary / is_outer_boundary. (#58)
  • gen_hollow_rectangle / gen_hollow_circle always raised Unknown model face (stale OCC tags after occ.cut); gen_hollow_cube returned a stale cached mesh; gen_sphere(order=2) was never reordered. (#58)
  • Loading an order ≥ 2 Gmsh/VTK mesh without reorder=True now raises ValueError (Mesh.check_node_ordering, run by the constructor) instead of silently assembling a wrong geometry map. The constant pressure mode of a Taylor–Hood form is in the kernel to 4e-15 once mesh and mask are right; tests/assemble/test_taylor_hood_kernel.py pins that. (#58)
  • BufferDict supports in and iteration over keys. (#58)
  • layout_signature stays stable across vector reassembly, so one Condenser can be reused across time steps / Picard iterations. (#51)

Notebooks

Fifteen Colab notebooks covering the gallery — basics, Poisson (2D / 3D / h-adaptive), Helmholtz, Taylor-Hood Stokes, lid-driven cavity, flow past obstacles, inverse design, physics-informed training, cantilever and hyperelastic beams, heat, wave, Allen–Cahn — linked from the README and the docs. (#52–#55)

Migration notes

  • A .vtu written by mesh.save is a VTK-ordered file: read it back with reorder=True.
  • Per-side generator masks are intersected with the boundary; an interior node that happened to sit on x == inner_left is no longer flagged.

Full changelog: v0.2.0...v0.2.1