From 92285453f8b3c166f763902d7c232ab74c8dd3cb Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner Date: Thu, 17 Dec 2020 19:01:21 -0600 Subject: [PATCH] Document TracePair --- grudge/eager.py | 3 +++ grudge/symbolic/primitives.py | 19 +++++++++++++++++-- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/grudge/eager.py b/grudge/eager.py index 3bacbc2b..4079cdd0 100644 --- a/grudge/eager.py +++ b/grudge/eager.py @@ -340,6 +340,9 @@ class EagerDGDiscretization(DGDiscretizationWithBoundaries): def interior_trace_pair(discrwb, vec): + """Return a :class:`grudge.sym.TracePair` for the interior faces of + *discrwb*. + """ i = discrwb.project("vol", "int_faces", vec) e = obj_array_vectorize(lambda el: discrwb.opposite_face_connection()(el), i) return TracePair("int_faces", interior=i, exterior=e) diff --git a/grudge/symbolic/primitives.py b/grudge/symbolic/primitives.py index b106de1c..6e57bcf4 100644 --- a/grudge/symbolic/primitives.py +++ b/grudge/symbolic/primitives.py @@ -116,6 +116,14 @@ Geometry data .. autofunction:: surface_normal .. autofunction:: summed_curvature .. autofunction:: mean_curvature + +Trace Pair +^^^^^^^^^^ + +.. autoclass:: TracePair +.. autofunction:: int_tpair +.. autofunction:: bv_tpair +.. autofunction:: bdry_tpair """ @@ -857,13 +865,20 @@ class TracePair: .. attribute:: interior - an expression representing the interior value to + a value (symbolic expression or :class:`~meshmode.dof_array.DOFArray` + or object array of either) representing the interior value to be used for the flux. .. attribute:: exterior - an expression representing the exterior value to + a value (symbolic expression or :class:`~meshmode.dof_array.DOFArray` + or object array of either) representing the exterior value to be used for the flux. + + .. note:: + + :class:`TracePair` is used both by the symbolic and the eager interface, + with symbolic information or concrete data. """ def __init__(self, dd, *, interior, exterior): """ -- GitLab