The function appears to work correctly for all the input words tested. There doesn't seem to be any part of the domain where the rule the function normally applies, does not hold. Therefore, the domain of the function is the set of all words that can be translated using the substitution cipher.

Please let me know if you have any further