Cleanup DiscreteFunctions

Merged Praetorius, Simon requested to merge issue/discretefunction_cleanup into master

Merge request reports