Degree discount heuristic
package fixes