Algorithms normalization and fixes