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

Functions

 n_to_diameter_nm (n)
 
 diameter_nm_to_n (d_nm)
 
 run_single (name, overrides, I=I_SWEEP, V=V_SWEEP)
 

Variables

 MODULE_ROOT = Path(__file__).resolve().parent.parent.parent
 
 REPO_ROOT = MODULE_ROOT.parent
 
float Omega = 1.18e-29
 
float b_111 = 2.482e-10
 
int I_SWEEP = 3000
 
int V_SWEEP = 3000
 
dict SOLVER_CONFIG
 
dict BASE_PARAMS
 
dict RUNS
 
list all_results = []
 
 t0_total = time.time()
 
 flush
 
 t0 = time.time()
 
 res = run_single(name, overrides)
 
 elapsed = time.time() - t0
 
float in_target = 5.0
 
str marker = ' *** IN TARGET ***' if in_target else ''
 
 total_time = time.time() - t0_total
 
float target_d = 3.5
 
 key
 
str in_t = 5.0 else 'no'
 
list best = all_results[0]
 
dict base_v = BASE_PARAMS.get(k)
 
str out_path = Path(__file__).parent / 'param_sweep_results.json'
 
list serializable = []
 
 sr = dict(r)
 
 f
 
 indent
 

Detailed Description

Parameter sweep for RadCluster_2_1
========================================
Objective: find input parameter sets that produce SIA loop size distribution
peak at 2-5 nm diameter by 0.1 dpa.

Diameter formula:  d_nm = 2 * sqrt(n * Omega / (pi * b_111)) * 1e9
  -> d=2 nm => n ~ 66,  d=5 nm => n ~ 413,  d=3 nm => n ~ 149

Strategy: vary the most influential parameters within physical ranges,
run the C++ active_window solver, extract the SIA peak location at
the time step closest to 0.1 dpa.

Function Documentation

◆ diameter_nm_to_n()

param_sweep.diameter_nm_to_n (   d_nm)
Loop diameter in nm -> SIA cluster size n.

Definition at line 51 of file param_sweep.py.

◆ n_to_diameter_nm()

param_sweep.n_to_diameter_nm (   n)
SIA cluster size -> loop diameter in nm.

Definition at line 47 of file param_sweep.py.

◆ run_single()

param_sweep.run_single (   name,
  overrides,
  I = I_SWEEP,
  V = V_SWEEP 
)
Run one simulation and return the SIA peak info at ~0.1 dpa.

Definition at line 138 of file param_sweep.py.

Variable Documentation

◆ all_results

list param_sweep.all_results = []

Definition at line 288 of file param_sweep.py.

◆ b_111

float param_sweep.b_111 = 2.482e-10

Definition at line 45 of file param_sweep.py.

◆ BASE_PARAMS

dict param_sweep.BASE_PARAMS
Initial value:
1= {
2 'eta': 0.3,
3 'f_cl_i': 0.3,
4 'f_cl_v': 0.25,
5 'E_m_1D': 0.4,
6 'i_mobile': 10,
7 'L_hat': 71.8,
8 'c_C': 1.94e-4,
9 'E_b_C_SIA': 0.65,
10 'rho_d': 1e13,
11 'Z_i': 1.05,
12 'Z_ii': 1.2,
13 'shape_function': 'linear',
14}

Definition at line 77 of file param_sweep.py.

◆ base_v

dict param_sweep.base_v = BASE_PARAMS.get(k)

Definition at line 352 of file param_sweep.py.

◆ best

list param_sweep.best = all_results[0]

Definition at line 341 of file param_sweep.py.

◆ elapsed

param_sweep.elapsed = time.time() - t0

Definition at line 305 of file param_sweep.py.

◆ f

param_sweep.f

Definition at line 381 of file param_sweep.py.

◆ flush

param_sweep.flush

Definition at line 292 of file param_sweep.py.

◆ I_SWEEP

int param_sweep.I_SWEEP = 3000

Definition at line 59 of file param_sweep.py.

◆ in_t

str param_sweep.in_t = 5.0 else 'no'

Definition at line 333 of file param_sweep.py.

◆ in_target

float param_sweep.in_target = 5.0

Definition at line 309 of file param_sweep.py.

◆ indent

param_sweep.indent

Definition at line 381 of file param_sweep.py.

◆ key

param_sweep.key

Definition at line 327 of file param_sweep.py.

◆ marker

str param_sweep.marker = ' *** IN TARGET ***' if in_target else ''

Definition at line 310 of file param_sweep.py.

◆ MODULE_ROOT

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

Definition at line 21 of file param_sweep.py.

◆ Omega

float param_sweep.Omega = 1.18e-29

Definition at line 44 of file param_sweep.py.

◆ out_path

str param_sweep.out_path = Path(__file__).parent / 'param_sweep_results.json'

Definition at line 364 of file param_sweep.py.

◆ REPO_ROOT

param_sweep.REPO_ROOT = MODULE_ROOT.parent

Definition at line 22 of file param_sweep.py.

◆ res

param_sweep.res = run_single(name, overrides)

Definition at line 301 of file param_sweep.py.

◆ RUNS

dict param_sweep.RUNS

Definition at line 102 of file param_sweep.py.

◆ serializable

param_sweep.serializable = []

Definition at line 365 of file param_sweep.py.

◆ SOLVER_CONFIG

dict param_sweep.SOLVER_CONFIG
Initial value:
1= {
2 't_span': (1e-6, 1e5), # reach 0.1 dpa
3 'n_points': 100, # fewer points for speed
4 'log_time': True,
5 'rtol': 1e-5, # slightly relaxed for speed
6 'atol': 1e-20,
7 'solver_method': {
8 'linsol': 'gmres',
9 'window_width': 50,
10 'concentration_threshold': 1e-18,
11 'window_pad': 10,
12 }
13}

Definition at line 62 of file param_sweep.py.

◆ sr

param_sweep.sr = dict(r)

Definition at line 367 of file param_sweep.py.

◆ t0

param_sweep.t0 = time.time()

Definition at line 299 of file param_sweep.py.

◆ t0_total

param_sweep.t0_total = time.time()

Definition at line 289 of file param_sweep.py.

◆ target_d

float param_sweep.target_d = 3.5

Definition at line 326 of file param_sweep.py.

◆ total_time

param_sweep.total_time = time.time() - t0_total

Definition at line 320 of file param_sweep.py.

◆ V_SWEEP

int param_sweep.V_SWEEP = 3000

Definition at line 60 of file param_sweep.py.