How to create a vector from two or three point?

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 ?

 采纳的回答

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

3 个评论

I want to create a function to calculate the vector, I can input the what number I need to calculate
function [vector] = calculate_vector(A,B)
vector = B - A;
end

请先登录,再进行评论。

更多回答(0 个)

类别

帮助中心File Exchange 中查找有关 NaNs 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by