completed parent_index method, added comments