Definition
Sleep has no single agreed function, so its purposes are inferred largely from what happens when it is lost. The rebound increase of SWS and REM following deprivation is the key evidence that both states are needed, with each stage apparently answering a different need.
Evidence that sleep is needed
When sleep is lost, the missing stages are repaid at the next opportunity: both SWS and REM show a rebound increase following deprivation, rising above their usual levels. Such compensation implies that each stage is regulated and required rather than optional. The defining physiology of the two states is covered in REM versus Slow Wave Sleep, and the stage definitions in EEG and the Stages of Sleep.
REM sleep
Selective deprivation of REM causes abnormalities in sensory processing and subtle emotional and personality disturbances. These deficits point to a role in mind maintenance: REM brings repeated bouts of cortical activation close to waking levels, and the proposal is that this activity keeps the machinery of perception, emotion and personality in working order, since these are precisely the faculties that falter when REM is lost. REM is also proposed to be necessary for the consolidation of memories: removing REM after learning impairs later recall, evidence that memory traces laid down while awake are stabilised during these episodes.
Slow wave sleep
SWS is the phase linked to body maintenance, and the deepest slow wave sleep is the part that really matters. During SWS, hormones that stimulate protein synthesis are released, driving growth and tissue repair, glymphatic clearance increases, washing metabolic waste out of the brain, and the immune system is stimulated, aiding defence and recovery. Consistent with this restorative role, N3 is increased after exercise: N3 is the deepest stage of the current 3 stage NREM nomenclature and merges the former stages 3 and 4, so the stage 4 of older usage is the N3 of today. Its rise after physical exertion ties the deepest sleep directly to the recovery needs of the body.
Summary
Summary
Both states rebound after deprivation, but they do different work. REM serves the mind: its loss brings sensory processing abnormalities with subtle emotional and personality disturbances, and it is credited with mind maintenance and memory consolidation. SWS serves the body through hormones that stimulate protein synthesis, glymphatic clearance and immune stimulation, with its deepest stage, N3, rising after exercise.