Skip to content

Commit

Permalink
Merge pull request #6931 from KratosMultiphysics/adding-pressure-smoo…
Browse files Browse the repository at this point in the history
…thing-pfem-femdem

[FEMDEM App] Adding pressure time smoothing
  • Loading branch information
AlejandroCornejo authored May 25, 2020
2 parents 2674aa7 + 6812db2 commit a97c295
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,11 @@ void UpdatePressureValuePfemConditionsProcess<TDim>::Execute()

for (unsigned int i = 0; i < r_geometry.PointsNumber(); i++) {
const auto &r_node = r_geometry[i];
const double nodal_pressure = r_node.FastGetSolutionStepValue(PRESSURE);
average_pressure += nodal_pressure;

const double nodal_pressure = r_node.FastGetSolutionStepValue(PRESSURE);
const double nodal_pressure_old = r_node.FastGetSolutionStepValue(PRESSURE, 1);
const double alpha = 0.6;
average_pressure += alpha * nodal_pressure + (1.0 - alpha) * nodal_pressure_old;
}
average_pressure /= r_geometry.PointsNumber();
it_cond->SetValue(POSITIVE_FACE_PRESSURE, average_pressure);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ def __init__(self, Model, PFEMparameters):
initial_relaxation = 0.825
else:
max_relaxation = 0.9
min_relaxation = 0.1
min_relaxation = 0.7
initial_relaxation = 0.825
self.aitken_max_iterations = 30
self.aitken_max_iterations = 10
self.aitken_residual_dof_tolerance = 1e-5

self.FSI_aitken_utility = FEMDEM.AitkenRelaxationFEMDEMUtility(initial_relaxation, max_relaxation, min_relaxation)
Expand Down

0 comments on commit a97c295

Please sign in to comment.