compas.geometry.norm_vectors

compas.geometry.norm_vectors(vectors)[source]

Calculate the norm of each vector in a list of vectors.

Parameters

vectors (list) – A list of vectors

Returns

list – A list with the lengths of all vectors.

Examples

>>> norm_vectors([[1.0, 0.0, 0.0], [2.0, 0.0, 0.0], [3.0, 0.0, 0.0]])
[1.0, 2.0, 3.0]