diff --git a/src/functionObjects/field/fieldAverage/fieldAverage.C b/src/functionObjects/field/fieldAverage/fieldAverage.C index 72794fd602..a2b46f4a33 100644 --- a/src/functionObjects/field/fieldAverage/fieldAverage.C +++ b/src/functionObjects/field/fieldAverage/fieldAverage.C @@ -40,7 +40,7 @@ namespace functionObjects } -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // void Foam::functionObjects::fieldAverage::resetFields() { diff --git a/src/functionObjects/field/fieldAverage/fieldAverage.H b/src/functionObjects/field/fieldAverage/fieldAverage.H index 62c2aaf647..850f6f72a8 100644 --- a/src/functionObjects/field/fieldAverage/fieldAverage.H +++ b/src/functionObjects/field/fieldAverage/fieldAverage.H @@ -185,7 +185,7 @@ protected: label periodIndex_; - // Private Member Functions + // Protected Member Functions // Initialisation routines diff --git a/src/functionObjects/field/fieldMinMax/fieldMinMax.C b/src/functionObjects/field/fieldMinMax/fieldMinMax.C index 738228b7de..d45f180b88 100644 --- a/src/functionObjects/field/fieldMinMax/fieldMinMax.C +++ b/src/functionObjects/field/fieldMinMax/fieldMinMax.C @@ -52,7 +52,7 @@ const Foam::NamedEnum > Foam::functionObjects::fieldMinMax::modeTypeNames_; -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // void Foam::functionObjects::fieldMinMax::writeFileHeader(const label i) { diff --git a/src/functionObjects/field/fieldMinMax/fieldMinMax.H b/src/functionObjects/field/fieldMinMax/fieldMinMax.H index 69fc1b214d..6d34a105cb 100644 --- a/src/functionObjects/field/fieldMinMax/fieldMinMax.H +++ b/src/functionObjects/field/fieldMinMax/fieldMinMax.H @@ -123,7 +123,7 @@ protected: wordList fieldSet_; - // Private Member Functions + // Protected Member Functions //- Helper function to write the output template diff --git a/src/functionObjects/field/fieldValues/surfaceFieldValue/surfaceFieldValue.C b/src/functionObjects/field/fieldValues/surfaceFieldValue/surfaceFieldValue.C index dc1a450b20..b532696e40 100644 --- a/src/functionObjects/field/fieldValues/surfaceFieldValue/surfaceFieldValue.C +++ b/src/functionObjects/field/fieldValues/surfaceFieldValue/surfaceFieldValue.C @@ -98,7 +98,7 @@ const Foam::NamedEnum > Foam::functionObjects::fieldValues::surfaceFieldValue::operationTypeNames_; -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // void Foam::functionObjects::fieldValues::surfaceFieldValue::setFaceZoneFaces() { diff --git a/src/functionObjects/field/nearWallFields/nearWallFields.C b/src/functionObjects/field/nearWallFields/nearWallFields.C index 063ff610f9..0b23094ddd 100644 --- a/src/functionObjects/field/nearWallFields/nearWallFields.C +++ b/src/functionObjects/field/nearWallFields/nearWallFields.C @@ -42,7 +42,7 @@ namespace functionObjects } -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // void Foam::functionObjects::nearWallFields::calcAddressing() { diff --git a/src/functionObjects/field/wallBoundedStreamLine/wallBoundedParticle.C b/src/functionObjects/field/wallBoundedStreamLine/wallBoundedParticle.C index beb9167673..560201960d 100644 --- a/src/functionObjects/field/wallBoundedStreamLine/wallBoundedParticle.C +++ b/src/functionObjects/field/wallBoundedStreamLine/wallBoundedParticle.C @@ -33,7 +33,7 @@ const std::size_t Foam::wallBoundedParticle::sizeofFields_ ); -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // Foam::edge Foam::wallBoundedParticle::currentEdge() const { diff --git a/src/functionObjects/utilities/codedFunctionObject/codedFunctionObject.C b/src/functionObjects/utilities/codedFunctionObject/codedFunctionObject.C index 33d2227e65..c676703e9d 100644 --- a/src/functionObjects/utilities/codedFunctionObject/codedFunctionObject.C +++ b/src/functionObjects/utilities/codedFunctionObject/codedFunctionObject.C @@ -47,7 +47,7 @@ namespace Foam ); } -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // void Foam::codedFunctionObject::prepare ( diff --git a/src/mesh/blockMesh/searchableCurve/searchableCurve.H b/src/mesh/blockMesh/searchableCurve/searchableCurve.H index 3c5f122cbf..1b9d5c4f72 100644 --- a/src/mesh/blockMesh/searchableCurve/searchableCurve.H +++ b/src/mesh/blockMesh/searchableCurve/searchableCurve.H @@ -37,9 +37,6 @@ SourceFiles #include "treeBoundBox.H" #include "searchableSurface.H" -//#include "edgeMesh.H" -//#include "indexedOctree.H" -//#include "treeDataEdge.H" // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -59,8 +56,6 @@ class searchableCurve : public searchableSurface { -private: - // Private Member Data //- Feature @@ -222,15 +217,11 @@ public: NotImplemented; } - - // regIOobject implementation - bool writeData(Ostream&) const { NotImplemented; return false; } - }; diff --git a/src/meshTools/AMIInterpolation/AMIInterpolation/AMIMethod/AMIMethod/AMIMethod.C b/src/meshTools/AMIInterpolation/AMIInterpolation/AMIMethod/AMIMethod/AMIMethod.C index 8341460fcc..32eb59bd45 100644 --- a/src/meshTools/AMIInterpolation/AMIInterpolation/AMIMethod/AMIMethod/AMIMethod.C +++ b/src/meshTools/AMIInterpolation/AMIInterpolation/AMIMethod/AMIMethod/AMIMethod.C @@ -28,7 +28,7 @@ License #include "mapDistribute.H" #include "unitConversion.H" -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // template void Foam::AMIMethod::checkPatches() const diff --git a/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.C b/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.C index b02dbed509..d66be7da71 100644 --- a/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.C +++ b/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.C @@ -67,44 +67,6 @@ Foam::vector Foam::cyclicAMIPolyPatch::findFaceNormalMaxRadius } -// * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * * // - -void Foam::cyclicAMIPolyPatch::calcTransforms() -{ - const cyclicAMIPolyPatch& half0 = *this; - vectorField half0Areas(half0.size()); - forAll(half0, facei) - { - half0Areas[facei] = half0[facei].normal(half0.points()); - } - - const cyclicAMIPolyPatch& half1 = neighbPatch(); - vectorField half1Areas(half1.size()); - forAll(half1, facei) - { - half1Areas[facei] = half1[facei].normal(half1.points()); - } - - calcTransforms - ( - half0, - half0.faceCentres(), - half0Areas, - half1.faceCentres(), - half1Areas - ); - - if (debug) - { - Pout<< "calcTransforms() : patch: " << name() << nl - << " forwardT = " << forwardT() << nl - << " reverseT = " << reverseT() << nl - << " separation = " << separation() << nl - << " collocated = " << collocated() << nl << endl; - } -} - - void Foam::cyclicAMIPolyPatch::calcTransforms ( const primitivePatch& half0, @@ -319,7 +281,7 @@ void Foam::cyclicAMIPolyPatch::calcTransforms } -// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * * // void Foam::cyclicAMIPolyPatch::resetAMI ( @@ -395,6 +357,42 @@ void Foam::cyclicAMIPolyPatch::resetAMI } +void Foam::cyclicAMIPolyPatch::calcTransforms() +{ + const cyclicAMIPolyPatch& half0 = *this; + vectorField half0Areas(half0.size()); + forAll(half0, facei) + { + half0Areas[facei] = half0[facei].normal(half0.points()); + } + + const cyclicAMIPolyPatch& half1 = neighbPatch(); + vectorField half1Areas(half1.size()); + forAll(half1, facei) + { + half1Areas[facei] = half1[facei].normal(half1.points()); + } + + calcTransforms + ( + half0, + half0.faceCentres(), + half0Areas, + half1.faceCentres(), + half1Areas + ); + + if (debug) + { + Pout<< "calcTransforms() : patch: " << name() << nl + << " forwardT = " << forwardT() << nl + << " reverseT = " << reverseT() << nl + << " separation = " << separation() << nl + << " collocated = " << collocated() << nl << endl; + } +} + + void Foam::cyclicAMIPolyPatch::initGeometry(PstreamBuffers& pBufs) { // Clear the invalid AMI diff --git a/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.H b/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.H index f89bdfa1cb..f510f60d2f 100644 --- a/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.H +++ b/src/meshTools/AMIInterpolation/patches/cyclicAMI/cyclicAMIPolyPatch/cyclicAMIPolyPatch.H @@ -53,9 +53,6 @@ class cyclicAMIPolyPatch : public coupledPolyPatch { - -private: - // Private Member Functions //- Return normal of face at max distance from rotation axis diff --git a/src/meshTools/algorithms/MeshWave/FaceCellWave.C b/src/meshTools/algorithms/MeshWave/FaceCellWave.C index 8518350e80..f76d716574 100644 --- a/src/meshTools/algorithms/MeshWave/FaceCellWave.C +++ b/src/meshTools/algorithms/MeshWave/FaceCellWave.C @@ -104,7 +104,7 @@ namespace Foam } -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // template bool Foam::FaceCellWave::updateCell diff --git a/src/meshTools/algorithms/MeshWave/FaceCellWave.H b/src/meshTools/algorithms/MeshWave/FaceCellWave.H index 0653e255c1..f86aab57d0 100644 --- a/src/meshTools/algorithms/MeshWave/FaceCellWave.H +++ b/src/meshTools/algorithms/MeshWave/FaceCellWave.H @@ -77,8 +77,6 @@ class FaceCellWave : public FaceCellWaveName { -private: - // Private Member Functions //- Disallow default bitwise copy construct @@ -90,7 +88,7 @@ private: protected: - // Private data + // Protected data //- Reference to mesh const polyMesh& mesh_; @@ -244,7 +242,7 @@ protected: void handleExplicitConnections(); - // Private static data + // Protected static data static const scalar geomTol_; static scalar propagationTol_; diff --git a/src/meshTools/mappedPatches/mappedPolyPatch/mappedPatchBase.H b/src/meshTools/mappedPatches/mappedPolyPatch/mappedPatchBase.H index 38ef08c3b2..1fe40bfc35 100644 --- a/src/meshTools/mappedPatches/mappedPolyPatch/mappedPatchBase.H +++ b/src/meshTools/mappedPatches/mappedPolyPatch/mappedPatchBase.H @@ -133,7 +133,7 @@ public: //- Helper class for finding nearest - // Nearest: + // Nearest: // - point+local index // - sqr(distance) // - processor diff --git a/src/meshTools/sets/topoSetSource/topoSetSource.C b/src/meshTools/sets/topoSetSource/topoSetSource.C index 295af9f0f9..216c417c64 100644 --- a/src/meshTools/sets/topoSetSource/topoSetSource.C +++ b/src/meshTools/sets/topoSetSource/topoSetSource.C @@ -134,7 +134,7 @@ Foam::Istream& Foam::topoSetSource::checkIs(Istream& is) } -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // void Foam::topoSetSource::addOrDelete ( diff --git a/src/meshTools/sets/topoSets/topoSet.C b/src/meshTools/sets/topoSets/topoSet.C index 23127c2358..c4a73597e7 100644 --- a/src/meshTools/sets/topoSets/topoSet.C +++ b/src/meshTools/sets/topoSets/topoSet.C @@ -130,7 +130,7 @@ Foam::fileName Foam::topoSet::localPath } -// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * // +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // // Update stored cell numbers using map. // Do in two passes to prevent allocation if nothing changed. diff --git a/src/meshTools/triSurface/triSurfaceTools/triSurfaceTools.H b/src/meshTools/triSurface/triSurfaceTools/triSurfaceTools.H index 24fd96322e..1b4578b6ff 100644 --- a/src/meshTools/triSurface/triSurfaceTools/triSurfaceTools.H +++ b/src/meshTools/triSurface/triSurfaceTools/triSurfaceTools.H @@ -159,7 +159,7 @@ class triSurfaceTools ); //- Calculate minimum (cos of) edge angle using addressing from - /// collapsing + // collapsing // edge to v1 at pt. Returns 1 if v1 is on edge without neighbours // (and hence no edge angle can be defined) static scalar collapseMinCosAngle diff --git a/src/rigidBodyDynamics/rigidBodyModel/rigidBodyModel.C b/src/rigidBodyDynamics/rigidBodyModel/rigidBodyModel.C index b2236c39c4..4a8de4eac4 100644 --- a/src/rigidBodyDynamics/rigidBodyModel/rigidBodyModel.C +++ b/src/rigidBodyDynamics/rigidBodyModel/rigidBodyModel.C @@ -114,6 +114,53 @@ void Foam::RBD::rigidBodyModel::addRestraints } +// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * // + +Foam::label Foam::RBD::rigidBodyModel::join_ +( + const label parentID, + const spatialTransform& XT, + autoPtr jointPtr, + autoPtr bodyPtr +) +{ + // Append the body + const rigidBody& body = bodyPtr(); + bodies_.append(bodyPtr); + const label bodyID = nBodies()-1; + bodyIDs_.insert(body.name(), bodyID); + + // If the parentID refers to a merged body find the parent into which it has + // been merged and set lambda and XT accordingly + if (merged(parentID)) + { + const subBody& sBody = mergedBody(parentID); + lambda_.append(sBody.masterID()); + XT_.append(XT & sBody.masterXT()); + } + else + { + lambda_.append(parentID); + XT_.append(XT); + } + + // Append the joint + const joint& prevJoint = joints_[joints_.size() - 1]; + joints_.append(jointPtr); + joint& curJoint = joints_[joints_.size() - 1]; + curJoint.index() = joints_.size() - 1; + curJoint.qIndex() = prevJoint.qIndex() + prevJoint.nDoF(); + + // Increment the degrees of freedom + nDoF_ += curJoint.nDoF(); + unitQuaternions_ = unitQuaternions_ || curJoint.unitQuaternion(); + + resizeState(); + + return bodyID; +} + + // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * * // Foam::RBD::rigidBodyModel::rigidBodyModel() @@ -168,52 +215,7 @@ Foam::RBD::rigidBodyModel::~rigidBodyModel() {} -// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * // - -Foam::label Foam::RBD::rigidBodyModel::join_ -( - const label parentID, - const spatialTransform& XT, - autoPtr jointPtr, - autoPtr bodyPtr -) -{ - // Append the body - const rigidBody& body = bodyPtr(); - bodies_.append(bodyPtr); - const label bodyID = nBodies()-1; - bodyIDs_.insert(body.name(), bodyID); - - // If the parentID refers to a merged body find the parent into which it has - // been merged and set lambda and XT accordingly - if (merged(parentID)) - { - const subBody& sBody = mergedBody(parentID); - lambda_.append(sBody.masterID()); - XT_.append(XT & sBody.masterXT()); - } - else - { - lambda_.append(parentID); - XT_.append(XT); - } - - // Append the joint - const joint& prevJoint = joints_[joints_.size() - 1]; - joints_.append(jointPtr); - joint& curJoint = joints_[joints_.size() - 1]; - curJoint.index() = joints_.size() - 1; - curJoint.qIndex() = prevJoint.qIndex() + prevJoint.nDoF(); - - // Increment the degrees of freedom - nDoF_ += curJoint.nDoF(); - unitQuaternions_ = unitQuaternions_ || curJoint.unitQuaternion(); - - resizeState(); - - return bodyID; -} - +// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * // Foam::label Foam::RBD::rigidBodyModel::join ( diff --git a/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.C b/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.C index ecd9105aa6..a028b4b090 100644 --- a/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.C +++ b/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.C @@ -36,7 +36,7 @@ namespace Foam } -// * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * * // +// * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * * // void Foam::incompressibleTwoPhaseMixture::calcNu() { diff --git a/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.H b/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.H index 6928f50b58..a12fe58736 100644 --- a/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.H +++ b/src/transportModels/incompressible/incompressibleTwoPhaseMixture/incompressibleTwoPhaseMixture.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2014 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -72,7 +72,7 @@ protected: volScalarField nu_; - // Private Member Functions + // Protected Member Functions //- Calculate and return the laminar viscosity void calcNu();