bug fix in prim
Merge branch 'master' into move_to_deap1