Remark 1
5F9WLet \mathcal{F} be a small permutation class.
Then there exists a regular language L_{\mathcal{F}} and a length-preserving bijection
f_{\mathcal{F}}: L_{\mathcal{F}} \rightarrow \mathcal{F}satisfying the following property: for every first-order logic sentence \Psi on \mathcal{F} there exists a first-order logic sentence \Phi on L_{\mathcal{F}} so that
\{w \in L_\mathcal{F}: w \models \Phi\} = \{w \in L_\mathcal{F}: f_\mathcal{F}(w) \models \Psi\}.The same conclusion also holds for sentences in monadic second-order logic.
(sketched) The bijection f_\mathcal{F} is in fact a monadic second-order isomorphism: that is, for every sentence \Phi in monadic second-order logic on L_\mathcal{F} there exists a corresponding sentence in monadic second-order logic on \mathcal{F} for which the conclusion above holds. In addition, it is also possible to construct a regular language L_\mathcal{F}' and a length-preserving bijection f'_\mathcal{F}: L_\mathcal{F}' \rightarrow \mathcal{F} which is a first-order isomorphism.
For the last three assertions, suppose that \mathcal{F} is not finite. There exist a positive real number \alpha, a real number \beta \geq 1, and a non-negative integer c so that
\vert \mathcal{F}_n\vert = (\alpha+o(1))\cdot \beta ^n\cdot n^c.Given a monadic second-order sentence \Psi on \mathcal{F}, write
\mathcal{F}^\Psi_n := \{\sigma \in \mathcal{F}_n: \sigma \models \Psi\}.Then the sets \mathcal{F}^\Psi_n have a rational generating function.
For every first-order \mathrm{TOTO} sentence \Phi the limit \lim_{n\rightarrow \infty} \mathbb{P} (\pi \models \Phi) exists, where \pi is taken uniformly at random from \mathcal{F}_n.
Proof of Remark 1
Let d and k be positive integers and let M be a multiplicative \star-isolated forest matrix chosen so that \mathcal{F} \subseteq \mathrm{Geom}(M)_{d,k}. Note that such M exists by Proposition 9. Since \mathcal{F} is a small permutation class, Proposition 23 implies that there exists a first-order sentence \hat{\upsilon}_{\mathcal{F}} so that \sigma \models \hat{\upsilon}_\mathcal{F} if and only if \sigma \in \mathcal{F}.
Let \chi_{\mathcal{F}} be the first-order sentence in \Sigma_M^* obtained by applying Theorem 36 to the sentence \hat{\upsilon}_{\mathcal{F}}, and set L_{\mathcal{F}} = \{w \in \Sigma_M^*: w \models \Delta_M \land \chi_{\mathcal{F}}\}. Thus Theorem 4 implies that L_{\mathcal{F}} is a regular language, and Theorem 36 implies that the restriction f_\mathcal{F} of f_M on L_{\mathcal{F}} is both a first-order and a monadic second-order homomorphism. Finally, since the restriction of f_M on \{w\in \Sigma_M^*: w\models \Delta_M\} induces a bijection whose image is \mathrm{Geom}(M)_{d,k}, it follows that f_\mathcal{F} induces a bijection from L_{\mathcal{F}} to \mathcal{F}. This completes the proof of the first part.
Let \mathcal{A'}_\mathcal{F} denote the automaton obtained by removing the unproductive states from the automaton \mathcal{A}_\mathcal{F} constructed in Theorem 62. Thus by Theorem 62 all the dominant strongly connected components of \mathcal{A}_\mathcal{F} are aperiodic, and at least one such component must exist as \mathcal{F} is not finite. Hence Lemma 52 implies that there exists positive constant c, non-negative integer k and \lambda \geq 1 so that
as n\rightarrow \infty. This completes the proof of the third part.
Let \Psi be a monadic second-order sentence on \mathcal{F}, and let \Phi denote the first-order sentence on words for which we have
Define L_\mathcal{F}^\Phi := \{w \in L_{\mathcal{F}}: w\models \Phi\}. Then L_\mathcal{F}^\Phi is a monadic second-order restriction of a regular language, and thus itself a regular language by Theorem 4. Hence the sets (L_\mathcal{F}^\Phi)_n has a rational generating function by Theorem 5, and thus \mathcal{F}^\Psi_n also have rational generating function, which completes the proof of the fourth part.
Let \Psi be a first-order sentence on permutations, and again we write \Phi for the corresponding first-order sentence on words. Let \mathcal{B}_\Phi denote the automaton chosen to satisfy the conclusion of Lemma 7, and set \mathcal{A}_\Psi := \mathcal{A}_\mathcal{F} \times B_\Phi. Then \mathcal{A}_\Psi accepts precisely those w \in L_{\mathcal{F}} with w \models \Phi.
Define b_n = |\mathcal{F}_n^\Psi|. If b_n = 0 for sufficiently large n, then the limit is clearly 0. Otherwise, let \mathcal{A}_\Psi' denote the automaton obtained from \mathcal{A}_\Psi by removing all the unproductive states. Then \mathcal{A}_\Psi' accepts the same words as \mathcal{A}_\Psi, and since it accepts infinitely many words, it contains at least one directed cycle.
Let \mu denote the largest spectral radius of a strongly connected component in \mathcal{A}_\Psi', and let r+1 denote the largest number of strongly connected components with spectral radius \mu along any walk from the initial state to an accepting state. Then standard properties of regular languages imply that |\mathcal{F}_n^\Psi| \leq C\cdot n^{r}\mu^n for some constant C.
If \mu < \lambda, then
and thus in particular the limit exists. If \mu \geq \lambda, let C be a strongly connected component in \mathcal{A}_\Psi' with spectral radius \mu, and let D be the strongly connected component in \mathcal{A'}_{\mathcal{F}} containing its projection. Write A and B for the transition matrices of \mathcal{A'}_\mathcal{F} and \mathcal{A}_\Psi' respectively. By Lemma 51 we have \rho(B_C) \leq \rho(A_D), and thus
Thus we must have \rho(B_C) = \rho(A_D) = \lambda, and hence D must be a dominant component, and hence D is aperiodic by Theorem 62. Since \rho(B_C) = \rho(A_D), Lemma 51 in turn implies that C must be aperiodic.
Thus every dominant component in \mathcal{A}_\Psi must be aperiodic, and thus Lemma 52 implies that there exits c'>0 for which b_n =(c'+o(1))\cdot n^r \cdot \lambda^n as n \rightarrow \infty. Thus
If r = k, the limit exists and equals \frac{c'}{c}. If r < k, the limit exists and equals 0. Since b_n \leq a_n for every n, we cannot have r > k. This completes the proof of the final part.