Mathematical Form:
K(t-τ) = λ exp(-λ(t-τ))
Exponential memory decay with characteristic time 1/λ
Integral Form (what appears in CRR equation):
∫₀ᵗ K(t-τ) × signal(τ) dτ
Equivalent Differential Form:
dmemory/dt = λ(signal - memory)
This first-order ODE has the same solution as the integral form
Code Implementation:
updateMemory(lambda) {
for (let i = 0; i < this.cells; i++) {
const totalBiomass = this.protonema[i] + this.gametophore[i] +
this.buds[i] + this.rhizoids[i];
this.moistureMem[i] += lambda * (this.moisture[i] - this.moistureMem[i]);
this.nutrientMem[i] += lambda * (this.nutrients[i] - this.nutrientMem[i]);
this.growthMem[i] += lambda * (totalBiomass - this.growthMem[i]);
}
}
Default λ = 0.025: This gives memory timescale τ_mem = 1/λ = 40 timesteps. Past signals decay to ~37% after 40 steps, ~13.5% after 80 steps.