a = [1, 3, -5] b = [4, -2, -1] % or [4; -2; -1] and avoid transposition with ' disp( a * b' ) % ' means transpose