Clean-up, streamline and documente filter/smoother routines

For the IMF.