diff --git a/python/demo/demo_helmholtz.py b/python/demo/demo_helmholtz.py index 225f7c8ae31..edc27355912 100644 --- a/python/demo/demo_helmholtz.py +++ b/python/demo/demo_helmholtz.py @@ -42,7 +42,6 @@ n_elem = 128 msh = create_unit_square(MPI.COMM_WORLD, n_elem, n_elem) -n = ufl.FacetNormal(msh) # Source amplitude if np.issubdtype(PETSc.ScalarType, np.complexfloating): # type: ignore diff --git a/python/demo/demo_scattering_boundary_conditions/demo_scattering_boundary_conditions.py b/python/demo/demo_scattering_boundary_conditions/demo_scattering_boundary_conditions.py index bd54d6fdd23..d75655db4c0 100644 --- a/python/demo/demo_scattering_boundary_conditions/demo_scattering_boundary_conditions.py +++ b/python/demo/demo_scattering_boundary_conditions/demo_scattering_boundary_conditions.py @@ -371,7 +371,9 @@ def curl_2d(f: fem.Function): # # Cancelling $-(\nabla\times\mathbf{E}_s \times \bar{\mathbf{V}}) # \cdot\mathbf{n}$ and $\mathbf{n} \times \nabla \times \mathbf{E}_s -# \cdot \bar{\mathbf{V}}$ using the triple product rule $\mathbf{A} +# \cdot \bar{\mathbf{V}}$ and rearrange $\left((\mathbf{n} \times \mathbf{E}_s) +# \times \mathbf{n}\right) \cdot \bar{\mathbf{v}}$ to $ (\mathbf{E}_s \times\mathbf{n}) +# \cdot (\bar{\mathbf{v}} \times \mathbf{n})$ using the triple product rule $\mathbf{A} # \cdot(\mathbf{B} \times \mathbf{C})=\mathbf{B} \cdot(\mathbf{C} \times # \mathbf{A})=\mathbf{C} \cdot(\mathbf{A} \times \mathbf{B})$, we get: #