Mathematics
Greatest Common Divisor
Find the largest integer divisor shared by two integers.
Let’s calculate.
Usage estimateFind the largest integer divisor shared by two integers.
Formula and worked example
gcd(a,b) = gcd(b, a mod b)
Reference example
The GCD of 48 and 18 is 6.
When this calculation applies
This tool accepts positive integers only, up to 10¹⁵ each. It excludes zero and signed inputs even though broader GCD definitions can include them.
Background reference: NIST. References explain the method or units; they do not certify this calculator.
Source scope: NIST defines the integer operation or Euclidean algorithm. CalcuAll deliberately restricts its supported inputs to positive integers; broader mathematical conventions are not silently applied.
For the derivation, input conventions and numerical limits, open .