Fixed simulation error with systematic encoding