DESTINATION ${DEAL_II_PYTHON_RELDIR}
COMPONENT python_bindings
)
-
"PYTHONPATH=${CMAKE_BINARY_DIR}/${DEAL_II_PYTHON_RELDIR}/../:$ENV{PYTHONPATH};DEAL_II_PYTHON_TESTPATH=${_test_directory}"
)
ENDFOREACH()
-
process_changed "tests include source examples cmake/scripts contrib/python-bindings doc" \
".*\.(cc|h|cu|cuh|html|dox|txt)" remove_trailing_whitespace
-
#
# Ensure only a single newline at end of files
#
-ensure_single_trailing_newline()
-{
- f=$1
-
- # Remove newlines at end of file
- # Check that the current line only contains newlines
- # If it doesn't match, print it
- # If it does match and we're not at the end of the file,
- # append the next line to the current line and repeat the check
- # If it does match and we're at the end of the file,
- # remove the line.
- sed -e :a -e '/^\n*$/{$d;N;};/\n$/ba' $f >$f.tmpi
-
- # Then add a newline to the end of the file
- # '$' denotes the end of file
- # 'a\' appends the following text (which in this case is nothing)
- # on a new line
- sed -e '$a\' $f.tmpi >$f.tmp
-
- diff -q $f $f.tmp >/dev/null || mv $f.tmp $f
- rm -f $f.tmp $f.tmpi
-}
-export -f ensure_single_trailing_newline
process_changed "tests include source examples cmake/scripts contrib/python-bindings doc" \
".*\.(cc|h|cu|cuh|html|dox|txt)" ensure_single_trailing_newline
process "tests include source examples cmake/scripts contrib/python-bindings doc" \
".*\.(cc|h|cu|cuh|html|dox|txt)" remove_trailing_whitespace
+
+#
+# Ensure only a single newline at end of files
+#
+
+process "tests include source examples cmake/scripts contrib/python-bindings doc" \
+ ".*\.(cc|h|cu|cuh|html|dox|txt)" ensure_single_trailing_newline
+
grep -E "^${2}$" |
${XARGS} '\n' -n 1 -P 10 -I {} bash -c "${3} {}"
}
+
+#
+# Ensure only a single newline at end of files
+#
+ensure_single_trailing_newline()
+{
+ f=$1
+
+ # Remove newlines at end of file
+ # Check that the current line only contains newlines
+ # If it doesn't match, print it
+ # If it does match and we're not at the end of the file,
+ # append the next line to the current line and repeat the check
+ # If it does match and we're at the end of the file,
+ # remove the line.
+ sed -e :a -e '/^\n*$/{$d;N;};/\n$/ba' $f >$f.tmpi
+
+ # Then add a newline to the end of the file
+ # '$' denotes the end of file
+ # 'a\' appends the following text (which in this case is nothing)
+ # on a new line
+ sed -e '$a\' $f.tmpi >$f.tmp
+
+ diff -q $f $f.tmp >/dev/null || mv $f.tmp $f
+ rm -f $f.tmp $f.tmpi
+}
+export -f ensure_single_trailing_newline
ADD_DEPENDENCIES(code-gallery build_code-gallery_h)
ENDIF()
-
* discussed in the first few tutorial programs and are used
* throughout deal.II.
*/
-
* @defgroup Accessors Accessor classes of the mesh iterators
* @ingroup Iterators
*/
-
-
*
* @ingroup feall feaccess
*/
-
ADD_DEPENDENCIES(documentation changelog)
ENDIF(DEAL_II_COMPONENT_DOCUMENTATION)
-
<h3>The testcase</h3>
The problem we solve here is the same as the one in step-12.
-
So much now for all the theoretical and anecdotal background. The best
way of learning about a program is to look at it, so here it is:
-
the code do?), making them consistently better than global
refinement. Behavior is still irregular, though, so no results about
an order of convergence are possible.)
-
the author of the example program, Wolfgang Bangerth, in publications that
arise from that, of your program consists in a considerable part of the
example program.
-
another evaluation and dual functional is simple. You are encouraged
to take the program as a basis for your own experiments, and to play a
little.
-
-
-
-
-
becomes possible to change the actual type to a larger one if necessary without
having to go through the entire library and figure out whether a particular use
of <code>unsigned int</code> corresponds to, say, a material indicator.
-
Finally, on the right vertical wall we impose the condition that the vertical component of the velocity
and the pressure should both be zero.
The final time $T=10$.
-
-
as for the previous one, except that they will now also apply to the 3d
case. For inspiration read up on <a href="step_3.html#extensions"
target="body">possible extensions in the documentation of step 3</a>.
-
The initial and final configurations are shown in the image above.
Using symmetry, we solve for only one quarter of the geometry (i.e. a cube with dimension $0.001$).
The inner-quarter of the upper surface of the domain is subject to a load of $p_0$.
-
-
While this is clearly a suboptimal solution, it works for now and leaves room
for future improvement.
-
Having discussed the general outline of how we want to implement things, let us go
to the program and show how it is done in practice.
-
The pictures confirm that the normal to mesh projection approach leads to grids that remain evenly spaced
throughtout the refinement steps. At the same time, these meshes represent rather well the original geometry even in the bottom region
of the bulb, which is not well recovered employing the directional projector or the normal projector.
-
-
What you will find is that the number of FGMRES iterations stays
constant under refinement if you use GMG this way. This means that the
Multigrid is optimal and independent of $h$.
-
behave differently and FE_DGQ needs 2-5 less iterations than FE_DGQHermite,
despite the modification made to the Hermite-like shape functions to ensure a
good conditioning.
-
The code is set up to work correctly with an adaptively refined mesh (the
interface matrices are created and set). Devise a suitable refinement
criterium or try the KellyErrorEstimator class.
-
-
-
$y$-forces are symmetric with respect to these axes. However, the force
considered as a vector is not symmetric and consequently neither is
the solution.
-
-
COMPONENT library
FILES_MATCHING PATTERN "*.h"
)
-
DEAL_II_NAMESPACE_CLOSE
-#endif
\ No newline at end of file
+#endif
for (const auto &b : boxes)
deallog << "Box: " << Patterns::Tools::to_string(b.get_boundary_points())
<< std::endl;
-}
\ No newline at end of file
+}
}
return 0;
-}
\ No newline at end of file
+}
}
return 0;
-}
\ No newline at end of file
+}
v = random_double_generator.generate();
}
}
-} // namespace FEConforimityTest
\ No newline at end of file
+} // namespace FEConforimityTest
make_dofs();
run_test();
}
-} // namespace FEConforimityTest
\ No newline at end of file
+} // namespace FEConforimityTest
else
deallog << "Not OK" << std::endl;
std::remove("grid.vtu");
-}
\ No newline at end of file
+}
INCLUDE(../setup_testsubproject.cmake)
PROJECT(testsuite CXX)
DEAL_II_PICKUP_TESTS()
-
initlog();
test();
-}
\ No newline at end of file
+}
for (unsigned int l = k; l < dim; ++l)
stream << name << "[" << i << "][" << j << "][" << k << "][" << l
<< "]: " << t[i][j][k][l] << std::endl;
-}
\ No newline at end of file
+}