Mesh study

The rows of the fixed table are described on the Benchmarks page, with the rule for comparing methods (LUSolver, backend :compiled; "–" marks what a row does not have). The SVG figures are written to the results folder by each script; the ones shown here are copies in docs/src/assets/benchmarks.

The MBB beam of the compliance benchmarks (rmin = 0.06) on 120 × 40, 240 × 80 and 480 × 160, and the cantilever (0, 2) × (0, 1) clamped on x = 0 with a unit traction (0, −1) on x = 2, |y − ½| ≤ 0.1 (plane stress, ν = 0.3, volume fraction 0.5, rmin = 0.048) on 100 × 50, 200 × 100 and 400 × 200, and the heat conduction problem H0 of the heat benchmarks (rmin = 0.04, kmin = 1e-3, volume fraction 0.4) on 100 × 100, 200 × 200 and 400 × 400, with density SiMPL (P0) and the reaction–diffusion level set; τ = 2e-4 (κ = τ|D|: 6e-4 on the MBB, 4e-4 on the cantilever, 2e-4 on the heat problem), Emin = 1e-3, loads and volume the same on every mesh (on 50 × 50 density SiMPL ends the heat problem stalled, so its coarsest mesh is 100 × 100). Every design is read as 0/1 keeping the volume, prolonged exactly to h/4 and evaluated there (mesh_comparison); the short table gives also J_bin on its own mesh, which mixes the change of the design with the discretisation error of the state (they go in opposite directions: on its own mesh the h/2 designs looked within 0.2–0.6 % of h/4). Rule (between h/2 and h/4): J_bin on h/4 within 1 %, the same number of holes of at least π(rmin/2)², iterations within ± 25 %; the run on h/4 is the reference. validation/mesh_study.jl.

problemmethodmeshJJ_bin (own mesh)J_bin on h/4vs h/4 (on h/4)cells changing phase on h/4perimeterholesV_bin (½)iterations
MBBdensity SiMPL, P0120 × 40185.607167.586171.021+2.99 %5.09 %13.0830.505437
MBBdensity SiMPL, P0240 × 80185.212166.186167.398+0.81 %1.88 %14.7440.504443
MBBdensity SiMPL, P0480 × 160185.444166.054166.054+0.00 %0.00 %15.0650.504147
MBBreaction–diffusion level set, Ersatz()120 × 40161.394166.523172.373+6.53 %16.03 %15.4850.497574
MBBreaction–diffusion level set, Ersatz()240 × 80160.35162.42164.202+1.48 %5.76 %17.6870.500867
MBBreaction–diffusion level set, Ersatz()480 × 160160.934161.804161.804+0.00 %0.00 %17.7170.499569
cantilever 2×1density SiMPL, P0100 × 502.704162.443192.48486+3.05 %2.83 %10.5230.503234
cantilever 2×1density SiMPL, P0200 × 1002.686322.42072.43393+0.94 %0.92 %10.5630.501833
cantilever 2×1density SiMPL, P0400 × 2002.681442.411262.41126+0.00 %0.00 %10.5630.501834
cantilever 2×1reaction–diffusion level set, Ersatz()100 × 502.380042.434822.49869+4.31 %6.17 %12.860.498868
cantilever 2×1reaction–diffusion level set, Ersatz()200 × 1002.380442.405292.42601+1.27 %2.37 %12.9860.499064
cantilever 2×1reaction–diffusion level set, Ersatz()400 × 2002.383882.395482.39548+0.00 %0.00 %12.7660.500057
heat H0density SiMPL, P0100 × 1000.1267960.1142270.114806+0.98 %0.84 %4.400.400426
heat H0density SiMPL, P0200 × 2000.1265880.1138860.114088+0.35 %0.42 %4.4200.400426
heat H0density SiMPL, P0400 × 4000.1265510.1136940.113694+0.00 %0.00 %4.41500.400427
heat H0reaction–diffusion level set, Ersatz()100 × 1000.1132320.1141490.114738+1.16 %0.95 %4.7800.399655
heat H0reaction–diffusion level set, Ersatz()200 × 2000.1132440.1136520.11386+0.38 %0.44 %4.7900.399857
heat H0reaction–diffusion level set, Ersatz()400 × 4000.1132170.1134270.113427+0.00 %0.00 %4.7900.400059
  • MBB, density SiMPL, P0: h/2 against h/4 on h/4: J_bin +0.81 % (≤ 1 %: yes), holes 4 / 5 (same: no), iterations 43 / 47, -8.5 % (± 25 %: yes), 1.88 % cells change: rule not met (as documented)
  • MBB, reaction–diffusion level set, Ersatz(): h/2 against h/4 on h/4: J_bin +1.48 % (≤ 1 %: no), holes 7 / 7 (same: yes), iterations 67 / 69, -2.9 % (± 25 %: yes), 5.76 % cells change: rule not met (as documented)
  • cantilever 2×1, density SiMPL, P0: h/2 against h/4 on h/4: J_bin +0.94 % (≤ 1 %: yes), holes 3 / 3 (same: yes), iterations 33 / 34, -2.9 % (± 25 %: yes), 0.92 % cells change: rule met (as documented)
  • cantilever 2×1, reaction–diffusion level set, Ersatz(): h/2 against h/4 on h/4: J_bin +1.27 % (≤ 1 %: no), holes 6 / 6 (same: yes), iterations 64 / 57, +12.3 % (± 25 %: yes), 2.37 % cells change: rule not met (as documented)
  • heat H0, density SiMPL, P0: h/2 against h/4 on h/4: J_bin +0.35 % (≤ 1 %: yes), holes 0 / 0 (same: yes), iterations 26 / 27, -3.7 % (± 25 %: yes), 0.42 % cells change: rule met (as documented)
  • heat H0, reaction–diffusion level set, Ersatz(): h/2 against h/4 on h/4: J_bin +0.38 % (≤ 1 %: yes), holes 0 / 0 (same: yes), iterations 57 / 59, -3.4 % (± 25 %: yes), 0.44 % cells change: rule met (as documented)

MBB beam: rows, methods; columns, h, h/2 and h/4 (the reference)

Cantilever: rows, methods; columns, h, h/2 and h/4 (the reference)

Heat H0: rows, methods; columns, h, h/2 and h/4 (the reference)

On the common mesh h/4 the rule is met by density SiMPL on the cantilever only (J_bin +0.94 %, the same 3 holes, 0.9 % of the cells change). On the MBB beam density SiMPL meets the 1 % (+0.81 %) but not the holes: a small hole under the load is below π(rmin/2)² on h/2 and above it on h/4 (4 against 5). The reaction–diffusion level set does not meet the 1 %: +1.48 % on the MBB beam and +1.27 % on the cantilever, with 5.8 % and 2.4 % of the cells changing phase between h/2 and h/4: with a fixed τ its members keep moving under refinement (on h, +6.5 % and +4.3 %). These outcomes are results of the study, recorded in the script, which fails only if one of them changes. The heat problem H0 is the first of the bank where both methods meet the rule: J_bin +0.35 % (density SiMPL) and +0.38 % (the level set) between h/2 and h/4, 0.4 % of the cells changing phase, no holes on any mesh: one concentrated heat input and two thick arms, no member that the mesh keeps refining. Evaluated on their own meshes, as in the first version of this study, the same designs looked within 0.2–0.6 % of h/4: the discretisation error of the state, of the opposite sign, hid most of the difference.

The outcome of the level set against the 1 % depends on the family of meshes: nested families give +1.2–1.5 % between h/2 and h/4 (+1.48 % here, +1.23 % on the Delaunay triangles of Gmsh refined uniformly of the unstructured meshes), meshes of Gmsh generated anew at each size +0.90 % (a probe made when designing the unstructured example, 2026-11-29, Apple M5 Max, 4 threads, Julia 1.13): the 1 % lies within the spread between meshes.

The fixed report table (J_bin on the own mesh; vs ref against the design on h/4 on its mesh):

Apple M5 Max, 4 threads, Julia 1.13.0 · commit 3b98442 · 2026-11-30 17:17.

casevariantJJ_binrefvs refVV_bingreyperimeterholesiterationssolves state/adjoint/filter/steptime (s)time ÷ state solves (s)
MBB 120×40density SiMPL, P0185.607167.586166.054+0.92 % (J_bin)0.50000.50000.20613.08337 (converged, objective_range)42/0/79/01.10.0255
MBB 240×80density SiMPL, P0185.212166.186166.054+0.08 % (J_bin)0.50000.50000.20714.74443 (converged, objective_range)48/0/91/04.40.0927
MBB 480×160density SiMPL, P0 (h/4: reference)185.444166.054166.054+0.00 % (J_bin)0.50000.50000.20615.06547 (converged, objective_range)57/0/104/021.60.378
MBB 120×40reaction–diffusion level set, Ersatz()161.394166.523161.804+2.92 % (J_bin)0.50000.50000.07015.48574 (converged, all)75/0/0/742.20.0295
MBB 240×80reaction–diffusion level set, Ersatz()160.35162.42161.804+0.38 % (J_bin)0.50000.50000.04017.68767 (converged, all)68/0/0/677.40.108
MBB 480×160reaction–diffusion level set, Ersatz() (h/4: reference)160.934161.804161.804+0.00 % (J_bin)0.50000.50000.02017.71769 (converged, all)70/0/0/6930.80.441
cantilever 2×1 100×50density SiMPL, P02.704162.443192.41126+1.32 % (J_bin)0.50000.50000.18510.52334 (converged, objective_range)37/0/71/01.00.0267
cantilever 2×1 200×100density SiMPL, P02.686322.42072.41126+0.39 % (J_bin)0.50000.50000.17310.56333 (converged, objective_range)36/0/69/03.20.0896
cantilever 2×1 400×200density SiMPL, P0 (h/4: reference)2.681442.411262.41126+0.00 % (J_bin)0.50000.50000.17010.56334 (converged, objective_range)37/0/71/014.40.389
cantilever 2×1 100×50reaction–diffusion level set, Ersatz()2.380042.434822.39548+1.64 % (J_bin)0.50000.50000.06712.8668 (converged, all)69/0/0/682.00.029
cantilever 2×1 200×100reaction–diffusion level set, Ersatz()2.380442.405292.39548+0.41 % (J_bin)0.49990.50000.03312.98664 (converged, all)65/0/0/647.20.111
cantilever 2×1 400×200reaction–diffusion level set, Ersatz() (h/4: reference)2.383882.395482.39548+0.00 % (J_bin)0.49990.50000.01612.76657 (converged, all)58/0/0/5727.00.465
heat H0 100×100density SiMPL, P00.1267960.1142270.113694+0.47 % (J_bin)0.40000.40000.1274.4026 (converged, objective_range)30/0/56/00.70.024
heat H0 200×200density SiMPL, P00.1265880.1138860.113694+0.17 % (J_bin)0.40000.40000.1244.42026 (converged, objective_range)28/0/54/02.40.0843
heat H0 400×400density SiMPL, P0 (h/4: reference)0.1265510.1136940.113694+0.00 % (J_bin)0.40000.40000.1224.415027 (converged, objective_range)28/0/55/08.30.296
heat H0 100×100reaction–diffusion level set, Ersatz()0.1132320.1141490.113427+0.64 % (J_bin)0.40000.40000.0264.78055 (converged, all)56/0/0/551.30.0234
heat H0 200×200reaction–diffusion level set, Ersatz()0.1132440.1136520.113427+0.20 % (J_bin)0.39990.40000.0134.79057 (converged, all)58/0/0/575.50.0947
heat H0 400×400reaction–diffusion level set, Ersatz() (h/4: reference)0.1132170.1134270.113427+0.00 % (J_bin)0.40000.40000.0064.79059 (converged, all)60/0/0/5921.90.365