RadCluster
Graph-based cluster dynamics for irradiated materials
Loading...
Searching...
No Matches
Functions | Variables
mobility_sweep Namespace Reference

Functions

 run_case (name, overrides, quiet=True, heartbeat_every=1.5)
 
 write_summary_csv (cases, out_dir)
 
 plot_time_series (cases, out_dir)
 
 plot_size_distributions (cases, out_dir)
 
 main ()
 

Variables

 MODULE_ROOT = Path(__file__).resolve().parent.parent.parent
 
 REPO_ROOT = MODULE_ROOT.parent
 
 I_SIM
 
 V_SIM
 
float DOSE_SNAPSHOT = 0.01
 
dict SOLVER_CONFIG
 
list CASES
 

Detailed Description

mobility_sweep.py — diagnostic sweep of SIA / vacancy mobility cutoffs.

Hypothesis under test
---------------------
With the current input (n_max_i=50, m_max_v=5, L_hat=50), mobile SIA
clusters of size 4–50 glide in 1D and are rapidly drained at fixed sinks
(dislocations, GBs, precipitates) and at voids — even when the 3D
coalescence diffusivity D_SIA_eff[n>=2] is zero.  Vacancy clusters lose
mobility at m=6 and become permanent sinks for the residual flux.  The
asymmetry should disappear (and may invert) when i_mobile is reduced
toward 1, when v_mobile is raised, or when L_hat is shortened.

Cases
-----
  A  baseline                   i_mobile=50, v_mobile=5,  L_hat=50
  B  di-SIA only                i_mobile=2,  v_mobile=5,  L_hat=50
  C  monomer-only SIA           i_mobile=1,  v_mobile=5,  L_hat=50
  D  symmetric mobility         i_mobile=50, v_mobile=20, L_hat=50
  E  mono-defect (reference)    i_mobile=1,  v_mobile=1,  L_hat=50
  F  short MFP (1D suppressed)  i_mobile=50, v_mobile=5,  L_hat=5

Output
------
  output/mobility_sweep_<timestamp>/
      summary.csv                — per-case scalars at 0.1 dpa
      mean_sizes_vs_dose.png     — mean_n_i, mean_n_v(t) for all cases
      swelling_vs_dose.png       — swelling(t) for all cases
      conservation_vs_dose.png   — delta_FP vs dose for all cases
      size_dist_at_0.1dpa.png    — c_n, c_m at 0.1 dpa, all cases

Function Documentation

◆ main()

mobility_sweep.main ( )

Definition at line 298 of file mobility_sweep.py.

◆ plot_size_distributions()

mobility_sweep.plot_size_distributions (   cases,
  out_dir 
)

Definition at line 276 of file mobility_sweep.py.

◆ plot_time_series()

mobility_sweep.plot_time_series (   cases,
  out_dir 
)

Definition at line 232 of file mobility_sweep.py.

◆ run_case()

mobility_sweep.run_case (   name,
  overrides,
  quiet = True,
  heartbeat_every = 1.5 
)
Run one case via active_window and return time-resolved results.

Per-row progress is forwarded to the *real* terminal even while the
inner solver's stdout is captured.  A line is printed at most once
every `heartbeat_every` seconds (wall-clock) plus always at the
final point, to avoid flooding while still confirming progress.

Definition at line 98 of file mobility_sweep.py.

◆ write_summary_csv()

mobility_sweep.write_summary_csv (   cases,
  out_dir 
)

Definition at line 204 of file mobility_sweep.py.

Variable Documentation

◆ CASES

list mobility_sweep.CASES
Initial value:
1= [
2 ('A_baseline', {'i_mobile': 50, 'v_mobile': 5, 'L_hat': 50.0}),
3 ('B_di_SIA', {'i_mobile': 2, 'v_mobile': 5, 'L_hat': 50.0}),
4 ('C_mono_SIA', {'i_mobile': 1, 'v_mobile': 5, 'L_hat': 50.0}),
5 ('D_symmetric', {'i_mobile': 50, 'v_mobile': 20, 'L_hat': 50.0}),
6 ('E_mono_defect', {'i_mobile': 1, 'v_mobile': 1, 'L_hat': 50.0}),
7 ('F_short_MFP', {'i_mobile': 50, 'v_mobile': 5, 'L_hat': 5.0}),
8]

Definition at line 88 of file mobility_sweep.py.

◆ DOSE_SNAPSHOT

float mobility_sweep.DOSE_SNAPSHOT = 0.01

Definition at line 73 of file mobility_sweep.py.

◆ I_SIM

mobility_sweep.I_SIM

Definition at line 68 of file mobility_sweep.py.

◆ MODULE_ROOT

mobility_sweep.MODULE_ROOT = Path(__file__).resolve().parent.parent.parent

Definition at line 42 of file mobility_sweep.py.

◆ REPO_ROOT

mobility_sweep.REPO_ROOT = MODULE_ROOT.parent

Definition at line 43 of file mobility_sweep.py.

◆ SOLVER_CONFIG

dict mobility_sweep.SOLVER_CONFIG
Initial value:
1= {
2 't_span': (1e-6, 1e4), # 1e4 s @ G=1e-6 dpa/s = 0.01 dpa
3 'n_points': 120,
4 'log_time': True,
5 'rtol': 1e-6,
6 'atol': 1e-22,
7 'solver_method': {
8 'linsol': 'gmres', # required for Woodbury auto-engage
9 # window_mode=0 (full_system) so Woodbury preconditioner kicks in
10 # whenever i_mobile>=2 or v_mobile>=2 (parameters.h:494-501)
11 },
12}

Definition at line 75 of file mobility_sweep.py.

◆ V_SIM

mobility_sweep.V_SIM

Definition at line 68 of file mobility_sweep.py.