FOL with Update Expressions

Syntactic extension of FOL with if-then-else, function update, sets.


ite(p,x,y) = if p then x else y

Function Update

f (a:=b)(x)

f ( (a,b) :=c)(x,y)


Set variables (not quantified).

Set operations $\cup$, $\cap$, $\setminus$, $\{x,y\}$.

Syntax Summary

  F ::= A \mid F \land F \mid F \lor F \mid \lnot F \mid \exists x.F \mid \forall x.F \\
  A ::= R(T,\ldots,T) \mid T=T \mid S \subseteq S \mid S=S \\
  T ::= V_o \mid U(T,\ldots,T) \mid ite(F,T,T) \\
  U ::= f \mid U((T,\ldots,T):=T) \\
  S ::= V_s \mid S \cup S \mid S \cap S \mid S \setminus S \mid \{T,\ldots,T\} 

Elimination of Extensions

f(a:=b)(x) =

f ( (a,b):=c )(x,y) =

z=ite(p,x,y) $\leftrightarrow$

F(ite(p,x,y)) $\leftrightarrow$

S1 = S0 Un {a} $\leftrightarrow$

f = g

Substituting Function Symbols

Consider symbolic execution of assignment to local variable

x = e

Evaluate e in current symbolic state, then assign symbolic value of x to result.


x.f = e;


f = f(x:=e)

We need to replace f with f(x:=e).

  • do we always get syntactically valid formula in FOL extension above?