predicate function error