亲爱的研友该休息了!由于当前在线用户较少,发布求助请尽量完整地填写文献信息,科研通机器人24小时在线,伴您度过漫漫科研夜!身体可是革命的本钱,早点休息,好梦!

Collective dynamics of trail-interacting particles

统计物理学 物理 粒子系统 经典力学 联轴节(管道) 动力学(音乐) 粒子(生态学) 集体行为 瞬态(计算机编程) 粒子动力学 渲染(计算机图形) 复杂系统 现象学(哲学) 随机动力学 颗粒密度 聚类分析 集体运动 随机过程 相互作用粒子系统 耦合强度 时间演化
作者
Paul Pineau,Samuel Bell,Raphaël Voituriez,Ram M. Adar
出处
期刊:Physical review [American Physical Society]
卷期号:114 (4)
标识
DOI:10.1103/1rfx-w3rw
摘要

Collective Dynamics of Trail-Interacting Particles This repository accompanies the paper on the collective dynamics of trail-interacting particles. It contains the simulation code (Julia), analytical derivations (Mathematica), and plotting notebooks (Python/Jupyter) needed to reproduce the results. Repository Structure /├── Julia_DRWs/ # 1D simulations│ ├── DRWsEngine.jl # Core engine: data structures, Gillespie stepper│ ├── Trajectories.jl # Mid-level routines: observables, I/O│ ├── Launching_functions.jl # High-level launchers (steady states, DSF, …)│ └── Launching_file.jl # Entry point — edit parameters and run this│├── 2d_Julia_DRWs/ # 2D simulations (L×L periodic grid)│ ├── 2d_DRWsEngine.jl # Core engine for the 2D model│ ├── 2d_Trajectories.jl # Mid-level routines for 2D│ ├── 2d_Launching_functions.jl # High-level launchers for 2D│ ├── 2d_Launching_file.jl # Entry point for 2D│ └── Launch.sh # SLURM batch script (HPC cluster)│├── Collective_dynamics_of_trail_interacting_particles.nb # Mathematica notebook for the caclulations done in the paper└── Notebook_plots_article.ipynb # Python notebook — figures for the paper Physical Model Particles perform continuous-time random walks on a periodic 1D chain (or 2D square lattice) of $N$ sites. Each particle leaves a *trail* (local time / deposition count $\phi_i$) that biases the jump rates of all particles. The jump rate from site $i$ to a neighbouring site $j$ is: $$r(i \to j) = 2 \, k_\text{tr} \, \frac{w(j)}{w(i) + w(j)}, \qquad w(n) = e^{-h \, n}$$ where $n$ is the local trail depth and $h$ is the **interaction strength**: | Sign of $h$ | Interpretation | BE CAREFUL, THE SIGN OF $h$ IS THE OPPOSITE IN THE MAIN TEXT.|-------------|----------------|| $h < 0$ | Repulsive trails — particles avoid previously visited sites || $h > 0$ | Attractive trails — particles are drawn to previously visited sites | > **Note:** the sign convention of $h$ in the code is the **opposite** of the one used in the paper. Set `h = -0.1` in the code to match $h = +0.1$ in the paper. In addition to hopping, each particle deposits at rate $k_d$, incrementing $\phi_i$ by 1. Events are selected with a Gillespie (continuous-time Monte Carlo) algorithm accelerated by a waypoint / row-waypoint data structure that reduces the event-selection cost to $O(\sqrt{N_\text{sites}})$ per step. Prerequisites ### Julia (≥ 1.9) Install the required packages once: ```juliausing PkgPkg.add(["Random", "FFTW", "LinearAlgebra", "CSV", "DataFrames", "NPZ", "BenchmarkTools", "ThreadsX", "Dates", "Printf"])``` ### Python (for the plotting notebook) ```bashpip install numpy matplotlib scipy pandas jupyter``` Quick Start 1D simulations Open `Julia_DRWs/Launching_file.jl`, adjust the parameters at the top: ```juliaNsites = 256 # Number of lattice sitesh = -0.1 # Interaction strength (h < 0 ↔ repulsive; note sign convention above)ktr = 1.0 # Hopping ratekd = 1.0 # Deposition raterho0 = 1.0 # Mean particle densityNsims = 100 # Number of independent realisations``` Then run from the terminal: ```bashjulia Julia_DRWs/Launching_file.jl``` Uncomment the desired launcher call to choose the workflow. 2D simulations Same workflow with `2d_Julia_DRWs/2d_Launching_file.jl`. The grid size is controlled by parameter `L` (total sites = $L^2$). ```bashjulia 2d_Julia_DRWs/2d_Launching_file.jl``` ### HPC cluster (SLURM) `2d_Julia_DRWs/Launch.sh` is a ready-made SLURM array job script. Adjust the partition and memory settings to match your cluster, then submit with: ```bashsbatch 2d_Julia_DRWs/Launch.sh``` --- ## Available Workflows | Function | Description ||---|---|| `Generate_Steady_State_h_negative` | Run until the repulsive ($h<0$) steady state is reached and save density + local time || `Launch_GeneratePermanentState_h_positive` | Find the permanent (frozen) state for attractive trails ($h>0$) || `Launch_DSF` | Compute the **dynamic structure factor** $S(q,\omega)$ from previously saved steady-state snapshots || `Launch_Snapped_SF` | Record the structure factor $S(q)$ at regular step intervals (time-resolved) || `Launch_Snapped_SF_Poisson` | Same as above but starting from a Poisson-distributed initial condition || `make_trajectories_from_given_density` | Generate full particle trajectories for visualisation / videos | All output data are saved automatically in organised subdirectories under the folder from which the script is run, following the naming convention: ``` / /From /h= /ktr= _kd= /rho= _Nsites= _nsim= /``` --- ## Output Format Results are written as CSV files (via `CSV.jl` / `DataFrames.jl`) and `.npy` arrays (via `NPZ.jl`): | File | Content ||---|---|| `density.csv` | Particle density field $\rho_i$ for each simulation || `local_time.csv` | Trail field $\phi_i$ for each simulation || `time.csv` | Physical time reached at the end of each run || `Sqw.csv` | Dynamic structure factor $S(q,\omega)$ || `SF_rho.csv` / `SF_phi.csv` | Static structure factors of $\rho$ and $\phi$ | Mathematica Notebook Wolfram Mathematica ≥ 14 is required to open and evaluate the `.nb` file. `Collective_dynamics_of_trail_interacting_particles.nb` derives analytical results presented in the paper, including: - The Green function of the linearised hydrodynamic equation - The density and trail structure factor $S(q)$ - The scaling solution in 2d Plotting Notebook `Notebook_plots_article.ipynb` loads the simulation data and reproduces the figures in the paper. Citation If you use this code, please cite: > *Collective Dynamics of Trail-Interacting Particles*, (authors), (journal), (year). DOI: ... License This project is released under the Creative Commons Attribution 4.0 International License
最长约 10秒,即可获得该文献文件

科研通智能强力驱动
Strongly Powered by AbleSci AI
科研通是完全免费的文献互助平台,具备全网最快的应助速度,最高的求助完成率。 对每一个文献求助,科研通都将尽心尽力,给求助人一个满意的交代。
实时播报
蒋紫妍发布了新的文献求助10
1秒前
义气春天完成签到,获得积分10
6秒前
ahh完成签到 ,获得积分10
9秒前
畅快的夜云完成签到,获得积分10
36秒前
渡人舟的应助被科研通管家采纳,获得10
39秒前
39秒前
炙热的凡霜完成签到,获得积分10
42秒前
1分钟前
kiko发布了新的文献求助10
1分钟前
优雅谷蕊完成签到,获得积分10
1分钟前
老石完成签到 ,获得积分10
1分钟前
爱听歌未来完成签到,获得积分10
1分钟前
null的应助被vvan采纳,获得10
1分钟前
Yvonne1229完成签到,获得积分10
2分钟前
土豪的城完成签到,获得积分10
2分钟前
2分钟前
隐形骁完成签到,获得积分10
2分钟前
沉默的樱完成签到,获得积分10
2分钟前
渡人舟的应助被科研通管家采纳,获得10
2分钟前
Lucas的应助被科研通管家采纳,获得10
2分钟前
渡人舟的应助被科研通管家采纳,获得10
2分钟前
Orange的应助被自定义采纳,获得10
3分钟前
3分钟前
高高的夏波完成签到,获得积分10
3分钟前
快乐舒完成签到 ,获得积分10
3分钟前
研友_LMo56Z完成签到,获得积分10
3分钟前
如意紫翠完成签到,获得积分10
3分钟前
单纯的小土豆完成签到 ,获得积分0
3分钟前
SciGPT的应助被jackone采纳,获得10
3分钟前
跳跃的咖啡豆完成签到,获得积分10
3分钟前
机灵自中完成签到,获得积分10
4分钟前
4分钟前
4分钟前
MchemG完成签到,获得积分0
4分钟前
oleskarabach发布了新的文献求助10
4分钟前
自定义发布了新的文献求助10
4分钟前
一个小胖子完成签到,获得积分10
4分钟前
天真的音完成签到,获得积分10
4分钟前
4分钟前
渡人舟的应助被科研通管家采纳,获得10
4分钟前
高分求助中
(应助此贴封号)【重要!!请各用户(尤其是新用户)详细阅读】【科研通的精品贴汇总】 10000
Campbell's Operative Orthopaedics, E-Book 3000
Les Mantodea De Guyane 2000
Energie-Contracting 1500
内視鏡下経鼻経蝶形骨洞手術術後SIADHに対する予防的水制限の安全性と有効性の検討 1000
Guidelines for fracture-safe and fatigue-reliable design of steel structures 600
Problems and Solutions for Integer and Combinatorial Optimization: Building Skills in Discrete Optimization 600
热门求助领域 (近24小时)
化学 材料科学 医学 生物 纳米技术 计算机科学 工程类 有机化学 化学工程 生物化学 物理 复合材料 内科学 催化作用 光电子学 人工智能 细胞生物学 无机化学 物理化学 数学
热门帖子
关注 科研通微信公众号,转发送积分 8013725
求助须知:如何正确求助?哪些是违规求助? 9460662
关于积分的说明 21182956
捐赠科研通 7585092
什么是DOI,文献DOI怎么找? 3384303
关于科研通互助平台的介绍 2517206
邀请新用户注册赠送积分活动 2419606