More correctly updated conversion code to fix normalization bugs.  Tested and works.