%%%
function dd = dist(x, map, lambda)
c1 = 1; c2 = 10;
d = (x*lambda - 1)^2/sum(lambda.^2);
dm = dpl(map, lambda);
% Final distance
dd = c1*d + c2*dm;