This is a 2D circuit-and-charge model of the same lateral sliding-mode TENG: a fixed bound surface charge density σ on an insulating strip is progressively covered and uncovered as a metal electrode slides underneath by displacement x(t). Electrostatic induction redistributes free charge on the electrode to screen the exposed bound charge, and that redistribution — driven through an external load resistor — is the harvested current. The engine below solves the equivalent-circuit ODE independently every frame (not the 3D page's code, a separate re-derivation of the same physics), then plots it three ways: the charge-strip schematic, a scrolling V(t)/I(t) oscilloscope, and a Q-vs-x hysteresis loop that a 3D scene has no natural place to show.
Overlap capacitance: C(x) = ε0·W·(L−|x|) / d_eff + C_parasitic
Short-circuit charge: Qsc(x) = σ·W·|x|
Circuit equation: dQ/dt = (Qsc(x) − Q) / (R_L·C(x))
Load voltage: V(t) = I(t)·R_L
Instantaneous power: P(t) = I(t)²·R_L
Because R_L·C(x) (the RC time constant) can be far smaller than one animation frame, the engine integrates in several exponential-decay micro-steps per frame rather than a single Euler step — the standard, numerically stable way to solve a stiff linear RC circuit — instead of a fixed-step method that would blow up at high resistance.
Verified discrepancy from the 3D version: sweeping RL across this slider's full range shows average delivered power rising monotonically toward the top of the range — it never peaks partway across, because the true impedance-matched optimum for these plate dimensions sits near 10 GΩ (roughly 1/(ω·C̄), where C̄ is the cycle-averaged overlap capacitance), about an order of magnitude above where the original page's slider tops out. This build's RL range is extended so you can actually reach and see that interior peak.
- Material pair — sets σ (higher separation on the triboelectric series → larger σ → more charge, more power).
- Slide frequency — how fast the electrode reciprocates; higher speed = higher peak current (dQsc/dt scales with velocity).
- Plate length L — sets the stroke and the baseline capacitance scale.
- Load resistance RL — sweep it and watch the hysteresis loop widen, then narrow again, as you cross the impedance-matched optimum.