added dynamic version of emme's generator