Elementary equivalence is set-theoretically absolute between any two transitive models of set theory; this is also true for the infinitary logics - e.g., $\mathcal{L}\_{\omega\_1\omega}$ - at least, assuming the models in question have all the relevant infinitary formulas. In both cases, the easiest way to prove this is to prove that the *satisfaction* of a given sentence in a given structure is absolute (note <https://arxiv.org/abs/1312.0670> by Joel David Hamkins and Ruizhi Yang, which justifies my restriction to *transitive* models).


This latter statement is of course false for second-order logic: the statements "the Continuum Hypothesis holds" and "this model is countable" are both expressible by second-order sentences, and their truth values depend on the ambient universe, with the former being being a "switch" and the latter a "button" in the sense of the modal logic of forcing.


However, this alone does not show that second-order elementary equivalence, "$\equiv\_{II}$", is not absolute. The simplest way I know to show that $\equiv\_{II}$ is not absolute is to consider a pair of models $A, B$ whose cardinalities have different set-theoretic properties; for example, take $A$ and $B$ to be pure sets with cardinalities $\aleph\_0$ and $\aleph\_1$, respectively. Then the former satisfies "I am countable" while the latter does not, and this is expressible by a second-order sentence, so they are not second-order elementarily equivalent; however, by collapsing $\omega\_1$ we make $A$ and $B$ isomorphic.


This leaves open, however, two classes questions about the non-absoluteness of second-order elementary equivalence. I'll mention a couple in each class.




---


First, how much of this depends on cardinality?



> 
> Are there equinumerous $A$, $B$ such that the second-order elementary equivalence of $A$ and $B$ is not absolute between transitive models of set theory containing $A$ and $B$?
> 
> 
> 


And the stronger version:



> 
> Are there *countable* such $A$ and $B$?
> 
> 
> 




---


Second, what kind of "switching behavior" is possible? The example given above shows that we can "turn $\equiv\_{II}$ on," but in that example we cannot turn it off again. An example where we can "turn $\equiv\_{II}$ off" is the following: take pure sets $A$ and $B$ of cardinalities $\vert A\vert<\vert B\vert$ which are second-order elementarily equivalent; by the pigeonhole principle, we can in fact find such $A$ and $B$ of cardinality $\le 2^{\aleph\_0}{}^+.$ Now consider a forcing extension $V[G]$ in which $\vert A\vert$ is made countable but $\vert B\vert$ is not; in $V[G]$, $A\not\equiv\_{II}B$. This raises a couple interesting questions.


First, note that in the above example, we can turn $\equiv\_{II}$ back on again by collapsing $\vert B\vert$ to $\omega$. So it makes sense to ask:



> 
> Suppose $A\equiv\_{II} B$ in $V$. Is it the case that for every generic extension $V[G]$, there is a further generic extension $V[G][H]$ in which $A\equiv\_{II} B$?
> 
> 
> 


Second, the only examples I've found so far involve collapsing cardinals. This, of course, runs out when everything reaches $\omega$. So we can ask:



> 
> Is there a pair of structures $A, B\in V$ and an $\omega$-sequence of models $V=V\_0<V\_1<V\_2< . . . $ (where "$W<W'$" means "$W'$ is a generic extension of $W$") such that $V\_i\models A\equiv\_{II}B$ exactly when $i$ is even? In general, what sort of 'alternating behavior' is possible?
> 
> 
> 




---


This is of course a long list of questions, and I don't expect them all to be answered here. Basically, I'm interested in everything around this issue, so I'll accept any answer which helps me understand the general picture of things.



The (non-)absoluteness of second-order elementary equivalence
**In this edit I have modified my previous argument, and added the appropriate conditions to Harrington's theorem.**



> 
> I will explain below why it is possible to arrange a model $M$ of $ZFC$ that:
> 
> 
> **(a)** contains two nonisomorphic countable structures $\cal{A}$ and $\cal{B}$ (in a finite vocabulary) that share the same second order theory, and
> 
> 
> **(b)** $M$ has a generic extension in which $\cal{A}$ and $\cal{B}$ differ in their seond order theory.
> 
> 
> 


**(1)** By a theorem of Marek, if there is a second-order definable well-ordering of the continuum, then as soon as two countable structures are elementarily equivalent in second order logic, then they are isomorphic.


**(2)** On the other hand, by a result of Ajtai, if $G$ is Cohen generic over a model $M$ of $ZFC$, then in $M[G]$ there will be two countable models $\cal{A}$ and $\cal{B}$ in a finite vocabulary that share the same second order theory (indeed they form a pair of indiscernibles in $M$ and share the same theory in many other logics beyond second order logic).


$\cal{A}$ is the structure $(F^{G} \cup \omega, <\_{\omega}, P\_{G})$, where $F^{G}$ is the collection of all subsets of $\omega$ that differ in finitely many places with $G$, and $P\_{G}$ is the relation that specifies which natural numbers belong to which subsets in $F^{G}$. $\cal{B}$ is defined similarly, with $\omega \setminus G$ swapped for $G$.


Since $\omega$ is rigid, $\cal{A}$ and $\cal{B}$ are nonisomorphic, and *moreover, remain nonisomorphic in any generic extension.*


(For proofs and references for (1) and (2) above, see Theorems 2.3 and 2.13 of [this manuscript](https://www.mittag-leffler.se/preprints/files/IML-0910f-34.pdf) ([Wayback Machine](https://web.archive.org/web/20100820134034/https://www.mittag-leffler.se/preprints/files/IML-0910f-34.pdf)) by Lauri Keskinen, which I believe is his Ph.D. dissertation at ILLC Amsterdam).


**(3)** By a theorem of Harrington, if $M$ is a countable model of $ZFC$ in which **(a)** $2^{\aleph\_0}$ is a regular cardinal, **(b)** $2^{\aleph\_0} > \aleph\_1$, and **(c)** $\aleph\_1 = \aleph\_1^{\bf{L}}$, then $M$ has a generic extension $M[G]$ in which there is a second order definable well-ordering of the continuum ((more precisely, a $\Delta^1\_3$ one).


(See Theorem 2.1 of Harrington's *Long projective well-orderings*, **Annals of Math. Logic**, 1977; the specific conditions on $M$ are stated on p.8, at the beginning of the proof of Theorem 2.1).


Based on (2), we can arrange a model $M$ of $ZFC$ in which there are two nonisomorphic countable structures $\cal{A}$ and $\cal{B}$ as described in (2) that share the same second order theory, such that $M$ satisfies conditions (a), (b), and (c) of Harrington's theorem (say by adding $\aleph\_2$ cohen reals to a model of $ZF + V=L$). Then by using (3) and invoking (1) we obtain a model of $ZFC$ in which two nonisomorphic structures that used to have the same second order theory now have different second order theories, since they remain nonisomorphic, as explained at the end of (2).


In light of Joel Hamkins' answer I should point out that Section 4 of Keskinen's aforementioned manuscript also addresses the effect of large cardinals on the issues discussed here.


You may also find my answer to [this question](https://mathoverflow.net/questions/72635/categoricity-in-second-order-logic) to be of interest.


