Flip-flop frequency divider calculator
Each T flip-flop with T = 1 halves the frequency, so n of them in a row give f_out = f_in / 2ⁿ. A 32,768 Hz watch crystal through 15 flip-flops gives 32,768 / 32,768 = 1 Hz, one tick a second.
Your values
Enter a number above 0, up to 10,000,000,000.
Enter a whole number from 1 to 40.
These values have no real result.
Result
- f_out output frequency
- Hz
- 2ⁿ division ratio
- T_out period
- s
Fix the value marked above to see the result.
Worked steps
- 2ⁿ = 2¹⁵ = 32,768
- f_out = f_in ÷ 2ⁿ = 32,768 Hz ÷ 32,768 = 1 Hz
- T_out = 1 ÷ f_out = 1 ÷ 1 Hz = 1 s
Formulas used
The same formulas as the formula sheet and the practice questions; the worked steps print them with your numbers.
f_out = f_in ÷ 2ⁿT_out = 1 ÷ f_out
Questions
Why does a flip-flop halve the frequency?
With T = 1 it changes its output at every clock edge it reacts to, which is once per clock period. Two changes make one whole output period, so the output period is two clock periods long.
Why do watches use a 32,768 Hz crystal?
Because 32,768 = 2¹⁵: fifteen flip-flops divide it down to exactly 1 Hz, and a small crystal at that frequency is cheap and uses very little power.
How do I divide by a number that is not a power of 2?
Use a MOD-N counter: a gate clears the flip-flops when the count reaches N, so the counter shows 0 to N − 1 and divides by N. A MOD-10 counter turns 1 kHz into 100 Hz.