Skip to content
Snippets Groups Projects
Commit 9b5682ac authored by Thomas Gibson's avatar Thomas Gibson
Browse files

Update normal computation and export functions

parent 5ae2a001
No related branches found
No related tags found
No related merge requests found
......@@ -27,7 +27,9 @@ from grudge.geometry.metrics import (
forward_metric_derivative_mat,
inverse_metric_derivative_mat,
inverse_surface_metric_derivative,
pseudoscalar,
area_element,
surface_normal,
normal
)
......@@ -35,6 +37,8 @@ __all__ = (
"forward_metric_derivative_mat",
"inverse_metric_derivative_mat",
"inverse_surface_metric_derivative",
"pseudoscalar",
"area_element",
"surface_normal",
"normal"
)
......@@ -322,10 +322,14 @@ def mv_normal(actx, dcoll, dd):
from grudge.op import project
import grudge.dof_desc as dof_desc
volm_normal = project(dcoll, dof_desc.DD_VOLUME, dd,
surface_normal(actx, dcoll,
dim=dim + 1,
dd=dof_desc.DD_VOLUME))
volm_normal = MultiVector(
project(dcoll, dof_desc.DD_VOLUME, dd,
surface_normal(
actx, dcoll,
dim=dim + 1,
dd=dof_desc.DD_VOLUME
).as_vector(dtype=object))
)
pder = pseudoscalar(actx, dcoll, dd=dd)
mv = -(volm_normal ^ pder) << volm_normal.I.inv()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment