add id to range computation
add id to computation of ranges