Find ring structures in molecular graphs