Modulo function. MOD(x,d) returns the remainder after x is divided by d. The result has the same sign as the divisor d.
The argument x can be a real number or a matrix. When it is a matrix, the function returns a matrix with the same dimensions and with the MOD function applied to all elements.
MOD(27,5) equals 2