bug fix in new code in sim utils