This repository has been archived on 2023-11-20. You can view files and clone it, but cannot push or open issues or pull requests.
foam-extend4.1-coherent-io/applications/solvers/solidMechanics/icoFsiElasticNonLinULSolidFoam/setInterfaceDisplacement.H

49 lines
1.2 KiB
C
Raw Normal View History

Info << "\nTime = " << runTime.timeName()
2012-09-11 15:42:55 +00:00
<< ", iteration: " << outerCorr << endl;
if (outerCorr < 3 || couplingScheme == "FixedRelaxation")
{
Info << "Current fsi under-relaxation factor: "
2012-09-11 15:42:55 +00:00
<< fsiRelaxationFactor << endl;
fluidPatchPointsDisplOld = fluidPatchPointsDispl;
fluidPatchPointsDispl += fsiRelaxationFactor*fsiResidual;
}
else
{
if (couplingScheme == "Aitken")
{
fsiRelaxationFactor =
2012-09-11 15:42:55 +00:00
-fsiRelaxationFactor
*(
gSum
(
fsiResidualOld
&(fsiResidual - fsiResidualOld)
)
/(
gSum
(
(fsiResidual - fsiResidualOld)
&(fsiResidual - fsiResidualOld)
)
)
);
fsiRelaxationFactor = mag(fsiRelaxationFactor);
Info << "Current fsi under-relaxation factor (Aitken): "
<< fsiRelaxationFactor << endl;
2012-09-11 15:42:55 +00:00
fluidPatchPointsDisplOld = fluidPatchPointsDispl;
fluidPatchPointsDispl +=
2012-09-11 15:42:55 +00:00
fsiRelaxationFactor*fsiResidual;
}
// else if (couplingScheme == "IQN-ILS")
// {
// }
}