From e624850e18b22247b4d46d02c36e1994849c0acf Mon Sep 17 00:00:00 2001 From: Oliver Sander <oliver.sander@tu-dresden.de> Date: Sun, 8 Jan 2023 07:40:08 +0100 Subject: [PATCH] Add CI pipeline running the codespell tool And fix all spelling errors that codespell currently finds. --- .gitlab-ci.yml | 11 +++++++++++ CHANGELOG.md | 2 +- cmake/modules/FindARPACK.cmake | 6 +++--- cmake/modules/FindARPACKPP.cmake | 6 +++--- doc/istl.tex | 2 +- dune/istl/basearray.hh | 4 ++-- dune/istl/bcrsmatrix.hh | 4 ++-- dune/istl/common/registry.hh | 4 ++-- dune/istl/eigenvalue/arpackpp.hh | 8 ++++---- dune/istl/ildl.hh | 2 +- dune/istl/ilusubdomainsolver.hh | 2 +- dune/istl/io.hh | 10 +++++----- dune/istl/matrixmatrix.hh | 2 +- dune/istl/multitypeblockmatrix.hh | 2 +- dune/istl/multitypeblockvector.hh | 2 +- dune/istl/novlpschwarz.hh | 4 ++-- dune/istl/overlappingschwarz.hh | 4 ++-- dune/istl/owneroverlapcopy.hh | 2 +- dune/istl/paamg/aggregates.hh | 16 ++++++++-------- dune/istl/paamg/amg.hh | 8 ++++---- dune/istl/paamg/dependency.hh | 20 ++++++++++---------- dune/istl/paamg/fastamg.hh | 6 +++--- dune/istl/paamg/graph.hh | 2 +- dune/istl/paamg/indicescoarsener.hh | 2 +- dune/istl/paamg/kamg.hh | 2 +- dune/istl/paamg/matrixhierarchy.hh | 4 ++-- dune/istl/paamg/smoother.hh | 2 +- dune/istl/paamg/test/anisotropic.hh | 4 ++-- dune/istl/paamg/test/fastamg.cc | 4 ++-- dune/istl/paamg/twolevelmethod.hh | 2 +- dune/istl/preconditioner.hh | 2 +- dune/istl/preconditioners.hh | 2 +- dune/istl/repartition.hh | 18 +++++++++--------- dune/istl/scalarproducts.hh | 2 +- dune/istl/schwarz.hh | 2 +- dune/istl/solvers.hh | 2 +- dune/istl/test/complexrhstest.cc | 2 +- dune/istl/test/vbvectortest.cc | 2 +- dune/istl/vbvector.hh | 2 +- dune/python/istl/bvector.hh | 6 +++--- 40 files changed, 100 insertions(+), 89 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 4b7d68699..43ae0e7fc 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -49,6 +49,17 @@ ubuntu:18.04 clang-5-17: DUNECI_CMAKE_FLAGS: "-DDUNE_ENABLE_PYTHONBINDINGS=OFF" tags: [duneci] +# Check for spelling mistakes in text +code-spelling-check: + stage: .pre + # Avoid the global 'before_script' + before_script: "" + image: registry.dune-project.org/docker/ci/debian:11 + tags: [duneci] + script: + - codespell + --ignore-words-list eiter,equil,fo,parms + reuse: stage: .pre image: diff --git a/CHANGELOG.md b/CHANGELOG.md index c82dc1e26..03e3c8487 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -210,4 +210,4 @@ SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception - The solver infrastructure was updated to support SIMD data types (see current changes in `dune-common`). This allows to solve multiple systems - simultaniously using vectorization. + simultaneously using vectorization. diff --git a/cmake/modules/FindARPACK.cmake b/cmake/modules/FindARPACK.cmake index e50a2d094..5986749ad 100644 --- a/cmake/modules/FindARPACK.cmake +++ b/cmake/modules/FindARPACK.cmake @@ -71,14 +71,14 @@ if(ARPACK_FOUND) set(ARPACK_LIBRARIES ${ARPACK_LIBRARY}) # log result file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log - "Determing location of ARPACK succeeded:\n" + "Determining location of ARPACK succeeded:\n" "Libraries to link against: ${ARPACK_LIBRARIES}\n\n") set(ARPACK_DUNE_LIBRARIES ${ARPACK_LIBRARIES} CACHE STRING "Libraries used by DUNE when linking ARPACK programs") else() - # log errornous result + # log erroneous result file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log - "Determing location of ARPACK failed:\n" + "Determining location of ARPACK failed:\n" "Libraries to link against: ${ARPACK_LIBRARIES}\n\n") endif() diff --git a/cmake/modules/FindARPACKPP.cmake b/cmake/modules/FindARPACKPP.cmake index 1b6f89602..d920d6eea 100644 --- a/cmake/modules/FindARPACKPP.cmake +++ b/cmake/modules/FindARPACKPP.cmake @@ -100,7 +100,7 @@ if(ARPACKPP_FOUND) endif(ARPACKPP_LIBRARY) # log result file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log - "Determing location of ARPACK++ succeeded:\n" + "Determining location of ARPACK++ succeeded:\n" "Include directory: ${ARPACKPP_INCLUDE_DIRS}\n" "Libraries to link against: ${ARPACKPP_LIBRARIES}\n\n") @@ -116,9 +116,9 @@ if(ARPACKPP_FOUND) set(ARPACKPP_DUNE_LIBRARIES ${ARPACKPP_LIBRARIES} CACHE STRING "Libraries used by DUNE when linking ARPACK++ programs") else() - # log errornous result + # log erroneous result file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log - "Determing location of ARPACK++ failed:\n" + "Determining location of ARPACK++ failed:\n" "Include directory: ${ARPACKPP_INCLUDE_DIRS}\n" "Libraries to link against: ${ARPACKPP_LIBRARIES}\n\n") endif() diff --git a/doc/istl.tex b/doc/istl.tex index 8f3b9ba1f..1407455d5 100644 --- a/doc/istl.tex +++ b/doc/istl.tex @@ -649,7 +649,7 @@ contains the computed update to the current guess, i.~e. $\vec v = M^{-1} \vec d$ where $M$ is the approximate inverse of the operator $A$ characterizing the preconditioner. The method \lstinline!void post(X& x)! -should be called after all computations to give the precondtioner the +should be called after all computations to give the preconditioner the chance to clean allocated resources. See Table \ref{tab:precond} for a list of available diff --git a/dune/istl/basearray.hh b/dune/istl/basearray.hh index 180bd82fa..1e1f86f5b 100644 --- a/dune/istl/basearray.hh +++ b/dune/istl/basearray.hh @@ -32,7 +32,7 @@ namespace Imp { - random access This container has *NO* memory management at all, - copy constuctor, assignment and destructor are all default. + copy constructor, assignment and destructor are all default. The constructor is made protected to emphasize that objects are only usable in derived classes. @@ -291,7 +291,7 @@ namespace Imp { - find returning iterator This container has *NO* memory management at all, - copy constuctor, assignment and destructor are all default. + copy constructor, assignment and destructor are all default. The constructor is made protected to emphasize that objects are only usably in derived classes. diff --git a/dune/istl/bcrsmatrix.hh b/dune/istl/bcrsmatrix.hh index b84dd833e..c7943726c 100644 --- a/dune/istl/bcrsmatrix.hh +++ b/dune/istl/bcrsmatrix.hh @@ -408,8 +408,8 @@ namespace Dune { The compress() method returns a value of type Dune::CompressionStatistics, which you can inspect to tune the construction parameters `_avg` and `compressionBufferSize`. - Use of copy constructor, assignment operator and matrix vector arithmetics - are not supported until the matrix is fully built. + Use of copy constructor, assignment operator and matrix vector arithmetic + is not supported until the matrix is fully built. The following sample code constructs a \f$ 10 \times 10\f$ matrix, with an expected number of two entries per matrix row. The compression buffer size is set to 0.4. diff --git a/dune/istl/common/registry.hh b/dune/istl/common/registry.hh index 43c379c46..33ddee83d 100644 --- a/dune/istl/common/registry.hh +++ b/dune/istl/common/registry.hh @@ -54,7 +54,7 @@ namespace Dune { /* Register all creators from the registry in the Parameterizedobjectfactory An - object of V is passed in the creator ans should be used to determine the + object of V is passed in the creator and should be used to determine the template arguments. */ template<class V, class Type, class Tag, class... Args> @@ -65,7 +65,7 @@ namespace Dune { [&](auto index) { // we first get the generic lambda // and later specialize it with given parameters. - // doing all at once lead to an ICE woth g++-6 + // doing all at once leads to an ICE with g++-6 using Reg = Registry<Tag, index>; auto genericcreator = Reg::getCreator(); factory.define(Reg::name(), [genericcreator](Args... args){ diff --git a/dune/istl/eigenvalue/arpackpp.hh b/dune/istl/eigenvalue/arpackpp.hh index 1f085d782..81f7ab861 100644 --- a/dune/istl/eigenvalue/arpackpp.hh +++ b/dune/istl/eigenvalue/arpackpp.hh @@ -596,12 +596,12 @@ namespace Dune /** * \brief Assume the matrix to be nonsymmetric and perform IRLM * to compute an approximation sigma of its largest - * singlar value and the corresponding approximation x of + * singular value and the corresponding approximation x of * an associated singular vector. * * \param[in] epsilon The target relative accuracy of Ritz values * (0 == machine precision). - * \param[out] sigma The approximated largest singlar value. + * \param[out] sigma The approximated largest singular value. * \param[out] x The associated approximated right-singular * vector (if #rows >= #ncols) respectively * left-singular vector (if #rows < #ncols). @@ -708,12 +708,12 @@ namespace Dune /** * \brief Assume the matrix to be nonsymmetric and perform IRLM * to compute an approximation sigma of its smallest - * singlar value and the corresponding approximation x of + * singular value and the corresponding approximation x of * an associated singular vector. * * \param[in] epsilon The target relative accuracy of Ritz values * (0 == machine precision). - * \param[out] sigma The approximated smallest singlar value. + * \param[out] sigma The approximated smallest singular value. * \param[out] x The associated approximated right-singular * vector (if #rows >= #ncols) respectively * left-singular vector (if #rows < #ncols). diff --git a/dune/istl/ildl.hh b/dune/istl/ildl.hh index 9f595854a..169a96c2d 100644 --- a/dune/istl/ildl.hh +++ b/dune/istl/ildl.hh @@ -79,7 +79,7 @@ namespace Dune * \brief compute ILDL decomposition of a symmetric matrix A * \author Martin Nolte * - * \param[inout] A matrix to decompose + * \param[in,out] A Matrix to decompose * * \note A is overwritten by the factorization. * \note Only the lower half of A is used. diff --git a/dune/istl/ilusubdomainsolver.hh b/dune/istl/ilusubdomainsolver.hh index 8d8436c36..1ea13df20 100644 --- a/dune/istl/ilusubdomainsolver.hh +++ b/dune/istl/ilusubdomainsolver.hh @@ -151,7 +151,7 @@ namespace Dune { std::size_t ILUSubdomainSolver<M,X,Y>::copyToLocalMatrix(const M& A, S& rowSet) { // Calculate consecutive indices for local problem - // while perserving the ordering + // while preserving the ordering typedef typename M::size_type size_type; typedef std::map<typename S::value_type,size_type> IndexMap; typedef typename IndexMap::iterator IMIter; diff --git a/dune/istl/io.hh b/dune/istl/io.hh index 559a7f206..f0f22c034 100644 --- a/dune/istl/io.hh +++ b/dune/istl/io.hh @@ -605,7 +605,7 @@ namespace Dune { if (col_offsets[col + 1] == null_offset) // write it in the offset vector col_offsets[col + 1] = sub_size.first; - // repeat proces for row sizes + // repeat process for row sizes if (row_offsets[row + 1] == null_offset) row_offsets[row + 1] = sub_size.second; }); @@ -703,7 +703,7 @@ namespace Dune { * @code{.cc} * opts.color_fill = [max,min](const double& val){ * auto percentage = (val-min)/(max-min)*100; - * return "hsl(348, " + std::to_string(precentage) + "%, 41%)";}; + * return "hsl(348, " + std::to_string(percentage) + "%, 41%)";}; * }; * @endcode */ @@ -752,7 +752,7 @@ namespace Dune { * case of overlaps in the SVG objects, the more nested blocks take * precedence. * @warning If the SVG bounding box is not respected, the content may be - * ommited in the final SVG view. + * omitted in the final SVG view. * @note This function signature is required for any custom options class. * * @tparam Stream An ostream type (possibly a NullStream!) @@ -795,7 +795,7 @@ namespace Dune { * bounding box. This is enough to visualize patterns. If you need a * more advance SVG object in each matrix block (e.g. color scale, or * write the value in text), just provide a custom SVGOptions that - * fullfils the DefaultSVGMatrixOptions interface. + * fulfills the DefaultSVGMatrixOptions interface. * * @tparam Mat Matrix type to write * @tparam SVGOptions Options object type (see DefaultSVGMatrixOptions) @@ -806,7 +806,7 @@ namespace Dune { template <class Mat, class SVGOptions = DefaultSVGMatrixOptions> void writeSVGMatrix(const Mat &mat, std::ostream &out, SVGOptions opts = {}) { - // We need a vector that can fit all the multi-indices for rows and colums + // We need a vector that can fit all the multi-indices for rows and columns using IndexPrefix = Dune::ReservedVector<std::size_t, blockLevel<Mat>()>; // Call overload for Mat type Impl::writeSVGMatrix(mat, out, opts, IndexPrefix{}, IndexPrefix{}); diff --git a/dune/istl/matrixmatrix.hh b/dune/istl/matrixmatrix.hh index 526e22529..19ac9e1d3 100644 --- a/dune/istl/matrixmatrix.hh +++ b/dune/istl/matrixmatrix.hh @@ -117,7 +117,7 @@ namespace Dune // as the mcol iterator for(row_iterator_t mtcol=matt.begin(); mtcol != matt.end(); ++mtcol) { - //Search for col entries in mat that have a corrsponding row index in matt + //Search for col entries in mat that have a corresponding row index in matt // (i.e. corresponding col index in the as this is the transposed matrix col_iterator_t mtrow=mtcol->begin(); bool funcCalled = false; diff --git a/dune/istl/multitypeblockmatrix.hh b/dune/istl/multitypeblockmatrix.hh index e15ab1470..0a856b439 100644 --- a/dune/istl/multitypeblockmatrix.hh +++ b/dune/istl/multitypeblockmatrix.hh @@ -74,7 +74,7 @@ namespace Dune { /** \brief Random-access operator * - * This method mimicks the behavior of normal vector access with square brackets like, e.g., m[5] = .... + * This method mimics the behavior of normal vector access with square brackets like, e.g., m[5] = .... * The problem is that the return type is different for each value of the argument in the brackets. * Therefore we implement a trick using std::integral_constant. To access the first row of * a MultiTypeBlockMatrix named m write diff --git a/dune/istl/multitypeblockvector.hh b/dune/istl/multitypeblockvector.hh index e512fcb3f..a22b06561 100644 --- a/dune/istl/multitypeblockvector.hh +++ b/dune/istl/multitypeblockvector.hh @@ -116,7 +116,7 @@ namespace Dune { /** \brief Random-access operator * - * This method mimicks the behavior of normal vector access with square brackets like, e.g., v[5] = 1. + * This method mimics the behavior of normal vector access with square brackets like, e.g., v[5] = 1. * The problem is that the return type is different for each value of the argument in the brackets. * Therefore we implement a trick using std::integral_constant. To access the first entry of * a MultiTypeBlockVector named v write diff --git a/dune/istl/novlpschwarz.hh b/dune/istl/novlpschwarz.hh index 1e5a2714b..a0c74f8af 100644 --- a/dune/istl/novlpschwarz.hh +++ b/dune/istl/novlpschwarz.hh @@ -265,8 +265,8 @@ namespace Dune { /** * @brief Nonoverlapping parallel preconditioner. * - * This is essentially a wrapper that take a sequential - * preconditoner. In each step the sequential preconditioner + * This is essentially a wrapper that takes a sequential + * preconditioner. In each step the sequential preconditioner * is applied and then all owner data points are updated on * all other processes. */ diff --git a/dune/istl/overlappingschwarz.hh b/dune/istl/overlappingschwarz.hh index fc45abe68..ce4f615f0 100644 --- a/dune/istl/overlappingschwarz.hh +++ b/dune/istl/overlappingschwarz.hh @@ -847,7 +847,7 @@ namespace Dune {} /*! - \brief Apply the precondtioner + \brief Apply the preconditioner \copydoc Preconditioner::apply(X&,const Y&) */ @@ -1209,7 +1209,7 @@ namespace Dune for(DomainIterator domain=subDomains.begin(); domain!=subDomains.end(); ++domain) maxlength=std::max(maxlength, domain->size()); }else{ - // initialize the solvers of the local prolems. + // initialize the solvers of the local problems. SolverIterator solver=solvers.begin(); for(DomainIterator domain=subDomains.begin(); domain!=subDomains.end(); ++domain, ++solver) { diff --git a/dune/istl/owneroverlapcopy.hh b/dune/istl/owneroverlapcopy.hh index 7ba01230e..8cebc0e8b 100644 --- a/dune/istl/owneroverlapcopy.hh +++ b/dune/istl/owneroverlapcopy.hh @@ -198,7 +198,7 @@ namespace Dune { protected: - /** \brief gather/scatter callback for communcation */ + /** \brief gather/scatter callback for communication */ template<typename T> struct CopyGatherScatter { diff --git a/dune/istl/paamg/aggregates.hh b/dune/istl/paamg/aggregates.hh index f7a855889..a71a29e18 100644 --- a/dune/istl/paamg/aggregates.hh +++ b/dune/istl/paamg/aggregates.hh @@ -746,7 +746,7 @@ namespace Dune private: /** @brief Prevent copying. */ AggregatesMap(const AggregatesMap<V>&) = delete; - /** @brief Prevent assingment. */ + /** @brief Prevent assignment. */ AggregatesMap<V>& operator=(const AggregatesMap<V>&) = delete; /** @@ -827,7 +827,7 @@ namespace Dune /** * @brief Reconstruct the aggregat from an seed node. * - * Will determine all vertices of the same agggregate + * Will determine all vertices of the same aggregate * and reference those. */ void reconstruct(const Vertex& vertex); @@ -853,7 +853,7 @@ namespace Dune */ typename VertexSet::size_type size(); /** - * @brief Get tne number of connections to other aggregates. + * @brief Get the number of connections to other aggregates. */ typename VertexSet::size_type connectSize(); @@ -1244,7 +1244,7 @@ namespace Dune /** * @brief Counts the edges depending on the dependency. * - * If the inluence flag of the edge is set the counter is + * If the influence flag of the edge is set the counter is * increased and/or if the depends flag is set it is * incremented, too. */ @@ -1294,7 +1294,7 @@ namespace Dune * @brief counts the dependency between a vertex and unaggregated * neighbours. * - * If the inluence flag of the edge is set the counter is + * If the influence flag of the edge is set the counter is * increased and/or if the depends flag is set it is * incremented, too. * @@ -1326,7 +1326,7 @@ namespace Dune * @brief Counts the number of neighbours belonging to an aggregate. * * - * If the inluence flag of the edge is set the counter is + * If the influence flag of the edge is set the counter is * increased and/or if the depends flag is set it is * incremented, too. * @@ -1341,7 +1341,7 @@ namespace Dune int aggregateNeighbours(const Vertex& vertex, const AggregateDescriptor& aggregate, const AggregatesMap<Vertex>& aggregates) const; /** - * @brief Checks wether a vertex is admisible to be added to an aggregate. + * @brief Checks whether a vertex is admissible to be added to an aggregate. * * @param vertex The vertex whose admissibility id to be checked. * @param aggregate The id of the aggregate. @@ -1457,7 +1457,7 @@ namespace Dune return; } real_type eji = norm_(*opposite_entry); - // skip positve offdiagonals if norm preserves sign of them. + // skip positive offdiagonals if norm preserves sign of them. if(!N::is_sign_preserving || (eij<0 || eji<0)) if(eji / norm_(matrix_->operator[](edge.target())[edge.target()]) * eij/ diagonal_ > alpha() * maxValue_) { diff --git a/dune/istl/paamg/amg.hh b/dune/istl/paamg/amg.hh index 417f8e7a7..3c2a5f614 100644 --- a/dune/istl/paamg/amg.hh +++ b/dune/istl/paamg/amg.hh @@ -101,7 +101,7 @@ namespace Dune /** * @brief Construct a new amg with a specific coarse solver. - * @param matrices The already set up matix hierarchy. + * @param matrices The already set-up matrix hierarchy. * @param coarseSolver The set up solver to use on the coarse * grid, must match the coarse matrix in the matrix hierarchy. * @param smootherArgs The arguments needed for thesmoother to use @@ -144,12 +144,12 @@ namespace Dune accumulationMode | If and how data is agglomerated on coarser level to | fewer processors. ("atOnce": do agglomeration once and | to one process; "successive": Multiple agglomerations to - | fewer proceses until all data is on one process; + | fewer processes until all data is on one process; | "none": Do no agglomeration at all and solve coarse level | iteratively). prolongationDampingFactor | Damping factor for the prolongation. - alpha | Scaling avlue for marking connections as strong. - beta | Treshold for marking nodes as isolated. + alpha | Scaling value for marking connections as strong. + beta | Threshold for marking nodes as isolated. additive | Whether to use additive multigrid. gamma | 1 for V-cycle, 2 for W-cycle. preSteps | Number of presmoothing steps. diff --git a/dune/istl/paamg/dependency.hh b/dune/istl/paamg/dependency.hh index 5a80f98dd..82ea609ec 100644 --- a/dune/istl/paamg/dependency.hh +++ b/dune/istl/paamg/dependency.hh @@ -29,11 +29,11 @@ namespace Dune */ /** - * @brief Class representing the properties of an ede in the matrix graph. + * @brief Class representing the properties of an edge in the matrix graph. * * During the coarsening process the matrix graph needs to hold different * properties of its edges. - * This class ontains methods for getting and setting these edge attributes. + * This class contains methods for getting and setting these edge attributes. */ class EdgeProperties { @@ -56,7 +56,7 @@ namespace Dune bool operator[](std::size_t v) const; /** - * @brief Checks wether the vertex the edge points to depends on + * @brief Checks whether the vertex the edge points to depends on * the vertex the edge starts. * @return True if it depends on the starting point. */ @@ -74,7 +74,7 @@ namespace Dune void resetDepends(); /** - * @brief Checks wether the start vertex is influenced by the end vertex. + * @brief Checks whether the start vertex is influenced by the end vertex. * @return True if it is influenced. */ bool influences() const; @@ -90,19 +90,19 @@ namespace Dune void resetInfluences(); /** - * @brief Checks wether the edge is one way. + * @brief Checks whether the edge is one way. * I.e. either the influence or the depends flag but is set. */ bool isOneWay() const; /** - * @brief Checks wether the edge is two way. + * @brief Checks whether the edge is two way. * I.e. both the influence flag and the depends flag are that. */ bool isTwoWay() const; /** - * @brief Checks wether the edge is strong. + * @brief Checks whether the edge is strong. * I.e. the influence or depends flag is set. */ bool isStrong() const; @@ -151,7 +151,7 @@ namespace Dune void setIsolated(); /** - * @brief Checks wether the node is isolated. + * @brief Checks whether the node is isolated. */ bool isolated() const; @@ -166,7 +166,7 @@ namespace Dune void setVisited(); /** - * @brief Checks wether the node is marked as visited. + * @brief Checks whether the node is marked as visited. */ bool visited() const; @@ -181,7 +181,7 @@ namespace Dune void setFront(); /** - * @brief Checks wether the node is marked as a front node. + * @brief Checks whether the node is marked as a front node. */ bool front() const; diff --git a/dune/istl/paamg/fastamg.hh b/dune/istl/paamg/fastamg.hh index 37bad452b..9c1c83c1e 100644 --- a/dune/istl/paamg/fastamg.hh +++ b/dune/istl/paamg/fastamg.hh @@ -82,7 +82,7 @@ namespace Dune /** * @brief Construct a new amg with a specific coarse solver. - * @param matrices The already set up matix hierarchy. + * @param matrices The already set-up matrix hierarchy. * @param coarseSolver The set up solver to use on the coarse * grid, must match the coarse matrix in the matrix hierarchy. * @param parms The parameters for the AMG. @@ -219,7 +219,7 @@ namespace Dune * @brief Apply pre smoothing on the current level. * @param levelContext The context with the iterators for the level. * @param x The left hand side at the current level. - * @param b The rightt hand side at the current level. + * @param b The right hand side at the current level. */ void presmooth(LevelContext& levelContext, Domain& x, const Range& b); @@ -227,7 +227,7 @@ namespace Dune * @brief Apply post smoothing on the current level. * @param levelContext The context with the iterators for the level. * @param x The left hand side at the current level. - * @param b The rightt hand side at the current level. + * @param b The right hand side at the current level. */ void postsmooth(LevelContext& levelContext, Domain& x, const Range& b); diff --git a/dune/istl/paamg/graph.hh b/dune/istl/paamg/graph.hh index 44f5f2c9b..5f712f89b 100644 --- a/dune/istl/paamg/graph.hh +++ b/dune/istl/paamg/graph.hh @@ -834,7 +834,7 @@ namespace Dune /** * @brief Constructor for the end iterator. * - * Only operator!= or operator== can be calles safely on an iterator + * Only operator!= or operator== can be called safely on an iterator * constructed this way. * @param iter The iterator of the underlying graph. */ diff --git a/dune/istl/paamg/indicescoarsener.hh b/dune/istl/paamg/indicescoarsener.hh index 8c68576ee..4f9a6f9ef 100644 --- a/dune/istl/paamg/indicescoarsener.hh +++ b/dune/istl/paamg/indicescoarsener.hh @@ -372,7 +372,7 @@ namespace Dune // The number of neighbours should not change! assert(coarseRemote.neighbours()==fineRemote.neighbours()); - // snyc the index set and the remote indices to recompute missing + // sync the index set and the remote indices to recompute missing // indices IndicesSyncer<ParallelIndexSet> syncer(coarseIndices, coarseRemote); syncer.sync(renumberer); diff --git a/dune/istl/paamg/kamg.hh b/dune/istl/paamg/kamg.hh index 233e302c8..267690915 100644 --- a/dune/istl/paamg/kamg.hh +++ b/dune/istl/paamg/kamg.hh @@ -170,7 +170,7 @@ namespace Dune /** * @brief Construct a new amg with a specific coarse solver. - * @param matrices The already set up matix hierarchy. + * @param matrices The already set-up matrix hierarchy. * @param coarseSolver The set up solver to use on the coarse * grid, must match the coarse matrix in the matrix hierarchy. * @param smootherArgs The arguments needed for thesmoother to use diff --git a/dune/istl/paamg/matrixhierarchy.hh b/dune/istl/paamg/matrixhierarchy.hh index d984b0c0d..acba3021b 100644 --- a/dune/istl/paamg/matrixhierarchy.hh +++ b/dune/istl/paamg/matrixhierarchy.hh @@ -194,7 +194,7 @@ namespace Dune * @brief Get the mapping of fine level unknowns to coarse level * aggregates. * - * For each fine level unknown i the correcponding data[i] is the + * For each fine level unknown i the corresponding data[i] is the * aggregate it belongs to on the coarsest level. * * @param[out] data The mapping of fine level unknowns to coarse level @@ -517,7 +517,7 @@ namespace Dune int start, end, overlapStart, overlapEnd; int procs=info->communicator().rank(); int n = UNKNOWNS/procs; // number of unknowns per process - int bigger = UNKNOWNS%procs; // number of process with n+1 unknows + int bigger = UNKNOWNS%procs; // number of process with n+1 unknowns // Compute owner region if(rank<bigger) { diff --git a/dune/istl/paamg/smoother.hh b/dune/istl/paamg/smoother.hh index 838b13b95..778391319 100644 --- a/dune/istl/paamg/smoother.hh +++ b/dune/istl/paamg/smoother.hh @@ -42,7 +42,7 @@ namespace Dune typedef typename FieldTraits<T>::real_type RelaxationFactor; /** - * @brief The numbe of iterations to perform. + * @brief The number of iterations to perform. */ int iterations; /** diff --git a/dune/istl/paamg/test/anisotropic.hh b/dune/istl/paamg/test/anisotropic.hh index c5cb53d2f..958077aea 100644 --- a/dune/istl/paamg/test/anisotropic.hh +++ b/dune/istl/paamg/test/anisotropic.hh @@ -56,7 +56,7 @@ void setupPattern(int N, M& mat, Dune::ParallelIndexSet<G,L,s>& indices, int ove iter.insert(iter.index()-1); if(i < overlapEnd-1) - // We have a rigt neighbour + // We have a right neighbour iter.insert(iter.index()+1); // j direction @@ -163,7 +163,7 @@ Dune::BCRSMatrix<MatrixEntry> setupAnisotropic2d(int N, Dune::ParallelIndexSet<G int start, end, overlapStart, overlapEnd; int n = N/procs; // number of unknowns per process - int bigger = N%procs; // number of process with n+1 unknows + int bigger = N%procs; // number of process with n+1 unknowns // Compute owner region if(rank<bigger) { diff --git a/dune/istl/paamg/test/fastamg.cc b/dune/istl/paamg/test/fastamg.cc index 8431792fd..861e9f1b1 100644 --- a/dune/istl/paamg/test/fastamg.cc +++ b/dune/istl/paamg/test/fastamg.cc @@ -90,9 +90,9 @@ void testAMG(int N, int coarsenTarget, int ml) Dune::SeqScalarProduct<Vector> sp; typedef Dune::Amg::FastAMG<Operator,Vector> AMG; - Dune::Amg::Parameters parms; + Dune::Amg::Parameters params; - AMG amg(fop, criterion, parms); + AMG amg(fop, criterion, params); // check if recalculation of matrix hierarchy works amg.recalculateHierarchy(); diff --git a/dune/istl/paamg/twolevelmethod.hh b/dune/istl/paamg/twolevelmethod.hh index 6058ad0c2..a5b518ea7 100644 --- a/dune/istl/paamg/twolevelmethod.hh +++ b/dune/istl/paamg/twolevelmethod.hh @@ -104,7 +104,7 @@ public: * * After returning from this function the coarse level correction * will have been added to fine level system. - * @param[inout] fineLhs The left hand side of the fine level to update + * @param[in,out] fineLhs The left hand side of the fine level to update * with the coarse level correction. */ virtual void moveToFineLevel(FineDomainType& fineLhs)=0; diff --git a/dune/istl/preconditioner.hh b/dune/istl/preconditioner.hh index a544b13f6..9067fa6d7 100644 --- a/dune/istl/preconditioner.hh +++ b/dune/istl/preconditioner.hh @@ -52,7 +52,7 @@ namespace Dune { \note if a preconditioner is copied (e.g. for a second thread) again the pre() method has to be called to ensure proper memory - mangement. + management. \code X x(0.0); diff --git a/dune/istl/preconditioners.hh b/dune/istl/preconditioners.hh index 6083e87ac..9841ac20b 100644 --- a/dune/istl/preconditioners.hh +++ b/dune/istl/preconditioners.hh @@ -36,7 +36,7 @@ namespace Dune { * together with matching ScalarProducts. * * Some of the available preconditioners (e.g. SeqJacobi, SeqSOR, SeqSSOR)) - * may be given an aditional int as a template parameter, the block recursion level. + * may be given an additional int as a template parameter, the block recursion level. * These preconditioners * can be used on block-recursive matrices with an arbitrary hierarchy depth * (eg. BCRSMatrix<BCRSMatrix<FieldMatrix,n,m> > >. Given a block recursion level diff --git a/dune/istl/repartition.hh b/dune/istl/repartition.hh index 2271fd873..c0e2c394d 100644 --- a/dune/istl/repartition.hh +++ b/dune/istl/repartition.hh @@ -13,7 +13,7 @@ #if HAVE_PARMETIS // Explicitly use C linkage as scotch does not extern "C" in its headers. // Works because ParMETIS/METIS checks whether compiler is C++ and otherwise -// does not use extern "C". Therfore no nested extern "C" will be created +// does not use extern "C". Therefore no nested extern "C" will be created. extern "C" { #include <parmetis.h> @@ -109,7 +109,7 @@ namespace Dune //starting atmaxgi+\sum_{i=1}^p neededall[i] // All created indices are owned by the process maxgi=oocomm.communicator().max(maxgi); - ++maxgi; //Sart with the next free index. + ++maxgi; // Start with the next free index. for(int i=0; i<oocomm.communicator().rank(); ++i) maxgi=maxgi+neededall[i]; // TODO: make this more generic @@ -512,7 +512,7 @@ namespace Dune { if(i->first==old->first) { - std::cerr<<"Value at indes"<<old-ownerVec.begin()<<" is the same as at index " + std::cerr<<"Value at index "<<old-ownerVec.begin()<<" is the same as at index " <<i-ownerVec.begin()<<" ["<<old->first<<","<<old->second<<"]==[" <<i->first<<","<<i->second<<"]"<<std::endl; throw "Huch!"; @@ -653,7 +653,7 @@ namespace Dune template<class T> void operator()(const T& edge) { - // Get the egde weight + // Get the edge weight // const Weight& weight=edge.weight(); adj_[i_] = data_.toParmetis(edge.target()); i_++; @@ -905,7 +905,7 @@ namespace Dune // // calculate edge count // for(RIter row=mat.begin(), endr=mat.end(); row != endr; ++row) // if(owner[row.index()]==OwnerOverlapCopyAttributeSet::owner) - // for(CIter entry= row->begin(), ende = row->end(); entry != ende; ++entry) + // for(CIter entry= row->begin(), end = row->end(); entry != end; ++entry) // ++edgecount[owner[entry.index()]]; // setup edge and weight pattern @@ -914,7 +914,7 @@ namespace Dune #ifdef USE_WEIGHTS vwgt = new Metis::idx_t[1]; - vwgt[0]= mat.N(); // weight is numer of rows TODO: Should actually be the nonzeros. + vwgt[0]= mat.N(); // weight is number of rows TODO: Should actually be the nonzeros. adjwgt = new Metis::idx_t[noNeighbours]; Metis::idx_t* adjwp=adjwgt; @@ -1050,7 +1050,7 @@ namespace Dune curr!=end; ++curr) gnoedges += *curr; - // alocate gobal graph + // allocate global graph Dune::dinfo<<"gxadjlen: "<<gxadjlen<<" noVertices: "<<noVertices <<" gnoedges: "<<gnoedges<<std::endl; gxadj = new Metis::idx_t[gxadjlen]; @@ -1116,7 +1116,7 @@ namespace Dune #endif // everything should be fine now!!! if(verbose && oocomm.communicator().rank()==0) - std::cout<<"Postprocesing global graph data took "<<time1.elapsed()<<std::endl; + std::cout<<"Postprocessing global graph data took "<<time1.elapsed()<<std::endl; time1.reset(); #ifndef NDEBUG assert(isValidGraph(noVertices, noVertices, gnoedges, @@ -1577,7 +1577,7 @@ namespace Dune // 4.2) Start the communication // - // Get all the owner and overlap vertices for myself ans save + // Get all the owner and overlap vertices for myself and save // it in the vectors myOwnerVec and myOverlapVec. // The received vertices from the other processes are simple // added to these vector. diff --git a/dune/istl/scalarproducts.hh b/dune/istl/scalarproducts.hh index ecbff5bc6..16682a5df 100644 --- a/dune/istl/scalarproducts.hh +++ b/dune/istl/scalarproducts.hh @@ -210,7 +210,7 @@ namespace Dune { /** @} end documentation */ /** - * \brief Choose the approriate scalar product for a solver category. + * \brief Choose the appropriate scalar product for a solver category. * * \todo this helper function should be replaced by a proper factory * diff --git a/dune/istl/schwarz.hh b/dune/istl/schwarz.hh index f3d9f28ef..b3a01c681 100644 --- a/dune/istl/schwarz.hh +++ b/dune/istl/schwarz.hh @@ -209,7 +209,7 @@ namespace Dune { } /*! - \brief Apply the precondtioner + \brief Apply the preconditioner \copydoc Preconditioner::apply(X&,const Y&) */ diff --git a/dune/istl/solvers.hh b/dune/istl/solvers.hh index 1a71d45dd..b9dcb5f39 100644 --- a/dune/istl/solvers.hh +++ b/dune/istl/solvers.hh @@ -1673,7 +1673,7 @@ private: /*! \brief Complete flexible conjugate gradient method This solver is a simple modification of the RestartedFCGSolver and, if possible, uses mmax old directions. - It uses noticably more memory, but provides more stability for preconditioner changes. + It uses noticeably more memory, but provides more stability for preconditioner changes. */ template<class X> diff --git a/dune/istl/test/complexrhstest.cc b/dune/istl/test/complexrhstest.cc index fa68405ba..1e32eadd4 100644 --- a/dune/istl/test/complexrhstest.cc +++ b/dune/istl/test/complexrhstest.cc @@ -37,7 +37,7 @@ typedef std::complex<double> FIELD_TYPE; N=3; A = full(gallery('poisson',N)); % create poisson matrix - % find a solution consiting of complex integers + % find a solution consisting of complex integers indVec = (0:(N*N-1))', iVec = complex(0,1).^indVec + indVec, x0 = iVec .* indVec, diff --git a/dune/istl/test/vbvectortest.cc b/dune/istl/test/vbvectortest.cc index 9d7e7e091..2ecd29cf9 100644 --- a/dune/istl/test/vbvectortest.cc +++ b/dune/istl/test/vbvectortest.cc @@ -35,7 +35,7 @@ int main() We have to un-initialize it first: */ std::size_t size = 20; - v3.resize(size); // this makes v3 unitialized again + v3.resize(size); // this makes v3 uninitialized again // Set block sizes with CreateIterator: for (auto cIt = v3.createbegin(); cIt!=v3.createend(); ++cIt) diff --git a/dune/istl/vbvector.hh b/dune/istl/vbvector.hh index f1e142d82..af0750331 100644 --- a/dune/istl/vbvector.hh +++ b/dune/istl/vbvector.hh @@ -380,7 +380,7 @@ namespace Dune { // and we have a usable vector initialized = true; - return *this; // Gebe Referenz zurueck damit a=b=c; klappt + return *this; // Return reference to make constructions like a=b=c; work. } diff --git a/dune/python/istl/bvector.hh b/dune/python/istl/bvector.hh index 742d9583b..81184b80b 100644 --- a/dune/python/istl/bvector.hh +++ b/dune/python/istl/bvector.hh @@ -179,12 +179,12 @@ namespace Dune - // registserBlockVector + // registerBlockVector // -------------------- //for the new bindings and arbitrary block size haven't - //the generator acutally takes the scope into account which is why we do nothing with it here - //so when doing a dune.istl blockvector it doesn't actually define any of the rest ofthe bindings + //the generator actually takes the scope into account which is why we do nothing with it here + //so when doing a dune.istl blockvector it doesn't actually define any of the rest of the bindings template< class BlockVector, class ... options > void registerBlockVector ( pybind11::handle scope, pybind11::class_<BlockVector, options ... > cls ) { -- GitLab