How partha-debug/brownian_dynamics works
This is a Brownian-dynamics simulator for particles in a 2D harmonic trap, with optional WCA interactions and underdamped or overdamped integration. The main workflow runs the simulation, saves position and velocity trajectories, calculates MSD and (when WCA is enabled) RDF, then produces plots and an animation. The README also describes these outputs. Edges reflect calls and data transfers visible in the sampled source; unsampled behavior is not inferred.
Main entry points: main.py Simulation runner · dynamics.py Force calculation · analyzer.py MSD and RDF · visualizer.py Plots and animation
Components 10
Simulation
- Simulation config
config.py - Simulation runner
main.py - Force calculation
dynamics.py - Integrators
dynamics.py - Trajectories
Analysis
- MSD and RDF
analyzer.py - Analysis CSV
Visualization
- Plots and animation
visualizer.py - Figures and GIF
Other components
- User
Connections 11
- User → Simulation runner: runs
- Simulation runner → Simulation config: reads settings
- Simulation runner → Force calculation: computes forces
- Force calculation → Integrators
- Simulation runner → Integrators: advances particles
- Simulation runner → Trajectories: saves
- Simulation runner → MSD and RDF: passes trajectory
- MSD and RDF → Analysis CSV: writes results
- Simulation runner → Plots and animation: requests plots
- Simulation runner → Trajectories: passes to visualizer
- Plots and animation → Figures and GIF: writes