dirty version, just for synch..
Parametric filter functions and some fixes
removed extra blank lines