Greatest common divisor (gcd)

Working with polynomials? See gcd (Polynomials)


Returns the greatest common divisor of a set of integers.

gcd(Integer, ..., Integer)

Given a set of integers a subscript 1, ..., a subscript n, returns the largest number that divides a subscript 1, ..., a subscript n simultaneously.

gcd(List)

Given a list of integers left curly bracket a subscript 1 comma... comma a subscript n right curly bracket, returns the largest number that divides a subscript 1, ..., a subscript n simultaneously.

gcd(Vector)

Given a vector of integers left square bracket a subscript 1 comma... comma a subscript n right square bracket, returns the largest number that divides a subscript 1, ..., a subscript n simultaneously.

gcd(Fraction, Fraction)

Given two fractions a over b and c over d, returns its greatest common divisor defined as g c d open parentheses a over b comma c over d close parentheses equals fraction numerator g c d left parenthesis a comma c right parenthesis over denominator l c m left parenthesis b comma d right parenthesis end fraction