javascript - What does /... mean in Matlab? -


i'm trying translate equation matlab javascript

k = 2*abs((x2-x1).*(y3-y1)-(x3-x1).*(y2-y1)) ./ ...    sqrt(((x2-x1).^2+(y2-y1).^2)*((x3-x1).^2+(y3-y1).^2)*((x3-x2).^2+(y3-y2).^2)); 

what ./ ... mean here?

... represents line continuation, while ./ means division performed in element-wise way. example, c = ./ b means for elements, c(i) := a(i) / b(i). similarly, .* , .^ represent element-wise multiplication , exponentiation.


Comments