what does a normalize means?

papawo
papawo Member, Developers Posts: 206 PRO

from the library:

_____________

normalize (vector is Vector) returns Vector

Returns the (unitless) result of normalizing vector. Throws if the input is zero-length.

Comments

  • ilya_baran
    ilya_baran Onshape Employees, Developers, HDM Posts: 1,278 image
    It means scaling the vector to have length 1.  So e.g. normalize(vector(2, 0, 0)) is vector(1, 0, 0)
    Ilya Baran \ VP, Architecture and FeatureScript \ Onshape Inc
  • papawo
    papawo Member, Developers Posts: 206 PRO
    ok got it thanks!