A simulation model for the saturable reactor