TITLE: Need help regarding a proof in First Order Logic
QUESTION [5 upvotes]: I am trying to proof the following question:
we are claiming that given any sentence φ and any model M (of the same vocabulary), and any variable assignments g and g′ in M, then M, g |= φ iff M, g′ |= φ. We want the reader to do two things. First, show that the claim is false if φ is not a sentence but a formula containing free variables. Second, show that the claim is true if φ is a sentence.
I have tried the following approach:
Here, given any sentence $\phi$ and any model $M$ (of the same vocabulary), and any variable assignments $g$ and $g'$ in $M$ then,
$ M,g\models \phi\; \iff \; M,g'\models \phi $.
Now if $\phi$ is a formula, then from the definitions of satisfaction of formula in a model $M$ the first one is given below,\
$ M,g\models R(\tau_1,...,\tau_n) \iff (I_F^g(\tau_1),...,I_F^g(\tau_n)) \in F(R) $\
$ M,g'\models R(\tau_1,...,\tau_n') \iff (I_F^{g'}(\tau_1),...,I_F^{g'}(\tau_n)) \in F(R) $\
But here $I_F^g(\tau_1) \neq I_F^{g'}(\tau_1)$ because the term $\tau_1$ can have different values for the assignments $g$ and $g'$ for the model $M$. Thus  $ M,g\models \phi\; \iff \; M,g'\models \phi $ is not true if $\phi$ is a formula. The other definitions of satisfaction of formula are not needed to check as it has to satisfy all the definitions.
I am really not sure if I'm going into the right direction. There are six different satisfaction definitions given for a formula $\phi$. Can anybody help me if this is the correct way? Or how can I write the proof?

REPLY [3 votes]: First to show that the claim is false if $\phi$ is not a sentence but a formula containing free variables, we can take $ϕ(x,y):=\forall x(x^2+y^2=x^2-y^2)$ with $y$ as a free variable and with domain as the usual $\mathbb R$. So clearly $M, g \models ϕ$ under the assignment $g$ where $I_F^g(y)=0$, however, $M, g' \models ϕ$ doesn't hold under another assignment $g'$ where $I_F^{g'}(y)=1$. Second to show that the claim is true if $\phi$ is a sentence, consider now $ϕ(x,y):=\forall x \forall y((x+y)(x-y)=x^2-y^2)$. Then any variable assignment does not affect the truth value of sentence $\phi$, and obviously from elementary algebra we have $M, g \models ϕ$ under any $g$.