optimize a bit D-small
Mod functions
Work on D-large wheel