You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: examples/ceed/index.rst
+7-27Lines changed: 7 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -50,37 +50,17 @@ Similarly to :ref:`Ex1-Volume`, it computes:
50
50
I = \int_{\partial\Omega} \mathbf{1} \, dS .
51
51
:label: eq-ex2-surface
52
52
53
-
but this time by solving a Laplace's equation for a harmonic function
54
-
:math:`u(\mathbf{x})`. We write the Laplace's equation
53
+
but this time by applying the divergence theorem using a Laplacian.
54
+
In particular, we select :math:`u(\bm x) = x_0 + x_1 + x_2`, for which :math:`\nabla u = [1, 1, 1]^T`, and thus :math:`\nabla u \cdot\hat{\bm n} = 1`.
55
55
56
-
.. math::
57
-
\nabla\cdot\nabla u = 0, \textrm{ for } \mathbf{x} \in\Omega .
58
-
:label: eq-laplace
59
-
60
-
We can rewrite this via the bilinear form :math:`a(\cdot, \cdot)` and the linear form
61
-
:math:`\langle\cdot, \cdot\rangle` as
56
+
Given Laplace's equation,
62
57
63
58
.. math::
64
-
a(u,v) = \langle, v,f \rangle
59
+
-\nabla\cdot\nabla u = 0, \textrm{ for } \mathbf{x} \in\Omega
65
60
66
-
where :math:`v` is the test function, and for which :math:`\langle, v,f \rangle=0` in
67
-
this case. We
68
-
obtain
61
+
multiply by a test function :math:`v` and integrate by parts to obtain
69
62
70
63
.. math::
71
-
a(u,v) = \int_\Omega v \nabla\cdot\nabla u \, dV = \int_{\partial\Omega} v \nabla u \cdot\mathbf{n}\, dS - \int_\Omega\nabla v \cdot\nabla u \, dV = 0 ,
72
-
73
-
where we have used integration by parts.
64
+
\int_\Omega\nabla v \cdot\nabla u \, dV - \int_{\partial\Omega} v \nabla u \cdot\hat{\bm n}\, dS = 0 .
74
65
75
-
:math:`a(u,v) = 0` because we have chosen :math:`u(\mathbf{x})` to be harmonic, so we
76
-
can write
77
-
78
-
.. math::
79
-
\int_{\partial\Omega} v \nabla u \cdot\mathbf{n}\, dS = \int_\Omega\nabla v \cdot\nabla u \, dV
80
-
:label: eq-laplace-by-parts
81
-
82
-
and use the :ref:`CeedOperator` for Laplace's operator to compute the right-hand side of
83
-
equation :math:numref:`eq-laplace-by-parts`. This way, the left-hand side of equation
84
-
:math:numref:`eq-laplace-by-parts` (which gives :math:numref:`eq-ex2-surface` because
85
-
we have chosen :math:`u(\mathbf{x}) = (x + y + z)` such that
86
-
:math:`\nabla u \cdot\mathbf{n} = 1`) is readily found.
66
+
Since we have chosen :math:`u` such that the boundary integrand is :math:`v 1`, we may evaluate the surface integral by applying the volumetric Laplacian and summing the result.
0 commit comments