There's a worry circuit in the brain, and when we worry 3 things usually happen. First a part of our brain behind our forehead detects the mistake. Orbitofrontal Cortex. And it sends a signal to another part of the brain called the Anterior Cingulate . The Anterior cingulate makes you anxious about the mistake so you'll stay focused on it until you've corrected it. And Finally, once you have corrected it... a third part (the Caudate) Funtions like a mental gear shift and shifts you on to the next thing. But in people with OCD that mental gear shift is very sticky. It stays stuck. So they try to correct the mistake again and again.

Each time they correct the mistake their anxiety drops... very briefly. Because neurons wired together that fire together, They get the idea that to lower anxiety they should keep correcting the mistake. It works in the short run. But in the long run, it makes them more obsessed