|
RadCluster
Graph-based cluster dynamics for irradiated materials
|
The GraphWalker in graph_walker.py assembles the right-hand side of the master equation by walking a Reaction Admissibility Graph edge by edge. For every admissible edge it evaluates the reaction flux \(J_r\) from the rate kernel of the edge, and it deposits the signed stoichiometric contribution \(S_{ar} J_r\) into the affected entries of the flat ODE state vector that the State layout defines.
The walker carries no host parameters. It dispatches only on the class of each edge (see Edge classes), with one contribution routine per class.
The Python graph walker is a reference discrete accumulator, with one ODE per size. It has two roles:
Production runs do not integrate with the Python walker. They use the C++ solver (see C++ solver), whose EUROFER-97 kernels are in radcluster_code/cpp_utils/materials/eurofer97/rate_kernels.cpp.
New physics is developed in the graph walker first. It is mirrored in C++ after it passes the conservation gate (see Verification and diagnostics).
Note that the two-dimensional coalescence and annihilation kernels are of size \(O(I^2)\). They are registered as lazy builders, so that they are materialized only when the Python walker evaluates the edge, and never on a C++ run.