Create kd_nclosestpoints.m