Degrees update

Fixed again some code on analytical calculation of degrees