Here’s an update that works also with open meshes
HeatMethod_Boundary.gh (88.4 KB)
As it is it gives you this, which seems to be the best match for geodesic distances:
If you look in the code there are also a couple of bools you can switch to get some different non geodesic results
If you don’t fix the boundary during the first step, the gradient ends up tangent at the boundary.
(so setting fixBoundary = false
and keepFixed = false
)
whereas if you keep the boundary values fixed also during the Poisson step, you get the gradient perpendicular to the boundary:
(so setting
fixBoundary = true
and keepFixed = true
)