MATLAB: How to create a vector from two or three point

vector

a) A(1,2) B(6,3) C (1,5) b)A(5,9,8) B(7,5,4) C(5,7,8) How to create vector AB and AC ?

Best Answer

A = [1,2]
B = [6,3]
C = [1,5]
AB = B - A
AC = C - A
The same with three points