Source-linked AI summary
Numba-Accelerated 2D Diffusion-Limited Aggregation: Implementation and Fractal Characterization
Sandy H. S. Herho, Faiz R. Fajary, Iwan P. Anwar, Faruq Khadami, Nurjanna J. Trilaksono, Rusmawan Suwarman, Dasapta E. Irawan
TL;DR
Large-scale DLA simulation requires high throughput without sacrificing flexibility. The paper uses JIT-compiled Python to study injection geometries and walker densities, finding standard scaling near Df = 1.71 in dilute cases but a high-density crossover to compact growth at Df = 1.8697 ± 0.0554.
Problem
Large DLA ensembles face a tradeoff between the flexibility of high-level scientific computing and the throughput needed for statistical convergence.
Method
The study combines a lattice random-walk DLA model with JIT-compiled Python simulations and mass-radius, generalized-dimension, and lacunarity analyses.
Results
Df = 1.7105 ± 0.0801 for classic DLA, while high density yields Df = 1.8697 ± 0.0554 and compact Eden-like growth.
Takeaways & Limitations
DLA scaling is robust across dilute injection modes but shifts toward a compact, approximately monofractal regime when walker density is high.
Takeaways & Limitations
The model assumes instantaneous sticking, corresponding to an infinite surface reaction rate characteristic of transport-limited growth.
Abstract
from arXiv · showhide
We present dla-ideal-solver, a high-performance framework for simulating two-dimensional Diffusion-Limited Aggregation (DLA) using Numba-accelerated Python. By leveraging just-in-time (JIT) compilation, we achieve computational throughput comparable to legacy static implementations while retaining high-level flexibility. We investigate the Laplacian growth instability across varying injection geometries and walker concentrations. Our analysis confirms the robustness of the standard fractal dimension $D_f \approx 1.71$ for dilute regimes, consistent with the Witten-Sander universality class. However, we report a distinct crossover to Eden-like compact growth ($D_f \approx 1.87$) in high-density environments, attributed to the saturation of the screening length. Beyond standard mass-radius scaling, we employ generalized Rényi dimensions and lacunarity metrics to quantify the monofractal character and spatial heterogeneity of the aggregates. This work establishes a reproducible, open-source testbed for exploring phase transitions in non-equilibrium statistical mechanics.
1 Introduction
The section frames DLA as a non-equilibrium Laplacian-growth problem whose large-ensemble study is computationally demanding. It introduces Numba JIT compilation as a Python-based solution achieving speeds comparable to legacy Fortran or C solvers while enabling structural analysis beyond mass-radius scaling.
- Introduction: DLA is governed by nonlocal screening of the harmonic measure rather than local surface tension and attachment kinetics.Incoming random-walker flux concentrates at aggregate tips as the structure expands.
- Introduction: Large-N ensemble studies are needed to overcome finite-size transients, but tracking millions of stochastic trajectories historically required rigid Fortran or C implementations.High-level dynamic ecosystems retain prohibitive interpretative overhead in the core random-walk loop.
- Introduction: Numba JIT compilation via LLVM-based architecture resolves the performance bottleneck by compiling stochastic trajectory logic into optimized machine code at runtime.The implementation achieves execution speeds comparable to legacy Fortran or C solvers without leaving Python.
- Introduction: The implementation supports probing DLA structural limits beyond simple mass-radius scaling.The paper specifically uses the framework to analyze the breakdown of scale invariance.
2 Methods
The methods formulate two-dimensional DLA as irreversible walker deposition on a square lattice, connect the random walk to continuum diffusion, and implement simulations with Numba acceleration, reinjection, configurable injection geometries, and fractal characterization.
- Model formulation: DLA is modeled on an N × N square lattice where unbiased walkers sequentially deposit irreversibly upon contacting the existing aggregate.Each lattice site is empty, mobile, or occupied by an immobile aggregate particle.
- Model formulation: The discrete isotropic random walk converges to the diffusion equation as a →0 and ∆t →0 with D = a2/(4∆t) fixed.This establishes diffusion-limited transport toward the aggregate surface.
- Fractal characterization: Fractal dimension Df is obtained as the slope of log M(Rk) versus log Rk over logarithmically spaced radii, excluding points with M(Rk) < 10.The analyzed range spans Rmin ≈3 lattice units to Rmax = 0.8 × min(N/2, rgyration).
- Numerical implementation: Numba JIT compilation accelerates the inner random-walk loop by approximately two orders of magnitude relative to pure Python while retaining a Python interface.The dla-ideal-solver library provides command-line and Python APIs, with multiprocessing used for parallel animation rendering.
- Numerical implementation: Walkers exceeding τmax = 2N steps are re-injected near the aggregate boundary to reduce computation spent on particles that contribute negligibly to growth.The threshold is tied to the characteristic diffusion time and scales linearly with lattice dimension.
- Injection geometries: The simulation supports uniform random injection and radial injection on a circle of radius Rinj centered at rc = (N/2, N/2), with radial injection producing more isotropic growth.Radial positions are sampled using a uniformly distributed angle θ ∈[0, 2π).
3 Results and Discussion
The results validate standard DLA scaling in dilute configurations while revealing more compact, still self-similar growth at high walker density. Generalized dimensions and lacunarity further characterize the aggregates as approximately monofractal with scale-dependent heterogeneity.
- Morphology: Nw = 25,000 walkers produce a compact high-density aggregate with Rmax = 148.39 and compactness C = 0.29.The denser structure is attributed to simultaneous approaches that partially fill fjords.
- Fractal dimension: Df = 1.8697 ± 0.0554 in the high density case exceeds the theoretical Df = 1.71 by 0.16, indicating a crossover toward more compact growth.The passage attributes this shift to reduced screening effectiveness as walker concentration increases; R2 = 0.9950 and z-score = 8.12.
- Lacunarity: Λ ∼10 at small scales decreases to Λ ∼1 at large scales for single-aggregate cases, reflecting hierarchical branching and increasing coarse-scale homogeneity.The multiple-seeds case has dramatically lower lacunarity at large scales.
- Generalized dimensions: D0 = 1.665 ± 0.031 and D1 = 1.758 ± 0.029 for classic DLA, while radial injection gives D0 = 1.634 ± 0.028 and D1 = 1.743 ± 0.023.These values bracket Df ≈ 1.71, consistent with monofractal structures satisfying D0 ≤ D1 ≤ D2.
- Generalized dimensions: D0 = 1.792, D1 = 1.840, and D2 = 1.865 in the high density case remain closely ordered, confirming monofractal scaling despite more compact morphology.The multiple-seeds case instead shows suppressed dimensions because box counting measures the effective cluster distribution.
4 Conclusion
The study demonstrates that JIT-compiled Python enables high-throughput stochastic simulations with legacy-comparable convergence and confirms standard DLA scaling while identifying high-density deviations.
- Implementation: JIT-compiled Python achieves high-throughput stochastic simulations with statistical convergence comparable to legacy implementations while preserving codebase flexibility.The framework combines performance with flexibility for stochastic simulation.
- Fractal characterization: Df ≈1.71 remains robust under radial and point-source injection, consistent with the standard DLA universality class.The result supports the expected universality-class behavior across both injection geometries.
- Fractal characterization: Df →1.87 in the high-density regime cautions against the limits of the discrete-walker approximation.The observed deviation marks a regime where standard discrete-walker assumptions become less reliable.