# gcd¶

tenpy.tools.math.gcd(a, b)[source]

Computes the greatest common divisor (GCD) of two numbers.

Return 0 if both a, b are zero, otherwise always return a non-negative number.