Dynamic processors automatically adjust the output level (dB) of a signal based on the level of the incoming key input.  The processor beings to adjust the output level of the source input signal at (or around) the threshold level of the key input.  Dynamic processors also have time-based functions built into them (collectively called the envelope) that dictate how quickly the signal becomes affected when the signal level meets the threshold.  These often include attack, decay, sustain (or hold), and release.

Compressor

A compressor reduces the overall dynamic range available for a given channel.  Once the key signal level becomes higher than the threshold, the output signal level is reduced by a selectable input-to-output ratio.  When set to 3:1, for example, for every 3 dB of signal above the threshold, the compressor will attenuate the output signal to allow 1 dB to pass through.  A compressor set 1:1 will not provide any compression, whereas a compressor set inf:1 will essentially limit the output level of the compressor to 1 dB above the threshold, regardless of the signal.  Some compressors have a knee adjustment, allowing a more subtle adjustment as the signal approaches the threshold level.

Compression Ratio
Compression ratio
By Iain Fergusson (Own Work)
Public Domain via Wikimedia Commons
Hard vs. Soft Knee
Compression knee
By Iainf (Own work)
Public domain, via Wikimedia Commons
Audio Compression Attack and Release
Audio Compression Attack and Release-2
By Iainf (Own work)
GFDL or CC-BY-SA-3.0 via Wikimedia Commons

Expander

The expander is essentially the opposite of a compressor.  Where a compressor will attenuate the signal ABOVE its threshold at a set input-to-output ratio, the expander attenuates the signal below its threshold at a proportion selected by the ratio, increasing the dynamic range of the signal by helping the quieter sections become even quieter.  When set to 1:2, for example, an input signal that is 3 dB below the threshold will  output a signal that is 6 dB weaker.  When set to higher value like 1:8, when the input signal is 3 dB below the threshold, the output signal will be 24 dB below the threshold.

Noise Gate

The noise gate is a specific type of expander - attenuating a signal to a point where it becomes inaudible while the signal is below the threshold.  Typically, a noise gate will have an expansion ratio above 1:10, creating a drastic cut in the signal level relatively close to the threshold.  The gate will OPEN over the amount of time set by the attack, allowing the un-affected signal to pass through as long as the signal remains above the threshold.  The gate will stay open for the amount of time set by the sustain (or hold) setting, and then will begin to analyze the signal again - waiting until the signal level drops below the threshold before closing over the amount of time set by the release.

Noise Gate Attack Hold Release
Noise Gate Attack Hold Release
By Iainf (Own work)
Public domain, via Wikimedia Commons

Sidechaining

Typically, the key input will be the source input, but most dynamic processors can be configured in sidechain mode, where, the key input is a separate signal than the source input.

Compressor Sidechain
Compressor Sidechain
By Iainf (Own work)
Public domain, via Wikimedia Commons