now finds winding numbers