Last week Adrian Holovaty asked me (in response to a comment about me still wanting to write a guide to music theory for programmers—not sure if Adrian knows about Czerny) about algorithms for note quantization.
As it's of interest to me and somewhat related to Czerny, I decided I'd put down some thoughts.