ENH: maxLoadUnbalance control.

This commit is contained in:
graham
2011-06-03 16:15:27 +01:00
parent 231d1318bd
commit 1eb3cd5a52
3 changed files with 21 additions and 0 deletions

View File

@ -208,6 +208,15 @@ Foam::cvControls::cvControls
motionDict.lookupOrDefault<Switch>("timeChecks", false)
);
if (Pstream::parRun())
{
maxLoadUnbalance_ = readScalar(motionDict.lookup("maxLoadUnbalance"));
}
else
{
maxLoadUnbalance_ = -1;
}
alignmentSearchSpokes_ = readLabel
(
motionDict.lookup("alignmentSearchSpokes")

View File

@ -179,6 +179,9 @@ class cvControls
//- Switch to control the reporting of detailed timeChecks
Switch timeChecks_;
//- Allowed relative load unbalance
scalar maxLoadUnbalance_;
//- Number of "spokes" to use to search for secondary alignment
// direction
label alignmentSearchSpokes_;
@ -356,6 +359,9 @@ public:
//- Return the timeChecks Switch
inline Switch timeChecks() const;
//- Return the maxLoadUnbalance
inline scalar maxLoadUnbalance() const;
//- Return the number of alignmentSearchSpokes to use
inline label alignmentSearchSpokes() const;

View File

@ -91,6 +91,12 @@ inline Foam::Switch Foam::cvControls::timeChecks() const
}
inline Foam::scalar Foam::cvControls::maxLoadUnbalance() const
{
return maxLoadUnbalance_;
}
inline Foam::label Foam::cvControls::alignmentSearchSpokes() const
{
return alignmentSearchSpokes_;