Those functions were not really tested in DynamicPPL (except for the doctests). I moved them here but didn't add tests. Tests should be added.