completely reordered apply diffusion, main loop, calculateeriosion. non-production code. not working, not building, not logic complete. just syncing to switch computers.