Skip to content

Commit 2844510

Browse files
committed
Increased descreptiveness function names and small comment changes
1 parent a451770 commit 2844510

3 files changed

Lines changed: 9 additions & 7 deletions

File tree

Common/include/grid_movement/CRadialBasisFunctionInterpolation.hpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -228,18 +228,20 @@ class CRadialBasisFunctionInterpolation : public CVolumetricMovement {
228228
/*!
229229
* \brief Custom comparison function, for sorting the CRadialBasisFunctionNode objects based on their index.
230230
* \param[in] a - First considered Radial Basis Function Node.
231-
* \param[in] b - second considered Radial Basis Function Node.
231+
* \param[in] b - Second considered Radial Basis Function Node.
232+
* \return True if index of a is smaller than index of b.
232233
*/
233-
inline static bool Compare(CRadialBasisFunctionNode* a, CRadialBasisFunctionNode* b){
234+
inline static bool HasSmallerIndex(CRadialBasisFunctionNode* a, CRadialBasisFunctionNode* b){
234235
return a->GetIndex() < b->GetIndex();
235236
}
236237

237238
/*!
238239
* \brief Custom equality function, for obtaining a unique set of CRadialBasisFunctionNode objects.
239240
* \param[in] a - First considered Radial Basis Function Node.
240-
* \param[in] b - second considered Radial Basis Function Node.
241+
* \param[in] b - Second considered Radial Basis Function Node.
242+
* \return True if index of a and b are equal.
241243
*/
242-
inline static bool Equal(CRadialBasisFunctionNode* a, CRadialBasisFunctionNode* b){
244+
inline static bool HasEqualIndex(CRadialBasisFunctionNode* a, CRadialBasisFunctionNode* b){
243245
return a->GetIndex() == b->GetIndex();
244246
}
245247
};

Common/include/grid_movement/CVolumetricMovementFactory.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ namespace CVolumetricMovementFactory {
3535
* \brief Factory method for CVolumetricMovement objects.
3636
* \param[in] geometry_container - Geometrical definition of the problem.
3737
* \param[in] config - Definition of the particular problem.
38-
* \return Pointer to volumetric moever on the heap, caller is responsible for deletion.
38+
* \return Pointer to the allocated volumetric mover.
3939
*/
4040

4141
CVolumetricMovement* CreateCVolumetricMovement(CGeometry* geometry, CConfig* config);

Common/src/grid_movement/CRadialBasisFunctionInterpolation.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -198,10 +198,10 @@ void CRadialBasisFunctionInterpolation::SetBoundNodes(CGeometry* geometry, CConf
198198
}
199199

200200
/*--- Sorting of the boundary nodes based on their index ---*/
201-
sort(BoundNodes.begin(), BoundNodes.end(), Compare);
201+
sort(BoundNodes.begin(), BoundNodes.end(), HasSmallerIndex);
202202

203203
/*--- Obtaining unique set ---*/
204-
BoundNodes.resize(std::distance(BoundNodes.begin(), unique(BoundNodes.begin(), BoundNodes.end(), Equal)));
204+
BoundNodes.resize(std::distance(BoundNodes.begin(), unique(BoundNodes.begin(), BoundNodes.end(), HasEqualIndex)));
205205
}
206206

207207
void CRadialBasisFunctionInterpolation::SetCtrlNodes(CConfig* config){

0 commit comments

Comments
 (0)