removing redundancies