First-order substitution 2026-10-25
Replacing every free occurrence of variable in a first-order formula by a first-order term . Bound occurrences of are left alone. The operation requires either that be free for substitution at those occurrences or that conflicting bound variables first be renamed, as in capture-avoiding first-order substitution.
Free for substitution 2026-10-25
A first-order term is free for substitution for a variable in a first-order formula when no free variable of becomes bound after replacing a free occurrence of . Equivalently, at every free occurrence to be replaced, none of its enclosing quantifiers binds a variable appearing in . The test depends on occurrences and scopes, not merely on which variable names appear anywhere in the formula.
The term is free for substitution for . The only free occurrence of the target is in the outside disjunct , beyond both quantifier scopes. The occurrences under are bound variables and are not replaced. Therefore no renaming is required, and
The new and in the last disjunct are free. First-order substitution replaces the original free occurrences once; it does not recursively substitute into the inserted term.
The term is not free for substitution for . The occurrence of in is under , which would capture the inserted . The other occurrence, in the outside disjunct , has no enclosing quantifier. The inner does not bind the occurrence of in its antecedent, so it creates no additional capture at that substitution site.
Rename the bound to a fresh , then carry out capture-avoiding first-order substitution. The result is
The inserted in remains free because it lies outside the scope of . One may additionally rename that bound for readability, but it is not necessary for correctness.
Use broad scope up to the enclosing parenthesis, consistent with (c). Thus the first conjunct is read as
is not free for substitution for . The free occurrence of in lies under ; inserting there would capture its . Rename that bound variable to a fresh first, using alpha equivalence. The capture-avoiding first-order substitution is then
Every occurrence of in the original formula is free, so all four are replaced. The variable introduced by the term remains free, and the final is unchanged.
Under the same scope convention, is not free for substitution for . The occurrence of inside is free but lies under , so its replacement would capture the new . Rename this binder to fresh . Substitute only for the free occurrences in the first conjunct:
The two occurrences of in the final conjunct are bound variables and remain unchanged. The inserted remain free.
If instead one gives the printed only the scope , this part's free-for-substitution answer becomes yes, because neither free occurrence then lies under that binder. Under that alternative parsing, the result is explicitly
The narrower reading does not change the negative answer in (1): its occurrence of inside still requires renaming that binder before substitution. The broad-scope answers above give a single consistent parsing across the paper.