My matlab code