explicit calculations for triSurface fields
The triSurface fields are a slightly dodgy construct, they use triSurface for mesh sizes/relationship but the fields cannot be registered on triSurface. Instead, some other source of objectRegistry is used (in some cases this is whatever the IOobject provides).
As a result, the relationship field.mesh().thisDb()
does not work.
In places using triSurface fields, they should be expanded out (ie, expressed as calculations of the primitive fields) to ensure that none of the mesh().thisDb()
code is used.