 r_diff evaluates as 1 for all elements, which yields a zero length array. we should handle this as an edge case