update simulation code and tweak options