This commit: clean up of some matlab code.