cngf-pf

continuum model for granular flows with pore-pressure dynamics (renamed from 1d_fd_simple_shear)
git clone git://src.adamsgaard.dk/cngf-pf # fast
git clone https://src.adamsgaard.dk/cngf-pf.git # slow
Log | Files | Refs | README | LICENSE Back to index

commit 98e82ec48621114493aa95f533f2a82c56581739
parent cd1860a031d74199c9308ee12bee5dea8572f7be
Author: Anders Damsgaard <anders@adamsgaard.dk>
Date:   Tue,  9 Mar 2021 15:24:14 +0100

fluid.c: add comment on underrelaxation parameter

Diffstat:
Mfluid.c | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/fluid.c b/fluid.c @@ -179,6 +179,9 @@ darcy_solver_1d(struct simulation *sim, * epsilon = 0.5: Crank-Nicolson * epsilon = 1.0: implicit */ epsilon = 0.5; + + /* underrelaxation parameter in ]0.0; 1.0], + * where omega = 1.0: no underrelaxation */ omega = 1e-4; for (i = 0; i < sim->nz; ++i) @@ -301,6 +304,7 @@ darcy_solver_1d(struct simulation *sim, + (1.0 - epsilon) * sim->p_f_dot_expl[i]; set_fluid_bcs(sim->p_f_ghost, sim, p_f_top); + for (i = 0; i < sim->nz; ++i) sim->p_f_dot[i] = omega * sim->p_f_dot[i] + (1.0 - omega) * sim->p_f_dot_old[i];