Protein Folding
← Past Projects

An experimental 2D folding algorithm. Each particle is not a point charge but an amplitude distribution over a grid (non-negative, summing to 1). The system evolves under a distance-dependent dielectric (DDD) electrostatic model, with each cell's amplitude pushed up or down — Hopfield-style — by its interaction with every other particle's cloud. Watch the clouds condense toward a minimal-energy arrangement.

step 0 temp energy backend
Particles4
Grid size (N×N)16
Grid scale1.0
Spacing between cells, in arbitrary distance units. Larger = more room to spread out.
Rate0.20
Step size of each amplitude update.
Repulsion strength3.0
Short-range soft-core repulsion. With the DDD attraction, this sets the equilibrium separation between opposite charges.
Temperature1.00
Exploration softness. Higher = broader, more exploratory clouds while the arrangement settles.
Cooling rate0.030
How fast it cools once the energy settles. 0 = never cool (stays as clouds).
Final temperature0.010
How cold it gets = how sharply clouds collapse to points. Lower = crisper.