inference with functional dependencies