Skip to content

Commit e3ba727

Browse files
add viscosity limit to rft
1 parent 3243e56 commit e3ba727

File tree

6 files changed

+83
-1
lines changed

6 files changed

+83
-1
lines changed
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Added: A parameter to the reactive fluid transport model that limits
2+
the amount of fluid weakening on the solid viscosity.
3+
<br>
4+
(Daniel Douglas, 2026/03/05)

include/aspect/material_model/reactive_fluid_transport.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ namespace aspect
164164
double shear_to_bulk_viscosity_ratio;
165165
double min_compaction_visc;
166166
double max_compaction_visc;
167+
double min_weakened_viscosity;
167168
double reference_permeability;
168169
double alpha_phi;
169170
double reference_T;

source/material_model/reactive_fluid_transport.cc

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,8 @@ namespace aspect
191191
for (unsigned int q=0; q<out.n_evaluation_points(); ++q)
192192
{
193193
const double porosity = std::max(in.composition[q][porosity_idx],0.0);
194-
out.viscosities[q] *= (1.0 - porosity) * std::exp(- alpha_phi * porosity);
194+
const double weakened_viscosity = out.viscosities[q] * (1.0 - porosity) * std::exp(- alpha_phi * porosity);
195+
out.viscosities[q] = std::max(weakened_viscosity, min_weakened_viscosity);
195196
}
196197
}
197198

@@ -377,6 +378,9 @@ namespace aspect
377378
boost::lexical_cast<std::string>(std::numeric_limits<double>::max()),
378379
Patterns::Double (0),
379380
"Upper cutoff for the compaction viscosity. Units: $\\text{Pa}\\text{s}$.");
381+
prm.declare_entry ("Minimum weakened viscosity", "1e17",
382+
Patterns::Double (0),
383+
"Lower cutoff for the viscosity of the solid phase in the presence of fluids. Units: $\\text{Pa}\\text{s}$.");
380384
prm.declare_entry ("Reference fluid viscosity", "10",
381385
Patterns::Double (0),
382386
"The value of the constant melt/fluid viscosity $\\eta_f$. Units: $\\text{Pa}\\text{s}$.");
@@ -448,6 +452,7 @@ namespace aspect
448452
shear_to_bulk_viscosity_ratio = prm.get_double ("Shear to bulk viscosity ratio");
449453
max_compaction_visc = prm.get_double ("Maximum compaction viscosity");
450454
min_compaction_visc = prm.get_double ("Minimum compaction viscosity");
455+
min_weakened_viscosity = prm.get_double ("Minimum weakened viscosity");
451456
eta_f = prm.get_double ("Reference fluid viscosity");
452457
reference_permeability = prm.get_double ("Reference permeability");
453458
alpha_phi = prm.get_double ("Exponential fluid weakening factor");
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# This model tests the minimum viscosity within the reactive fluid transport model
2+
# correctly stops the viscosity from decreasing below a threshold in the presence
3+
# of fluids. The model prescribes a porosity of 10 % and an exponential fluid
4+
# weakening factor of 30. Without a minimum value for the viscosity, this would
5+
# result in the material viscosity of 4.481e17 Pa s, which is below the minimum
6+
# value that is specified in the Visco Plastic base material model. By setting
7+
# the parameter Minimum weakened viscosity to 1e10 Pa s, we ensure that the viscosity
8+
# of the material does not drop below this value, even in the presence of fluids.
9+
include $ASPECT_SOURCE_DIR/tests/reactive_fluid_transport_zero_solubility.prm
10+
11+
set Output directory = reactive_fluid_transport_min_viscosity
12+
set End time = 0
13+
14+
# 10 % porosity initially.
15+
subsection Initial composition model
16+
set Model name = function
17+
18+
subsection Function
19+
set Function expression = 0.1; 0.0
20+
end
21+
end
22+
23+
subsection Material model
24+
subsection Reactive Fluid Transport Model
25+
set Exponential fluid weakening factor = 30
26+
set Minimum weakened viscosity = 1e19
27+
end
28+
end
29+
30+
subsection Postprocess
31+
set List of postprocessors = material statistics
32+
end
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
2+
Number of active cells: 1 (on 1 levels)
3+
Number of degrees of freedom: 74 (18+7+18+4+9+9+9)
4+
5+
*** Timestep 0: t=0 years, dt=0 years
6+
Solving temperature system... 0 iterations.
7+
Solving porosity system ... 0 iterations.
8+
Skipping bound_fluid composition solve because RHS is zero.
9+
Rebuilding Stokes preconditioner...
10+
Solving Stokes system (AMG)... 0+0 iterations.
11+
Solving fluid velocity system... 1 iterations.
12+
Relative nonlinear residuals (temperature, compositional fields, Stokes system): 1.3813e-16, 4.89778e-17, 0, 1.55195e-09
13+
Relative nonlinear residual (total system) after nonlinear iteration 1: 1.55195e-09
14+
15+
16+
Postprocessing:
17+
Average density / Average viscosity / Total mass: 3000 kg/m^3, 1e+19 Pa s, 1.2e+10 kg
18+
19+
Termination requested by criterion: end time
20+
21+
22+
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# 1: Time step number
2+
# 2: Time (years)
3+
# 3: Time step size (years)
4+
# 4: Number of mesh cells
5+
# 5: Number of Stokes degrees of freedom
6+
# 6: Number of temperature degrees of freedom
7+
# 7: Number of degrees of freedom for all compositions
8+
# 8: Number of nonlinear iterations
9+
# 9: Iterations for temperature solver
10+
# 10: Iterations for composition solver 1
11+
# 11: Iterations for composition solver 2
12+
# 12: Iterations for Stokes solver
13+
# 13: Velocity iterations in Stokes preconditioner
14+
# 14: Schur complement iterations in Stokes preconditioner
15+
# 15: Average density (kg/m^3)
16+
# 16: Average viscosity (Pa s)
17+
# 17: Total mass (kg)
18+
0 0.000000000000e+00 0.000000000000e+00 1 22 9 18 1 0 0 0 0 0 0 3.00000000e+03 1.00000000e+19 1.20000000e+10

0 commit comments

Comments
 (0)