math.hypot

The math.hypot function returns the Euclidean norm of the vector that, having the center of coordinates as its origin, ends at the coordinates indicated as an argument. The result is equivalent to math.sqrt(sum(x ** 2 for x in coordinates)).

 

Submitted by admin on Sun, 02/07/2021 - 11:27

math.dist

The math.dist function returns the Euclidean distance between the two indicated points. These must be defined by a sequence (or iterable) of coordinates and must have the same dimension.

Submitted by admin on Sat, 02/06/2021 - 08:50

math.atan2

The math.atan2 function returns the arctangent, in radians, of the quotient of the arguments passed to the function: atan(y/x).

Once the point (x, y) is located in the plane, the angle returned is the one formed by the positive x axis and the line that passes through the origin of coordinates and through the point (x, y) :

Submitted by admin on Fri, 02/05/2021 - 08:54

math.pow

The math.pow function returns the result of raising x to y. Unlike the built-in function pow or the ** operator, math.pow always returns a real number, even if x and y are integers.

Submitted by admin on Mon, 02/01/2021 - 08:16