using .Other(bnd=...) with grad

Hello,

I’m using discontinuous Galerkin to solve a Poisson equation. I use .Other() when defining my jump and average operators, and I would like to use the bnd parameter to set a value for when .Other() is evaluated on exterior facets.

Defining my jump operators as

u_jump = n*(u - u.Other(bnd=0))

works perfectly.

However, my average operators involve grad and

grad_u_avg = 0.5*(grad(u) - grad(u.Other(bnd=u)))

doesn’t evaluate correctly on exterior facets.

Am I using .Other(bnd=…) incorrectly? I’ve attached a script with a working DG formulation where I modify the jump and average operators on the exterior facets and a broken formulation where I attempt to use the bnd parameter.
https://ngsolve.org/media/kunena/attachments/1344/test.py

Attachment: test_2020-10-28.py