% this is weird but it works
% nan means variable, so max(nan,x)=x
% inf means failure so max(inf,x)=inf
function z=unify(x,y)
	if ~isfinite(x) || ~isfinite(y), z=max(x,y);
	elseif x==y, z=x; 
	else z=inf; 
	end
end
