From 6c9f0d224120e64ae06786b1c1a5d098953eeadb Mon Sep 17 00:00:00 2001 From: Irabiel Romero Date: Thu, 8 Aug 2019 18:13:54 -0400 Subject: [PATCH] add comment for interpolate_boundary_values --- examples/step-4/step-4.cc | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/examples/step-4/step-4.cc b/examples/step-4/step-4.cc index 7cef32e6b3..0ab6776ce1 100644 --- a/examples/step-4/step-4.cc +++ b/examples/step-4/step-4.cc @@ -410,12 +410,20 @@ void Step4::assemble_system() } } - // As the final step in this function, we wanted to have non-homogeneous // boundary values in this example, unlike the one before. This is a simple // task, we only have to replace the Functions::ZeroFunction used there by an // object of the class which describes the boundary values we would like to // use (i.e. the BoundaryValues class declared above): + // + // The function VectorTools::interpolate_boundary_values() will only work + // on faces that have been marked with boundary indicator 0 (because that's + // what we say the function should work on with the second argument below). + // If there are faces with boundary id other than 0, then the function + // interpolate_boundary_values will do nothing on these faces. For + // the Laplace equation doing nothing is equivalent to assuming that + // on those parts of the boundary, zero Neumann + // boundary condition hold. std::map boundary_values; VectorTools::interpolate_boundary_values(dof_handler, 0, -- 2.39.5