Merge remote-tracking branch 'origin/master' into develop
This commit is contained in:
commit
8534983b0a
@ -175,9 +175,6 @@ void optimisationType::update()
|
||||
|
||||
void optimisationType::update(scalarField& direction)
|
||||
{
|
||||
// Compute eta if needed
|
||||
computeEta(direction);
|
||||
|
||||
// Multiply with line search step, if necessary
|
||||
scalarField correction(direction);
|
||||
if (lineSearch_)
|
||||
@ -218,6 +215,9 @@ tmp<scalarField> optimisationType::computeDirection()
|
||||
scalarField& correction = tcorrection.ref();
|
||||
correction = updateMethod_->returnCorrection();
|
||||
|
||||
// Compute eta if needed
|
||||
computeEta(correction);
|
||||
|
||||
return tcorrection;
|
||||
}
|
||||
|
||||
|
@ -376,7 +376,7 @@ Foam::scalar Foam::updateMethod::computeMeritFunction()
|
||||
|
||||
Foam::scalar Foam::updateMethod::meritFunctionDirectionalDerivative()
|
||||
{
|
||||
return sum(objectiveDerivatives_*correction_);
|
||||
return globalSum(objectiveDerivatives_*correction_);
|
||||
}
|
||||
|
||||
|
||||
|
@ -1828,31 +1828,28 @@ void Foam::NURBS3DVolume::writeCps
|
||||
|
||||
void Foam::NURBS3DVolume::writeCpsInDict() const
|
||||
{
|
||||
if (Pstream::master())
|
||||
{
|
||||
IOdictionary cpsDict
|
||||
IOdictionary cpsDict
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
IOobject
|
||||
(
|
||||
name_ + "cpsBsplines" + mesh_.time().timeName(),
|
||||
mesh_.time().caseConstant(),
|
||||
cpsFolder_,
|
||||
mesh_,
|
||||
IOobject::NO_READ,
|
||||
IOobject::NO_WRITE,
|
||||
false
|
||||
)
|
||||
);
|
||||
name_ + "cpsBsplines" + mesh_.time().timeName(),
|
||||
mesh_.time().caseConstant(),
|
||||
cpsFolder_,
|
||||
mesh_,
|
||||
IOobject::NO_READ,
|
||||
IOobject::NO_WRITE,
|
||||
false
|
||||
)
|
||||
);
|
||||
|
||||
cpsDict.add("controlPoints", cps_);
|
||||
cpsDict.add("controlPoints", cps_);
|
||||
|
||||
// Always write in ASCII, but allow compression
|
||||
cpsDict.regIOobject::writeObject
|
||||
(
|
||||
IOstreamOption(IOstream::ASCII, mesh_.time().writeCompression()),
|
||||
true
|
||||
);
|
||||
}
|
||||
// Always write in ASCII, but allow compression
|
||||
cpsDict.regIOobject::writeObject
|
||||
(
|
||||
IOstreamOption(IOstream::ASCII, mesh_.time().writeCompression()),
|
||||
true
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user