The ongoing activity in the brain throughout sleep, then, could have something to do with consolidating memory traces, extracting their gist, and integrating new with old memories (Born et al. 2006; Rasch and Born 2013). This idea is supported by studies performed over the past 20 years, first in rodents and then in primates, which show that patterns of neural activity during sleep often resemble those recorded during wake (Wilson and McNaughton 1994; Kudrimoti et al. 1999; Nadasdy et al. 1999; Hoffman and McNaughton 2002). For example, when a rat learns to navigate a maze, different hippocampal neurons fire in different places, in specific sequences. Presumably, each sequence is encoded in memory by strengthening the connections between neurons firing one after the other. During subsequent sleep, especially NREM sleep, these sequences are “replayed” above chance (though neither very often nor very faithfully). Based on this evidence, many researchers think that sleep “replay” may consolidate memories by further reinforcing the synaptic connections that had been strengthened in wake, leading to synaptic consolidation. There may also be some system-level consolidation, based on evidence that over time memories may be shuttled around in the brain. For example, the hippocampus may provide early storage, after which memories are transferred to connected cortical areas, and sleep may help this transfer (Girardeau et al. 2009). However, there is also evidence that the “replay” of neural circuits can also occur in wake, not just in sleep (Karlsson and Frank 2009), and “preplay” can also occur during wake before learning (Dragoi and Tonegawa 2011).
An interesting alternative is that sleep may be a time not so much for rehearsal, but for down-selection (Tononi and Cirelli 2014). In essence, the idea is this: when the brain sleeps, spontaneous neuronal firing activates many circuits in many different combinations, both new memory traces, which may be particularly prone to reactivation, and old networks of associations. But instead of strengthening whatever synapses are activated the most, which would lead to learning things that never happened, the brain could reverse plasticity rules, and promote the activity-dependent weakening of connections. Indeed, an efficient way to do so would be to implement a selectional, competitive process. For example, synapses that are reactivated most strongly and consistently during sleep would be protected and survive mostly unscathed, whereas synapses that are comparatively less activated would be depressed. This down-selection process would literally ensure the survival of those circuits that are “fittest,” either because they were strengthened repeatedly during wake (the signal, i.e., the right notes on the guitar) or because they are better integrated with previous, older memories (a new word in a known language). Instead, synapses involved in circuits that were only occasionally strengthened during wake (the noise, i.e., fumbled notes on the guitar), or fit less with old memories (a new word in an unknown language), would be depressed and possibly eliminated. In this way, synaptic down-selection during sleep would promote memory consolidation by increasing signal-to-noise ratios, thereby favoring gist extraction and the integration of new memories with established knowledge. As an additional bonus, down-selection would also make room for another cycle of synaptic strengthening during wake. Indeed, there are several indications that sleep, in addition to memory consolidation, gist extraction, and integration, is particularly beneficial to memory acquisition: quite a few studies have shown after a night of sleep you can learn new material much better than after having been awake all day.
Finally, down-selection based on the systematic reactivation of neural circuits old and new would also explain why prolonged quiescence and disconnection from the environment are important—that is, why one needs to be asleep. This is because sleep is the perfect time for the brain to try out many different scenarios without worrying about behaving appropriately in the real world. Only in this way can the brain go through a large repertoire of situations, collect fair statistics about how each synapse is activated in the context of the entire set of stored memories (how well it fits), and reorganize its networks accordingly. Otherwise, the synapses that were strengthened most recently would always be favored (say you spent the entire day trying out the guitar) at the expense of others that are equally important (you also know how to type, and you would not want to forget it), irrespective of how the new memories fit with your previous knowledge.
In the end, cycles of net strengthening of connections during wake followed by net weakening during sleep may constitute an excellent selectional strategy that implements a healthy reality check: neural activity patterns triggered during wake, when the brain is connected with the environment, would tend to be reinforced, whereas activation patterns triggered during sleep, when the brain is disconnected from the environment and makes up its own imaginary scenarios, would be weeded out systematically.