Add minor_dets routine for testing