refactor is_inspecial_group