added a missing end and some missing input arguments to muti.m