When using the outerMod function on matrices filled with zeros, the result is unexpected large negative values, to be exact the minimum signed 64-bit integer value. We get -nan when doing the same for zero floats. When using mod on two 0 scalars, we get an error message as expected.
Examples:
Using the outerMod function with two matrices filled with zero integers:
X = [0, 0];
Y = [0, 0];
result = outerMod(X, Y);
print(result);
Description:
When using the
outerMod
function on matrices filled with zeros, the result is unexpected large negative values, to be exact the minimum signed 64-bit integer value. We get-nan
when doing the same for zero floats. When using mod on two 0 scalars, we get an error message as expected.Examples:
Using the
outerMod
function with two matrices filled with zero integers:Output:
Using the
outerMod
function with two matrices filled with zero floats:Output:
Using the
mod
functionality with two scalar zeros:Output:
To my knowledge, all of these mod usecases should return an error message like in the third example.