Added feature of distance arguments instead of rate