So rhythm, from the standpoint of dancing, has as its fundamental unit a delay followed by a beat. During the delay we step, hop, leap, or somesuch, and on the beat one or other foot hits the floor.
Note that this is opposite to how we notate music, in which the fundamental unit is an attack followed by a period of sustain.
Take a single unit:
| | ------
We may divide it into two:
| | | ------
| | | | ------
The resulting units may then be further subdivided to produce complex rhythms. Dividing a unit by larger numbers doesn't produce as pleasing results as dividing by two or three.
Here is an example demonstrating progressively deeper divisions:
Here is the code I used to generate it:
You will need python, abc2midi and timidity (or whichever MIDI player you prefer). (Yes this is an ungainly way to generate MIDI, I'd love to find a less painful way.)
Update: One still needs to think about what comes after a beat, lest the beat interfere with following beats. Here's an example that does this (and with some further refinements):