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/elasticOrthoAcpSolidFoam/calculateDivSigmaExp.H

26 lines
731 B
C
Raw Normal View History

if(divSigmaExpMethod == "standard")
{
//- calculating the full gradient has good convergence and no high freq oscillations
divSigmaExp = fvc::div(C && epsilon) - fvc::div(K & gradU);
}
else if(divSigmaExpMethod == "surface")
{
//- this form seems to have the best convergence
divSigmaExp =
fvc::div(mesh.magSf()*
(
(n&(Cf && fvc::interpolate(symm(gradU))))
- (n&(Kf & fvc::interpolate(gradU)))
)
);
}
else if(divSigmaExpMethod == "laplacian")
{
//- causes high freq oscillations and slow convergence
divSigmaExp = fvc::div(sigma) - fvc::laplacian(K,U);
}
else
{
FatalError << "divSigmaExp method " << divSigmaExpMethod << " not found!" << endl;
}