Degrees of Freedom Formula