Degree function replaced