solve1d.py¶
neg_exp_H
¶
Negate, exponentiate and Heaviside clip.
Assumes the argument chi= \(\chi\) is the dimensionless distance from the erosion front, and dchi= \(\Delta\chi\) is the discrete spatial step size. Exponentiates \(-\chi H(\chi+\Delta\chi)\) where H=Heaviside function. When invoked in computing \(d{\eta}/d{\chi}\), adding \({\Delta}{\chi}\) means a non-clipped value is returned for the sample point just to the left (-ve \(\chi\)). Thus the \({\eta}\) gradient is estimated across the erosion front, where sample points span the moving origin, as well as for all points \(\chi\geq 0\).
Source code in wmbe/solve1d.py
erosionrate_steadystate_W
¶
Dimensionless steady-state speed of the erosion front \(\omega_s(W)\).
Source code in wmbe/solve1d.py
eta_chi_tau
¶
Weathering-driven weakness function.
Analytic solution for \(\eta(\chi,\tau)\) as a function of dimensionless distance (depth into the rock) \(\chi\) and time \(\tau\), and parameterized by weathering number \(W\), assuming an exponential-decay model for weathering.
Source code in wmbe/solve1d.py
NumericalModel
¶
Numerical solution of \(\eta(\chi,\tau)\) and \(\varphi(\tau)\) evolution.
Class that provides a finite-difference method for solving the $(\chi,\tau) evolution of a weakness profile \(\eta(\chi,\tau)\) and its eroding surface position \(\varphi(\tau)\) as 2d array \(\eta_i^j\) and 1d vector \(\varphi^j\) respectively, and that provides dictionaries for the model and its numerical solution parameters.
Attributes:
-
parameters–obj:
dict) : model parameters dictionary, extended during & after instantiation -
model_parameters–obj:
dict) : numerical method parameters dictionary -
chi_domain_size–obj:
float):
length of chi solution domain (extracted from model_parameters) -
Delta_chi–obj:
float):
spacing between discrete chi solution points (extracted from model_parameters) -
n_chi_domain–obj:
int):
number of solution points in distance chi (extracted from model_parameters) -
tau_domain_size–obj:
float):
maximum duration of solution (truncated if/when front exits chi domain) (extracted from model_parameters) -
tau_n_steps–obj:
int):
number of solution points in time \(\tau\) -
Delta_tau–obj:
float):
spacing between discrete tau solution points -
chi_array–class:
numpy.ndarray) : discrete distances \(\chi_i\) -
tau_array–class:
numpy.ndarray) : discrete times \(\tau^j\) -
eta_array–class:
numpy.ndarray) : discretized weakness profile \(\eta_i^j\) -
phi_array–class:
numpy.ndarray) : discrete (in time) series of erosion front positions \(\phi^j\) (smoothly resolved as floats) -
nu_array() –class:
numpy.ndarray) :
discrete (in time) series of dimensionless erosion rates \(\nu^j\) -
j–obj:
int) :
final time step index \(j\) -
W–obj:
float) : weathering number \(W\) -
nu_s–obj:
float) : predicted (by analytical solution) dimensionless steady-state erosion rate \(\nu_s\) -
v_s–obj:
float) : predicted (by analytical solution) steady-state erosion rate \(v_s\)
-
Python package
VizSimulations
Methods:
-
solve–Use an explicit finite-difference scheme to solve for evolution of a
Source code in wmbe/solve1d.py
solve
¶
Use an explicit finite-difference scheme to solve for evolution of a weakness profile \(\eta_i^j\) and its eroding surface position \(\phi^j\).