Renamed some methods
Refactor permutation decoding methods