Devlog #67 – Wave 47: Electrode Kinetics, Polymer Chain & Magnetic Domains

Wave 47 crosses three rich disciplines — electrochemistry, polymer physics, and magnetic materials — each demanding fundamentally different simulation approaches: rate equations, stochastic chain sampling, and lattice spin Monte Carlo. The result is three new double-canvas simulations for a platform total of 514 live simulations.

Wave 47 at a Glance

3
New simulations
6
HTML files (EN+UK)
514
Total simulations
2
Blog posts

Electrode Kinetics

Butler-Volmer equation, Tafel analysis, and animated cyclic voltammetry with exchange current density and transfer coefficient controls.

Launch →
🧬

Polymer Chain

Freely-jointed chain model with pivot Monte Carlo moves, Flory scaling across good/theta/poor solvent regimes, and Rg histogram accumulation.

Launch →
🧲

Magnetic Domains

2D Ising model with Metropolis Monte Carlo showing domain wall formation, Curie temperature transition, and animated B-H hysteresis loop.

Launch →

Electrode Kinetics — Butler-Volmer in Action

The rate at which an electrochemical reaction proceeds at an electrode surface is governed by the Butler-Volmer equation, which encodes two competing exponential processes — oxidation and reduction — each accelerated by the applied overpotential η:

j = j₀[exp(αFη/RT) − exp(−(1−α)Fη/RT)]

where j₀ is the exchange current density (the baseline current flowing in both directions at equilibrium), α is the transfer coefficient (asymmetry between forward and reverse activation energies), and η = E − Eeq is the overpotential.

Three Visualisation Modes

The right-hand canvas switches between three diagnostic plots that electrochemists routinely use:

The left-hand electrode animation shows ion particles drifting toward and away from the electrode surface, with electron-transfer events spawning at a rate proportional to the instantaneous |j|. At high anodic overpotential the animation swarms with outbound electron transfers; at cathodic potentials the direction reverses.

Five material presets cover hydrogen evolution on platinum (HER, fast j₀), oxygen reduction on platinum (ORR, sluggish), copper deposition, iron corrosion in acidic solution, and a generic slow reaction. Each loads experimentally-inspired j₀ and α values.

Polymer Chain — From Random Walks to Flory Scaling

The simplest polymer model is the freely-jointed chain (FJC): N segments of equal length b, each oriented isotropically. In the absence of excluded-volume interactions (the “theta solvent” limit) the chain statistics are identical to a random walk, giving root-mean-square end-to-end distance Ree = b√N and radius of gyration Rg = b√(N/6).

Once excluded-volume interactions are switched on (good solvent), the chain swells. Flory theory predicts the power-law scaling Rg ∝ Nν with ν ≈ 0.588 in three dimensions. In a poor solvent the chain collapses and ν = 1/3.

Pivot Monte Carlo

Pure thermal diffusion is extremely slow at sampling polymer configuration space. The simulator uses pivot moves: a random bond along the chain is chosen, and the entire sub-chain on one side is rotated by a random angle about that pivot. The Metropolis criterion accepts the new configuration based on the Boltzmann weight of the energy change. For solvent quality, the energy model biases toward Rg changes — penalising expansion in poor solvent and compression in good solvent.

The right-hand histogram accumulates Rg samples over thousands of accepted moves, overlaying a Gaussian fit in yellow. The Gaussian approximation is exact at theta conditions; it deviates measurably in good and poor solvent regimes, as the distribution acquires a non-Gaussian tail.

Five presets span biological and synthetic systems: a 60-segment DNA section (b=3.4 Å), a PEG hydrogel chain in good aqueous solvent, a polystyrene chain in THF (good solvent), an unfolded protein (theta approximation), and a polyethylene melt (poor, athermal).

Magnetic Domains — Ising Model & Hysteresis

Ferromagnetic materials below the Curie temperature Tc spontaneously magnetise, but the bulk sample may have zero net magnetisation because it is divided into Weiss domains — regions of aligned spins separated by domain walls. The 2D Ising model, exactly solved by Onsager in 1944, captures the essential physics:

H = −J ∑<ij> sisj − μH ∑i si

Each lattice site carries a spin s = ±1. Nearest neighbours interact with exchange coupling J > 0 (ferromagnetic). The Curie temperature is kBTc = 2J/ln(1+√2) ≈ 2.269J.

Real-Time Spin Lattice Rendering

The 80×60 spin lattice is rendered every frame using ImageData on a small off-screen canvas (80×60 pixels), then scaled to the full 480×300 display canvas via drawImage with imageSmoothingEnabled = false. This gives crisp pixel-art domain boundaries at negligible GPU cost. Up spins are indigo (#3f51b5); down spins are red (#e53935). Domain walls appear as sharp colour boundaries when T is well below Tc; they blur and fluctuate as T approaches Tc, and the entire lattice becomes a disordered salt-and-pepper pattern above Tc.

Animated B-H Loop

In Auto sweep mode the applied field H ramps linearly from −1 to +1 and back, recording (H, M) pairs at each step. The accumulated trace is drawn on the right-hand canvas: forward sweep in red, reverse in blue. The characteristic hysteresis loop emerges — its width reflects the coercive field Hc, its height the saturation magnetisation Ms, and its area the energy dissipated per cycle (Steinmetz’s law ∝ f Bmax1.6).

Five material presets capture the range from hard magnets (Cobalt, J=2.0, wide loop) to soft magnets (Permalloy, J=0.8, and soft ferrite, J=0.6, with narrow, nearly linear loops optimal for power transformers).

At temperatures above Tc the B-H loop collapses to a thin reversible line — the material is paramagnetic. Watch this transition live by raising the temperature slider past the T/Tc=1 threshold shown in the stats panel.

Companion Content

Wave 47 is accompanied by two blog posts on adjacent topics:

What’s Next

The platform continues to fill gaps in coverage. High-priority additions under consideration include tribology (friction, wear and lubrication physics), seismic wave propagation (P and S waves in layered media), and quantum dot spectroscopy (quantum confinement and size-dependent fluorescence). On the blog side, a Spotlight covering earth-science simulations and a Learning entry on statistical mechanics and phase transitions are both planned.

electrode-kinetics Butler-Volmer Tafel cyclic-voltammetry overpotential exchange-current polymer-chain freely-jointed-chain Flory-scaling radius-of-gyration Monte-Carlo magnetic-domains Ising-model B-H-hysteresis ferromagnetism Curie-temperature
← Devlog #66 (Wave 46) Back to blog →