Table Of Contents

gcd

Version:
    Last Modified: December 12, 2016

    Computes the pairwise greatest common divisor of the input elements.

    Syntax

    c = gcd(a, b)
    [c, d, e] = gcd(a, b)

    Inputs

    a

    Scalar or array of any dimension of integers.

    b

    Scalar or array of any dimension of integers of the same size as a.

    Outputs

    c

    Greatest common divisor of a and b. c is an array of the same size as a or b.

    d

    Array of the same size as a or b such as c = a.*d+b.*e.

    e

    Array of the same size as a or b such as c = a.*d+b.*e.

    A = 234;
    B = 98;
    C = gcd(A, B)

    Where This Node Can Run:

    Desktop OS: Windows

    FPGA: DAQExpress does not support FPGA devices


    Recently Viewed Topics