Quite a challenge, Dr. Bill. Give me five minutes.

Here's the diagram of the dimmer switch (including the TRIAC) http://www.geocities.com/tjacodesign/dimmer/dimmer.html

and here's the explanation of hysteresis: http://www.lassp.cornell.edu/sethna/hysteresis/WhatIsHysteresis.html

3:47 (!)