get_rho and get_dr fixed for crystals and non-equidistant r