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 fromis_boundary(gen_circle: 7/53 at order 1, 16/106 at order 2) and their Dirichlet condition was silently dropped.mesh.boundary_masknow falls back to the topological mask on imported meshes; per-side masks are tolerance predicates restricted to the boundary; the hollow generators exposeis_inner_boundary/is_outer_boundary. (#58) gen_hollow_rectangle/gen_hollow_circlealways raisedUnknown model face(stale OCC tags afterocc.cut);gen_hollow_cubereturned a stale cached mesh;gen_sphere(order=2)was never reordered. (#58)- Loading an order ≥ 2 Gmsh/VTK mesh without
reorder=Truenow raisesValueError(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.pypins that. (#58) BufferDictsupportsinand iteration over keys. (#58)layout_signaturestays stable across vector reassembly, so oneCondensercan 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
.vtuwritten bymesh.saveis a VTK-ordered file: read it back withreorder=True. - Per-side generator masks are intersected with the boundary; an interior node that happened to sit on
x == inner_leftis no longer flagged.
Full changelog: v0.2.0...v0.2.1