Transfer Matrix Method Matlab