Semantics of the Barwise sentence: insights from expressiveness, complexity and inference

In this paper, we study natural language constructions which were first examined by Barwise: The richer the country, the more powerful some of its officials. Guided by Barwise’s observations, we suggest that conceivable interpretations of such constructions express the existence of various similarities between partial orders such as homomorphism or embedding (strong readings). Semantically, we interpret the constructions as polyadic generalized quantifiers restricted to finite models (similarity quantifiers). We extend the results obtained by Barwise by showing that similarity quantifiers are not expressible in elementary logic over finite models. We also investigate whether the proposed readings are sound from the cognitive perspective. We prove that almost all similarity quantifiers are intractable. This leads us to first-order variants (weak readings), which only approximate the strong readings, but are cognitively more plausible. Driven by the question of ambiguity, we recall Barwise’s argumentation in favour of strong readings, enriching it with some arguments of our own. Given that Barwise-like sentences are indeed ambiguous, we use a generalized Strong Meaning Hypothesis to derive predictions for their verification. Finally, we propose a hypothesis according to which conflicting pressures of communication and cognition might give rise to an ambiguous construction, provided that different semantic variants of the construction withstand different pressures involved in its usage.


Introduction
Expressiveness is a measure that allows us to compare sentences and linguistic constructions in terms of their logical strength. One of the simplest ways of capturing this notion is obvious: we may say that a sentence A is more expressive than B if A entails B and B does not entail A. This is sometimes rephrased by saying that A has stronger truth conditions (is logically stronger), i.e., its truth conditions (that is, interpretations under which A is true) form a proper subset of the truth conditions of B.
A more subtle way of approaching the notion of expressiveness is through definability, where we are interested in questions like: -What kind of properties are definable using a given language or expression, or -Does a given construction increase the class of definable properties when added to that language.
In this sense, definability has acquired considerable attention and has provided us with fine-grained insights into expressive power of natural language constructions (see, e.g., Barwise and Cooper 1981;Peters and Westerståhl 2006).
As an example usage of logical strength in linguistic research, one can look at attempts to explicate variation in the literal meaning of reciprocal sentences, as formulated in Dalrymple et al. (1998) (see, also, Sabato and Winter 2005). According to the Strong Meaning Hypothesis (henceforth, SMH), a reciprocal expression should be assigned the strongest possible truth conditions which fit the context of interpretation. Some researchers argue that SMH has even more general status in semantics (Winter 2001;Szymanik 2010). SMH may be viewed as a particular instance of the Grice Maxim of Quantity which states that a speaker's contribution to a conversation should be as much informative as is required (Grice 1975).
According to the truth-conditional approach to natural language semantics, the meaning of a sentence is conceived as a mapping from models to truth values, orequivalently-as a class of models in which the sentence is true. The truth-conditional approach, though meaningful within the purview of logical semantics, tells us little or nothing about the cognitive content of sentence meaning (see, e.g., Stanosz 1974;Dummett 1975;Suppes 1982). Algorithmic theory of meaning, or procedural semantics, fills this gap by positing that the sense of an expression is a procedure for finding its denotation (Tichy 1969). For example, to know the meaning of "taller" does not mean to know who is taller than who but rather to know the procedure for deciding whether a given individual is taller then another one. In general, the meaning of a sentence (or, more broadly, expression) is conceived as a procedure for recognizing its truth value (denotation).
The idea of meaning as algorithm has been widely used and applied in linguistics, philosophy, logic and cognitive science. For instance, van Benthem (1986van Benthem ( , 1987 analyses how complex devices are needed to recognize various quantifiers. Mostowski and Wojtyniak (2004) show that the semantics of some natural language constructions are NP-complete. van Lambalgen and Hamm (2005) consider a cognitively motivated approach to the semantics of tense aspect and nominalization. Suppes (1980Suppes ( , 1982 claims that there are psychological reasons for scrutinising semantics of everyday expressions in terms of associations between linguistic constructions and procedures which get activated during language use [see Szymanik (2016) for a broader discussion on this topic]. As a matter of fact, empirical studies suggest that linguistic constructions are associated with specific procedures (Pietroski et al. 2009;Lidz et al. 2011;Tomaszewicz 2013).

Computational complexity and cognition
A computational model of meaning renders the notion of semantic complexity amenable to mathematical scrutiny. In particular, one can sensibly ask what is the computational complexity of a verification task for a given sentence. Here, verification is a task in which a human subject tries to recognize the truth value of a sentence in a given context. Using cognitively plausible measures of complexity, we can distinguish between meanings which are easy and hard to verify (see, also , Szymanik 2016).
A particularly interesting complexity class is PTIME (P for short). It consists of problems computable by deterministic Turing machines in polynomial time (for details on computational complexity see, e.g., Arora and Barak 2009). In part, the significance of this class is rooted in our computational experience: practical solutions are very often PTIME-computable and vice versa. It has even been proposed that the PTIME class consists of precisely those problems which are solvable in practice (feasible, tractable). This statement is known as the Edmonds thesis (Edmonds 1965).
Obviously, the question is whether PTIME (and computational complexity in general) has anything to do with human cognitive processing. A generalized version of the Edmonds thesis extends the putative relationship between feasibility and the class PTIME to all physical computing devices, including human brains (Mostowski and Wojtyniak 2004). The generalized Edmonds thesis implies a similar proposal (Frixione 2001), known as the PTIME-Cognition Hypothesis (PCH). According to PCH, human real-time cognitive functions are restricted to those which are PTIME-computable. As a consequence, PCH predicts that human brains are not capable of solving NPTIMEcomplete problems efficiently, provided PTIME = NPTIME. 1 In a sense, any task which amounts to solving an NP-complete problem pushes our cognition beyond the ultimate processing boundary of the individual human brain. See van Rooij (2008) for a broader discussion on the relevance of computational complexity for cognitive science and of PCH, in particular.
There is some cognitive-scientific research suggesting that various complexity distinctions, including PTIME versus NPTIME, are indeed reflected in human processing during cognitive tasks such as verification. Empirical relevance of computational models of human comprehension has been investigated lately, e.g., in Szymanik and Zajenkowski (2010). The authors examine the verification of simple quantifiers in natural language and give a direct empirical record linking computational complexity predictions with cognitive reality. Furthermore, in Zajenkowski et al. (2011) the same authors analyse a computational approach to quantifiers as an explanation for certain impairments in schizophrenia.
Recent investigations also seem to confirm predictions of PCH in the context of sentence verification. Earlier theoretical research has revealed that certain everyday language constructions-simple as they may seem-turn out to be NP-complete (Mostowski and Wojtyniak 2004;Sevenster 2006;Szymanik 2010). According to PCH, the inherent processing constraints of the brain should make verification of such sentences troublesome. The effect of complexity has been predicted and confirmed in the context of quantified reciprocals, based on a theoretical proposal known as the ramified Strong Meaning Hypothesis.

Ramified Strong Meaning Hypothesis
Originally, Strong Meaning Hypothesis (SMH) was proposed in the context of reciprocal expressions (Dalrymple et al. 1998): essentially, it predicted that logically stronger readings of these expressions should be preferred, as long as they fit the context of interpretation. Szymanik has observed that the raw SMH may be compromised by constraints of the human brain: having to choose more expressive meaning which is hard to process may put too high demands on our cognitive capacities (Szymanik 2010). The ramified SMH takes this caveat into account: a multi-quantifier sentence should be assigned the strongest truth conditions that match the context of interpretation and are easily processable. Szymanik (2010) observes that the ramified SMH leads to interesting predictions concerning verification of ambiguous constructions with NP-complete (difficult) and PTIME-computable (easy) readings: in some situations, human subjects may perform shifts from hard to easy semantics to avoid dealing with an overly complicated verification problem, even if the original SMH dictates otherwise. Interestingly, the ramified SMH has received some empirical support in experiments with human participants (Schlotterbeck and Bott 2013): as predicted, subjects have a significant tendency to avoid difficult semantic variants.

Present study
Barwise argues that the semantics of sentences such as The richer the country, the more powerful some of its officials (henceforth, Barwise-like sentences) should be given by the strong readings which express some way of embedding one ordering to another (Barwise 1979). He also shows that such properties are not expressible in first-order logic over arbitrary models. We provide new results on such constructions, including their logical strength and computational complexity, and discuss extensively what the implications are of our findings for certain pragmatic, cognitive and evolutionary approaches to meaning.
As a first step, we direct our attention to the expressibility of Barwise-like constructions. Our questions parallel those pursued by Barwise, with two exceptions. The first difference-a more substantial one-is the restriction to finite models. Switching to finite universes seems more appropriate for the analysis of everyday, pre-theoretic fragment of natural language. The second difference-a conceptual one-amounts to reformulating the original questions in the framework of generalized quantifiers theory. Strong readings define polyadic generalized quantifiers which we refer to as similarity quantifiers. Our examination leads to results extending those obtained in Barwise (1979), thus adding to a body of knowledge on definability of polyadic quantification patterns (see, e.g., Keenan and Westerståhl 1997;Hella et al. 1997;Peters and Westerståhl 2006).
A major part of our work focuses on the computational complexity of similarity quantifiers. We especially want to know whether the proposed strong readings are sound from the cognitive perspective. We show that quantifiers under examination split into two categories: PTIME-computable (feasible/tractable) and NPTIME-complete (infeasible/intractable). Most of them transpire to be of the latter kind. This line of research supplements earlier approaches to complexity of verification (Mostowski and Wojtyniak 2004;Sevenster 2006;Szymanik 2010) (see, also, Szymanik 2016. It is also worth noting that studies on polyadic generalized quantifiers are mainly concerned with the Frege Boundary and classical definability questions (see e.g. van Benthem 1989;Keenan 1992Keenan , 1996. A notable exception is Szymanik (2010).
Further, we provide an extensive discussion of what implications our results might have for certain pragmatic, cognitive and evolutionary aspects of meaning. First of all, complexity results lead us to weaker readings of Barwise-like constructions which are cognitively more plausible. Eventually, we end up with strong (intractable) and weak (tractable) readings. We recall and propose new arguments for strong readings. We also formulate a general version of SMH which allows us to derive predictions for verification of Barwise-like sentences, assuming they are indeed ambiguous between weak and strong readings. Finally, we propose a hypothesis which explains how ambiguity of a construction might arise through competing pressures of communication and cognition. If our hypothesis is correct, it provides some support for the claim that Barwise-like sentences are likely to manifest ambiguity.
The remainder of the paper is organized as follows. Section 2 contains a short discussion on the restriction to finite models and definitions of similarity quantifiers. Section 3 provides some examples of natural language sentences that are supposed to express the desired properties. In Sect. 4 we formulate main results on expressiveness and computational complexity. Section 5 provides us with basic conclusions and introduces weak readings. Section 6 revolves around ambiguity: it gives arguments for strong readings, formulates and applies the generalized SMH and outlines our trade-off approach to ambiguity. Section 7 contains conclusions and discusses some future directions. "Appendix" section presents proofs.
A significant part of the present work also appears in the second chapter of the PhD thesis by one of the authors (Kalociński 2016).

Finite models and everyday language
We will shortly discuss pros and cons of one of the major methodological assumptions held throughout the paper: narrowing semantic considerations to finite models only. If the reader is comfortable with this restriction, she can proceed directly to Sect. 2.2.
We do not claim that, in general, the semantics of natural language expressions (as, e.g., generalized quantifiers) limited to finite models is exhaustive with respect to ordinary communication. However, restricting attention to finite universes is a methodological assumption justified by the following reasons: 1. First of all, one can distinguish many more properties of various classes of expressions, using the restriction to finite interpretations. The main reason for this is that the restriction enables us to perform theoretical investigations much more simply and less ambiguously (Westerståhl 1984). This claim finds support in recent literature on the complexity of quantifiers. As Szymanik puts it: In many cases the restriction to finite interpretations essentially simplifies our theoretic considerations. (Szymanik 2016, p. 17) However, this does not seem to create the risk of oversimplification, since many of the properties of the general (i.e., including reference to infinite universes) semantics of various expressions might be already captured over finite models. 2 2. Whatever the properties of natural language expressions over infinite models are, their semantics in finite interpretations at least constitute an important and common part of the linguistic practice (Mostowski and Szymanik 2012). In typical communicative scenarios, we indeed refer to finite classes of objects. In particular, the use of (generalized) quantifiers in ordinary communication most commonly occurs with reference to finite contexts. Westerståhl has expressed a similar intuition: It [restriction to finite universes] is partly motivated by the fact that a great deal of the interest of the present theory of determiners comes from applications to natural language, where this restriction is reasonable. (Westerståhl 1984, p. 154) 3. Some determiners, or proportional and comparative expressions which do commonly occur in natural language, would not make (at least without further involved clarifications and justifications for further assumptions) sense without the restriction to finite models. This point does not necessarily concern the examples of natural language constructions we consider here, but is nevertheless worth noting.
Proportional quantifiers (such as most) provide a class of remarkable examples.
4. Finally, the core sentences of everyday language are sentences which can be more or less effectively verified-otherwise they could not be processed and used as efficiently as they are. To quote Szymanik again, it is worth noting that: Even though from the mathematical point of view we can work with infinite computations, the classic study of resource bounds in such a setting does not make much sense as we would need infinite time and infinite memory resources. (Szymanik 2016, p. 17) Henceforth, whenever we speak about a model/structure/context/situation, we always mean a finite one.

Strong readings: similarity quantifiers
Let us start with the motivating example from Barwise (1979), henceforth the Barwise sentence: (1) The richer the country, the more powerful some of its officials.
According to Barwise, the above sentence expresses a certain kind of similarity between partial orders. Think of A as a set of countries ordered by < A (x < A x means "x is richer than x"), B as a set of officials (of the countries from A) ordered by < B (y < B y means "y is more powerful than y"), and R(x, y) as a relation "y is an official of the country x". Now, the logical form of (1) presents as Barwise provides some arguments indicating that sentences such as (1) essentially require second-order quantification to adequately express their meaning. We shortly mention Barwise's argumentation in Sect. 6.1, enriching it with some arguments of our own.
Below we give definitions of various similarities between partial orders. Some of these definitions pertain to Barwise's original formulation while other go beyond it. We also frame the definitions in the spirit of the generalized quantifiers theory, obtaining polyadic quantifiers which we refer to as similarity quantifiers.
Let σ = (A, < A , B, < B ) be a relational vocabulary, where A, B are 1-place and < A , < B are 2-place predicates. We interpret the symbols so that (A, < A ), (B, < B ) were strict partial orders (observe that the required properties are easily expressible in F O). We refer to such σ -models as to double partial orders.
One partial order may be similar to another one in various ways. The similarities we consider are: homomorphism, injective homomorphism and embedding. The following second-order σ -sentences express the existence of homomorphism, 1-1 homomorphism and embedding from (A, < A ) to (B, < B ): Definition 1 Let t = (n 1 , n 2 , . . . , n k ) be a k-tuple of positive integers, k ≥ 1. A Lindström generalized quantifier of type t is an isomorphism-closed class Q of structures such that if M ∈ Q then M = (U, R 1 , R 2 , . . . , R k ), where U is the universe and R i is an n i -placed relation on U , for i = 1, 2, . . . , k. A generalized quantifier of type (n 1 , n 2 , . . . , n k ) is called polyadic, if n i > 1, for some 1 ≤ i ≤ k.
Observe that the classes of double partial orders in which the (1a), (1b) and (1c) conditions hold are isomorphism-closed. Hence, the respective classes are generalized quantifiers, hereinafter denoted by H, H 1-1 , E, accordingly. The type of these quantifiers is (1, 2, 1, 2).
Let σ R = (A, < A , B, < B , R) be relational vocabulary σ enriched with a 2-place predicate R. Symbols A, B, < A , < B are interpreted as in double partial orders. We require that R ⊆ A × B. We say that R denotes the coupling relation (between A and B). We refer to such σ R -models as to coupled partial orders.
The concept of a coupled partial order is richer. The coupling relation R ⊆ A × B makes it possible to introduce new types of similarities between partial orders. In what follows, we define similarities that are restricted by the coupling relation. Given a coupled partial order, let R a denote the set {b ∈ B : R(a, b)}. R induces an indexed family of sets {R a } a∈A . Let us formulate the following requirement: for each a ∈ A, the similarity function is not allowed to assume values outside R a . In other words, we require that the similarity function, say f , is such that each a ∈ A is in the relation R with the value f (a). The following second-order σ R -sentences express the existence of homomorphism, 1-1 homomorphism and embedding that are restricted by the coupling relation: The classes of (finite) coupled partial orders in which (2a)-(2c) hold are isomorphismclosed and thus are generalized quantifiers. This follows from the fact that they are 1 1 -definable, i.e. definable in the existential fragment of second-order logic, and isomorphisms preserve the properties definable by sentences of any finite order. 3 We denote them by H F , H 1-1 F and E F , respectively. The F subscript comes from the first letter of the word family. The family we have in mind is {R a } a∈A .
Additionally, we consider a natural condition that may be imposed on R. We refer to it as to the disjointness condition. It says that R a ∩ R b = ∅, for every a, b ∈ A such that a = b. This is expressed by If each of the conditions (2a)-(2c) is taken in conjunction with the disjointness requirement, we obtain the generalized quantifiers which we denote by H DF , H 1-1 DF and E DF , accordingly. The DF subscript comes from the first letters of disjoint family. The type of these quantifiers is (1, 2, 1, 2, 2). Trivially, Observe that E DF might as well be defined by the conjunction of the disjointness condition and

Examples
Which similarity quantifiers are expressible in everyday language? We present a few simple examples which suggest that at least some of these similarities are expressible, provided that Barwise's interpretation of (1) is correct. Some examples are based on the comparative construction the (more) …the (more) …, already used in Barwise (1979). 4 Further examples are based on slightly different ideas.

Homomorphism quantifiers
Let us start with a first-order example that can naturally lead to the Barwise sentence (Barwise 1979): (2) The richer the country, the more powerful its ruler.
Let A stand for countries and B for rulers. Countries are ordered by being richer < A , rulers-by being more powerful < B . Let f denote the function which assigns to each country its ruler. Now, (2) may be read as: As for the Barwise sentence (1), a conceivable reading says that we may assign to each country one of its officials in such a way that the richer the country the more powerful is the assigned official. Thus, in terms of logical form, (1) can be read similarly to (4) except that f is not a first-order logical constant (usually referred to as a "function symbol"), but a second-order function variable, quantified existentially. We must include the explicit use of R denoting the relation "y is an official of x" because for any given country a, f is allowed to assume values only from R a . A conceivable reading of (1) is thus (2a) which boils down to H F . If we agree that countries have disjoint sets of officials (disjointness condition), the semantics of the Barwise sentence is H DF . Perhaps a more natural example of H DF would be, for instance: (3) The richer the art dealer, the more famous are some of the paintings in her gallery. 5 It is rather natural to expect that different galleries do not feature the same painting at the same time.
To drop the disjointness condition, consider the following sentence: (4) The wiser the professor, the higher the remuneration of some of her students.
Let A stand for professors, B for students and R ⊆ A × B for the relation associating professors with their students. Professors are partially ordered by being wiser < A , students-according to their remuneration < B . A conceivable reading of (4) says we may assign to each professor one of his students in such a way that the wiser the professor, the higher the remuneration of the assigned student. It is perfectly possible that two professors have the same students, so the chosen relation does not make {R a } a∈A disjoint. Ideally, {R a } a∈A could be any family of sets of students whatsoever. Hence, the semantics of (4) is interpretable as the quantifier H F . We now turn to raw homomorphism. We need to eradicate R to allow the similarity function to assume its values from the whole B. It is not easy to find natural examples of sentences expressing this property. Getting rid of R may result in losing the connection between the antecedent and the consequent and thus obtaining an infelicitous example. It is therefore crucial to somehow preserve the link between objects from A and B without even mentioning it in a sentence. Moreover, this link must be of particular nature: any object from A should be connected with any object from B.
Consider a group of students writing an exam consisting of several questions ordered by the examiner on a scale of difficulty (say, by indicating the number of points one can earn by answering the question correctly). Assume there are more examination questions than students writing the exam. It is only necessary to solve only a fraction of all questions to obtain a given mark, as long as the fraction accumulates to an appropriate number of points. After the exam, each student is required to fill in a form indicating how motivated she was during the exam (say, the motivation is also measured on a scale, the precise details are not relevant here). Now, consider the following sentence: (5) The more difficult a question in the exam, the more motivated some of the students are.
Let A be the questions in the written exam, ordered by difficulty < A , B-the set of students with the reported motivation ordering < B . Observe that there is no explicitly stated relation which could be interpreted as R ⊆ A × B. Implicitly, the desired connection between A and B is simply writing the exam, R = A × B. However, this information is obvious from the context so there is no need to mention it directly. Crucially, the ordering of difficulty has the potential to influence students' motivation, so it seems natural to think that a similarity function can assume its values in the whole set of students. Due to this property, the sentence hopefully sounds felicitous. It turns out, then, that one of the conceivable readings of (5) corresponds to H, or-as we usually write throughout the paper-to raw homomorphism.

Injectivity and embedding
Some quantifiers introduced in Sect. 2 require similarity functions to be injective. It seems, however, that this property cannot be expressed in a natural way by any simple sentence using only the correlational comparative. Instead, we use a slightly more complex construction which first introduces an injective function, and then adds similarity requirement on top of it.
Consider, for example, a situation in which a poor landowner wants to marry off his daughters. His daughters and the gentlemen who might marry them have their own preferences as to their future spouses. The father wishes to reconcile financial and romantic preferences. Specifically, he might want to know whether: (6) There is a way to match the daughters and gentlemen into happy couples, so that the more beautiful a daughter, the richer her husband will be.
The reading stating the existence of an injective function is quite natural. The second part of the sentence, specified in terms of the correlational comparative, requires that one order should be mirrored, via the injective function, in another one. In consequence, the semantics of (6) seems to boil down to H 1−1 F . Switching from homomorphism to embedding consists in enforcing injectivity and preserving the ordering in both directions. The latter condition can perhaps be achieved by introducing the adverbial construction exactly/precisely which is often used to express equivalence. However, enforcing injectivity seems to be an issue, just as in attempts to provide natural examples of injective homomorphism. 6 We have two examples that we would like to share.
(7) Those professors, some of whose students earn higher salaries, are exactly the wiser ones.
Apparently, this sentence is grammatical, but it provokes mixed reactions-usually, it sounds odd to people. For sure, it is highly unusual in everyday language use. If its logical form can be captured by means we developped earlier, then it would be most likely something along the following lines: with A standing for professors ordered by being wiser < A , and B standing for students ordered according to their salaries < B . Observe, however, that f is not necessarily injective. Another problem with the above sentence is that the intended reading is clearly not the only one possible. For example, the sentence strongly suggests an interpretation in which we should determine whether the set denoted by the phrase Those professors, some of whose students earn higher salaries has a given property. This interpretation does not clearly lend itself to the above analysis. The next example is a conversation which naturally involves a Barwise-like construction: (8) -You know, there are worse and better prime ministers...
-Which prime ministers do you consider to be the better ones? -Precisely those with some of the members of their cabinets being more professional! This example, however, suffers from the same issues as (7).

Definability and complexity
This section provides some logical and computational classification of similarity quantifiers (defined in Sect. 2). Proofs of the theorems can be found in the Appendix ("Appendix" section). Our considerations are driven by questions concerning logical strength and ease of processing, key components that may affect the interpretation of a sentence, as predicted (for other constructions) by SMH (Dalrymple et al. 1998) and ramified SMH (Szymanik 2010). Barwise (1979) proved that the homomorphism between partial orders is not expressible in elementary logic over arbitrary models (i.e., there is no first-order sentence which is true precisely in models where such a homomorphism exists). What we prove is that similarity quantifiers are not expressible in elementary logic over finite models.
What can be said about the computational complexity of similarity quantifiers? Recall that, ultimately, we are interested in whether similarity quantifiers are sound from the cognitive perspective. PTIME-Cognition Hypothesis (van Rooij 2008) provides us with a theoretical linkage between complexity and cognition (see Sect. 1.1), and gives us the main reason for asking about PTIME-computability.
Based on definitions from Sect. 2, similarity quantifiers are expressible in the existential fragment of second-order logic. Hence, by Fagin's theorem (Fagin 1974), they are in NP. Assuming that P = NP, we lack an argument for (or against) feasibility of the quantifiers in question.

Theorem 4 H is in P.
An interesting consequence of these results is that they suggest a dichotomy, dividing similarity quantifiers into either tractable or intractable (see, also, de Haan and Szymanik 2015).
H differs from other quantifiers defined in Sect. 2 in two aspects.
which restricts the behavior of the similarity function. Theorem 5 shows that these two aspects make a significant difference in computational complexity (if P = NP).

Interim conclusions
A formally interesting result is that similarity quantifiers, to be captured exactly over finite structures, require non-elementary expressive power, namely the existential fragment of second-order logic. This result extends insights already obtained by Barwise for arbitrary models. We believe, however, that-at least in the context of natural language constructions that are considered here-arguments that work only for finite models are a better fit to the actual everyday language use, which, for the most part, deals only with finite contexts.
What can we say about cognitive plausibility of the strong readings? To shed some light on this question, we have pinpointed computational complexity of their verification-a paradigmatic task occurring in language use. By PTIME-Cognition Hypothesis (see Sect. 1.1) and Theorem 5, verification of similarity quantifiers is, in large part, infeasible for the human brain. In other words, our results left us with the conclusion that almost all strong readings, as initially proposed by Barwise, and further developed in Sect. 2.2, are not sound from the cognitive perspective. There is one exception, namely the quantifier corresponding to raw homomorphism: its verification is tractable (Theorem 4), which renders it as a cognitively plausible candidate for meaning. These results, when situated in the broader cognitive context, amount to a good classification of similarity quantifiers with respect to ultimate bounds of human individual cognition.
What happens if the meaning of a sentence is intractable? Can it constitute one of the sentence meanings at all? Arguments from inference (discussed further in Sect. 6.1) suggest that intractable readings do occur in reasoning. 7 This is perhaps not surprising, as our complexity results are not concerned with inference (in fact, a similar phenomenon has been observed in the context of the Hintikka sentence [see Mostowski 1994; Mostowski and Wojtyniak 2004]). What is crucial is whether intractable readings can occur in our referential intuitions or, more specifically, in actual verification.
In Mostowski and Wojtyniak (2004) the authors conclude that the intractability of the strong reading of the Hintikka sentence renders its referential meaning either undefined, or-otherwise-different than the strong one. 8 An empirical approach to a similar question (Schlotterbeck and Bott 2013) suggests that intractable readings actually appear in our referential intuitions. 9 Interestingly, as predicted in Szymanik (2010), the effect of complexity manifests precisely in verification, a task corresponding directly to the intractable problem in question. It transpires, then, that instead of entirely discarding intractable readings (as predicted in Mostowski and Wojtyniak 2004), people use them significantly less often when dealing with larger models [six 7 This matter might be a subject of further empirical scrutiny. 8 The distinction between referential and inferential meaning, as used in Mostowski and Wojtyniak (2004), is never made precise. Nevertheless, the idea behind this distinction seems clear: referential meaning of a sentence includes, for example, procedures for its direct verification. In contrast, inferential meaning of a sentence includes procedures allowing us to explore its inferential connections to other sentences. See, also, our remarks on indirect verification in Sect. 6.1.2. 9 The authors propose a picture completion task in which participants are asked to complete a graph of a situation to make a given sentence true. Obviously, this is not verification and purposely so: the whole idea is to get to know whether participants entertain intractable readings through a task that is tractable. objects as opposed to four in Schlotterbeck and Bott (2013)]. Extrapolating these results to the present study, we lean towards the claim that intractable readings of Barwise-like sentences are not entirely excluded from potential candidates for meanings. In particular, infeasible readings can occur in verification but mostly when dealing with smaller contexts.

Weak readings
What happens if the verification problem is too difficult in a given situation? As suggested in Szymanik (2010) and evidenced in Schlotterbeck and Bott (2013), language users might shift towards other available meanings which are easy to verify. Another good example is the two-way reading of Hintikka-like sentences, which language users seem to be endorsing (Gierasimczuk and Szymanik 2009). This leads us to hypothesise that there are perhaps other conceivable semantic variants of Barwise-like sentences which, unlike intractable strong readings, are cognitively more plausible.
Consider, for example, the following first-order formula: This is the weak version of (2a). Crucially, (5) follows from (2a) but not the other way round. Hence, in a sense, the weak reading approximates the strong one. The difference between second-order and first-order readings becomes apparent in specific situations (convince yourself that in the model presented in Fig. 1, the sentence (2a) is false, whereas (5) is true). There are also weak variants of other similarity quantifiers that are defined in Sect. 2.2. The reader should find them without difficulty. The proposed weak reading is just one example of a sentence (in a sense, the weakest one) that approximates the strong reading. Consider, for instance, the following firstorder interpretation of the Barwise sentence: This sentence is even stronger than (5): (6) implies (5) but not vice versa. Moreover, as opposed to (5) (6) is true. In general, one can provide increasingly stronger first-order readings, each one becoming closer to the strong reading. However, this approximation process is substantially restricted: by Theorems 1, 2 and 3, to express an appropriate similarity between partial orders in one sentence, we need non-elementary expressive means-adding more sophisticated elementary conditions cannot do the job. 10 In this sense, using existential second-order quantification in strong readings is not accidental.
Since model-checking for first-order sentences is PTIME-computable (Immerman 1999), PTIME-Cognition Hypothesis implies that verification of weak readings is feasible for the human cognitive system. As such, weak readings are cognitively plausible candidates for meanings that can systematically occur in actual verification.
Finally, let us remark about an important interplay between weak and strong readings. Observe that high expressive power of strong variants might actually render them more likely to be selected for communicative reasons. At the same time, semantic complexity makes them less likely to be selected due to cognitive constraints. As for weak readings, the situation is, in a sense, reversed: they are better suited to our cognitive capacities, but may be less preferred for communicative reasons. Consequently, weak and strong readings usually stay in conflict: choosing one of them gets you either high expressiveness or ease of processing, but never both. This observation forms the basis for much of our further considerations.

Are Barwise-like sentences ambiguous?
We have already remarked that strong readings might be preferred because they have clear advantage over weak ones in terms of expressiveness. In Sect. 6.1, we present further arguments for strong readings. Subsequently, in Sect. 6.2, we formu-late the generalized SMH, already anticipated in Szymanik (2010), which allows us to derive predictions for verification of Barwise-like sentences, assuming they are indeed ambiguous between weak and strong readings. Finally, in Sect. 6.3, we outline a tradeoff approach to ambiguity which, if correct, indicates that Barwise-like constructions are likely to assume both weak and strong variants.

Inferential tests
One way of checking whether a sentence admits a given logical form is to test it against commonly acceptable inference patterns. This has been done already for Barwise-like sentences, to some extent, in Barwise (1979). A similar approach has been adopted, for example, in the context of Hintikka-like sentences (Mostowski 1994;Gierasimczuk and Szymanik 2009), gradable adjectives (Kennedy and McNally 2005), or color adjectives (Hansen and Chemla 2017). 11 Barwise proposes an entailment test in favour of strong readings (Barwise 1979) (see, also, Gierasimczuk and Szymanik 2009;Mostowski and Szymanik 2012). The argument is based on his test for negation normality which builds upon the following theorem: if ϕ is an existential second-order sentence and its negation ¬ϕ is logically equivalent to an existential second-order sentence, then ϕ is logically equivalent to some first-order sentence. Hence, if a Barwise-like sentence requires strong reading to express its meaning, people should have some trouble with turning its negation to a normal form. Indeed, as Barwise reports, it is hard for people to suggest a paraphrase that is negation normal-when it is given, it often begins with There is no way which suggests that the negated sentence does not have a reading logically equivalent to an existential second-order sentence. Based on his provisional empirical results, Barwise concludes that our understanding of such sentences is driven by strong readings.
We add further evidence for strong readings. Consider the reasoning in Fig. 3. Its validity depends on the meaning of the first premise-the Barwise sentence. The conclusion is of the form where a, b, c are constants standing for USA, Poland and Bangladesh, respectively. Observe that the strong reading (2a) of the first premise implies (7). However, (7) does not follow if the first premise assumes the weak reading (5). Intuitively, the inference from Fig. 3 seems valid, suggesting that the strong reading is being used. 11 Mostowski observes that the Hintikka sentence (Some relative of each villager and some relative of each townsman hate each other) implies that each villager has a relative (and that each townsman has a relative)-a conclusion which does not follow from any reading that has been proposed by that time (Mostowski 1994). He suggests that our understanding of inferences involving the Hintikka sentence is driven by an appropriately modified branching reading. See, also, Gierasimczuk and Szymanik (2009) for further development.
The richer the country, the more powerful some of its officials.
USA is richer than Poland.
Poland is richer than Bangladesh.
Some USA officials are more powerful then some Polish officials which in turn are more powerful then some officials of Bangladesh.

Fig. 3 Inference involving the Barwise sentence
A cautionary note is worth making here: our argument from inference works provided that the strong and the weak reading, as considered above, are the only available. However, the argument is not limited only to this particular weak reading. Consider, for instance, a weak reading like (6). Obviously, if the first premise is read as (6) then the conclusion follows. Subsequently, however, one might give a similar inference pattern, involving four countries rather then three. The inference would be valid assuming the strong reading but the conclusion would not be licensed if the first premise was read as (6). Then, a better approximation could be supplied and a new inference pattern to prove it wrong-and so on. This argumentation parallels our discussion on weak readings in Sect. 5.1, and the process of approximation of the strong reading by increasingly more refined first-order interpretations.

Indirect verification
Hitherto, we have considered only non-verification scenarios. As noted in Sect. 5, direct verification of Barwise-like constructions (except simple homomorphism) is infeasible for the human brain. However, as observed by some authors, instead of using direct verification procedures, one can succeed in verification indirectly by exploring available inference patterns (Mostowski 1994;Mostowski and Wojtyniak 2004;Mostowski and Szymanik 2012). 12 Consider the reasoning from Fig. 4. Since the premise is expressible in firstorder logic, it is feasible for verification. This inference is also valid (Proposition 1, "Appendix" section). Observe that the premise suggests a particular certificate (similarity function) which makes the conclusion true: sending each country to its king. Now, consider the reasoning in Fig. 5. The intended model of this scenario consists of musicians, partially ordered by being more famous, and pieces of music, partially ordered by being more beautiful. Again, the premises are first-order and thus feasible for verification. The inference is also valid (Proposition 2, "Appendix" section). Observe, however, that the premises licence the conclusion also under the weak reading. Figure 6 provides an example of inference which is valid only when the conclusion assumes the strong reading (Proposition 3, "Appendix" section). The intended model Every king is more powerful than all officials of the countries which are smaller then his kingdom.
The bigger the country the more powerful one of its officials.

Fig. 4 Example of indirect verification of the Barwise sentence
John composed only one piece in his lifetime.
There is nothing more beautiful than John's music. Some composers are more famous than John.
It is not the case the more famous the composer the more beautiful are some of his pieces.

Fig. 5 Example of indirect verification of the (negated) Barwise sentence
Each student wrote two essays and took the final exam.
Tom's first essay was the worst one in the class. However, his second essay was the best.
At the final exam, some students scored higher and some lower than Tom.
It is not the case that the higher the student scored at the final exam, the better one of his essays was. consists of students, ordered according to the final examination scores, and students' essays, ordered according to instructor's evaluation. Again, the premises are first-order and thus easy to verify.
Crucially, the inference from Fig. 6 is not valid under the weak reading of the conclusion. To see this, it suffices to look at Fig. 1 and interpret a 1 , a 2 , a 3 as students (Tom = a 2 ) and the numbers 0, 1, 2, 3, 4, 5 as essays (ordered according to <). In such a model, the premises are true. However, as we have argued in Sect. 5.1, the weak reading of the sentence The higher the student scored at the exam, the better one of his essays is would be true, and hence the conclusion in inference from Fig. 6 would be false (under the weak reading).
Validity of inferences from Figs. 4, 5 and 6, and tractability of their premises, ensure that establishing the truth value of positive or negative instances of intractable Barwiselike sentences might be easy, provided appropriate inference patterns are available in a given scenario. This way one can solve an intractable verification task by taking an indirect, inferential approach.
Although we have provided only a few examples of indirect verification, it is worth mentioning that by the indirect verifiability thesis (Mostowski and Szymanik 2012), Barwise-like sentences can be verified indirectly whenever they happen to be true. This follows from our complexity results and from the thesis itself: all sentences having logical forms expressible in existential fragment of second-order logic (equivalently, sentences whose verification is NPTIME-computable) are indirectly verifiable.
f of the country. The richer the country, the more powerful The richer the country, the more powerful one of its officials.

Fig. 7 Indirect verification
According to Mostowski and Szymanik (2012), indirect verifiability of a sentence means that it can be justified through some inference having tractable premises. How can it be done? Mostowski and Szymanik have not worked out their ideas in too much detail. The gist of the argument is based on the characterization of the class NPTIME in terms of PTIME-computable certificates which can be somehow translated into practical inference patterns. Following their example-based approach, consider the inference pattern from Fig. 7. If f is actually given, as in the sentence The richer the country, the more powerful its ruler [the ruler of the country], verification of the premise is tractable, and hence the conclusion can be verified indirectly. Another example of inference pattern allowing us to justify a Barwise-like sentence is given in Fig. 4.
Interestingly, Mostowski and Szymanik emphasise a stronger claim: sentences that are indirectly verifiable are precisely those whose verification is NPTIME-computable. If this is correct, we were just lucky in finding our examples of tractable inference patterns having negated Barwise-like sentences as conclusions (Figs. 5,6). In general, this cannot be done [see, also, Ristad (1993) for a more general account of the relevance of NPTIME to natural language]. 13

Generalized SMH
The original version of SMH (Dalrymple et al. 1998) and its further developments (Winter 2001), follow from more general considerations concerning language use. The original SMH states that a quantified reciprocal sentence should be assigned the strongest available meaning, consistent with the information supplied by the context. Uncontrovertially, SMH may be viewed as an instance of the Gricean Maxim of Quantity (Grice 1975). The speaker producing a potentially ambiguous statement is legitimized in doing so as she tries to be as informative as needed, and thus selects the strongest meaning that matches the context of a conversation. The hearer, driven by a similar maxim in interpretation, selects the strongest matching meaning. Eventually, interlocutors communicate successfully.
The ramified SMH adds the aspect of simplicity: a multi-quantifier sentence should be assigned the strongest matching meaning that is easy to process (Szymanik 2010). Again, a tendency for choosing simple meanings may be viewed as a realization of a more general principle such as the principle of least effort (Zipf 1949). In our case, 'simple' is understood as 'tractable', which is justified by the PTIME-Cognition Hypothesis (van Rooij 2008).
Abstracting away from the peculiarities of a given construction (be it quantified reciprocal, plural predication or multiple quantification), we obtain a generic pragmatic principle that can be roughly stated as follows: Generalized SMH When dealing with an ambiguous construction, its stronger meanings are preferred as long as they fit the context of interpretation and do not compromise ease of processing.
Overall, the meaning resulting from the application of the generalized SMH comes about as a trade-off between informativeness and cognitive simplicity.

Application to Barwise-like sentences
If the proposed readings (see Sects. 2, 5) are indeed present in referential intuitions of human participants, we should observe a considerable difference in subjects' responses during verification of constructions having tractable and intractable strong readings, especially when dealing with larger models (crucially, "larger" does not mean impractically large: empirical studies suggest that the effect of complexity becomes visible even in practical scenarios consisting of four versus six objects in total, as in Schlotterbeck and Bott 2013). Intractability of a strong reading should lead human subjects to process a weak reading. For constructions having tractable strong readings, such as (5), this effect should be considerably weaker: human subjects should prefer to execute the strong reading as its usage is not compromised by cognitive constraints.
Note that if ∀a ∈ A R a = B holds, the strong readings (2a-2c) are actually equivalent to (1a-1c), respectively, and thus tractable. It seems then that the problem of verification, when restricted to models in which this condition is satisfied, should be easy to process. For this reason, if one wanted to test our predictions empirically, perhaps it would not be necessary to feed subjects with different sentences but rather with different kinds of models. Still, however, input sentences should feel natural in both kinds of situations and it might be challenging to come up with such examples.

Trade-off perspective on ambiguity
Ambiguity, especially in the context of multiple versions of SMH, is-technically speaking-an independent variable, and as such is not subject to explanation. What SMH theories are focused on is a mechanism of disambiguation-a hypothetical pragmatic tool guiding us in our search for the appropriate meaning in a given context. What we want to propose here as a speculation is to reverse the reasoning and to look at the possibility of explaining ambiguity by the appeal to the same pressures that play a central role in the generalized SMH.
Notice that the pressures that guide language users in the selection of semantic variants of a construction in various situations, as predicted by the generalized SMH, might be also the very reason of acquiring by the construction multiple meanings in the first place. At the most general level, our proposal boils down to the following: Hypothesis Ambiguity of a construction might be an optimal response of a linguistic system to tensions between competing semantic variants, provided that different variants withstand different selectional pressures that are involved in its usage.
Our hypothesis fits into the long tradition of evolutionary accounts, dating back to at least (Zipf 1949), which seek to explain properties of natural languages in terms of trade-offs between (extra-)linguistic selectional pressures (Christiansen and Chater 2016;Kirby et al. 2015).
To understand more clearly what our hypothesis means, consider a Barwise-like sentence with two potential semantic variants: an intractable strong reading and a tractable weak reading. If the construction assumed only the strong reading, it would be satisfactory for communication but its usage would be substantially narrowed due to cognitive pressures. On the other hand, if the construction assumed only the weak reading, its usage would be satisfactory for cognition but less so for communication. It seems that ambiguity is overall a better solution: whenever it is doable, one might use communicatively efficient strong reading; otherwise, one has always access to its approximation, the weak reading. Overall, ambiguity seems to be a win-win situation.
If our proposal is correct, we should expect that Barwise-like constructions are likely to manifest ambiguity, with strong and weak readings being preferred by communicative and cognitive pressures, respectively. This matter, however, requires further empirical scrutiny.

Conclusions and perspectives
We have provided results on expressiveness and computational complexity of strong readings for constructions such as The richer the country, the more powerful some of its officials, which, according to Barwise, express the existence of some kind of embedding between partial orders. Here are the main conclusions: 1. Strong readings cannot be expressed in first-order logic over finite models. 2. All strong readings, except simple homomorphism, are intractable; as such, they are not sound from the cognitive perspective-they can be verified effectively only against very small contexts. 3. We propose weak (first-order) readings: they are tractable and thus cognitively plausible. However, they express the desired similarities only approximately, and thus are less favoured by communicative pressures. 4. There are arguments in favour of strong readings based on inference and indirect verification. 5. Assuming that Barwise-like sentences are ambiguous between weak and strong readings, the generalized Strong Meaning Hypothesis predicts that more expressive variants should be selected as long as their usage is not compromised by cognitive constraints. 6. We hypothesise that the ambiguity of a construction might be an optimal solution of a linguistic system provided that competing semantic variants withstand different selectional pressures. This hypothesis, and our results, imply that Barwise-like sentences are likely to manifest ambiguity.
There are questions that naturally arise in the context of the present study. Here, we mention just two of them.
Firstly, a natural continuation of the present work is to generalize logical considerations in this paper. For example, one might investigate whether a general dichotomy result holds for a natural but more broadly construed class of quantifiers which includes those considered here. This question is especially motivated by a similar work on Ramsey quantfiers (de Haan and Szymanik 2015, to appear).
Secondly, it would be desirable to perform experiments, in a way similar to Schlotterbeck and Bott (2013), to see whether our predictions are correct. One set of predictions stems from the generalized Strong Meaning Hypothesis. Crucially, it assumes actual ambiguity of Barwise-like sentences and focuses on systematic meaning shifts resulting from the interplay between logical strength and ease of processing. Testing these predictions would count as an empirical evaluation of the generalized SMH understood as a generic pragmatic principle, based on fundamental and universal constraints of communication and cognition.
Another set of predictions stems from our trade-off approach to ambiguity-a theoretical attempt at explaining how ambiguity of a construction might come about in the first place. Testing these predictions requires that we have at our disposal a semantically undetermined construction admitting (at least) two readings-one logically strong but cognitively difficult, and another one which only approximates the strong reading but is cognitively easy. It is not clear whether Barwise-like sentences are suitable for this task. What speaks in favour of their suitability is that they provoke mixed reactions. When commenting about (1), Barwise says: "Some people just don't understand it. Typically they ask something like "Which official?" Thus, they are searching for a Skolem function, as you would expect." Anyway, supposing that we have at our disposal a semantically undetermined construction satisfying the above constraints, it would be interesting to discover what would happen in conditions which vary with respect to the relative strength of communicative and cognitive pressures (the latter might be controlled through the size of the models people are supposed to deal with, as in Schlotterbeck and Bott 2013). It seems reasonable to expect that, ideally: (i) high communicative pressure and low cognitive pressure would result in a construction assuming mostly the strong variant (because of its enhanced expressiveness), (ii) low communicative pressure and high cognitive pressure would result in a construction assuming mostly the weak variant (because it is easy to process), (iii) interwoven communicative and cognitive pressures would result in a construction assuming both weak and strong variants (as one is expressive and another is easy), thus leading to ambiguity.
Open Access This article is distributed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made.

Appendix Expressiveness
We prove that similarity quantifiers are not F O-definable over double and coupled partial orders. We use two techniques from finite model theory: reductions and locality (Libkin 2004 Proof Let Q ∈ {H, H 1-1 , E}. The proof is by contradiction. Assume Q is F Oexpressible over double partial orders. We show that the parity is expressible in F O over linear orders. This yields a contradiction as the parity is not F O-expressible over linear orders (Libkin 2004).
Let ϕ be a first-order σ -sentence expressing Q. Convince yourself that ϕ contains occurrences of A and B. Let τ = (<) be a vocabulary of linear orders. We construct an F O τ -sentence ψ which expresses the parity over linear orders. Let x be a variable not occurring in ϕ. In what follows, X Y means that expression X is to be substituted by expression Y . We construct ψ 1 (x) and ψ 2 (x) by applying to ϕ the substitutions rules (8a) and (8b), respectively: Now, let ψ denote the τ -sentence ∃ x (ψ 1 (x) ∧ ψ 2 (x)). We claim ¬ψ expresses the parity over linear orders. It suffices to observe that ψ expresses its complement. Observe that ψ says there is an element x such that all elements above x may be homomorphically mapped to all elements below x and vice versa. Since we work in strict linear orders, it simply means that the set of all elements above x has the same cardinality as the set of all elements below x. Hence, together with x, the whole universe is odd.
Proof The argument is almost the same as for the Theorem 1. The only difference is that we extend (8a) and (8b) with additional rules R(y i , z j ) x < y i ∧ z j < x and R(y i , z j ) y i < x ∧ x < z j , respectively. 14 The technique for proving Theorems 1 and 2 does not apply easily for showing F Oinexpressibility of the quantifiers H DF , H 1-1 DF , E DF . Instead, we use the Hanf-locality technique. We sketch the methodology and then prove the theorem.
Let ρ be a relational vocabulary. Let M be a ρ-model. The Gaifman graph of M is defined as G(M) = (|M|, E), where for every a, b ∈ |M|, E(a, b) iff a = b or there is a predicate R in ρ such that for some tuple t ∈ R M , a and b occur in t. The distance d M (x, y) is understood as the length of the shortest path from x to y in G(M). The ball of radius r around a ∈ |M| is defined as B r then we write A d B which means that the two structures locally look the same.
If A d B, then the cardinalities of both structures is the same, and the neighborhoods of distinguished elements a and b in the structures A and B, respectively, are isomorphic. We say that a class of ρ-structures Q is Hanf-local if there exists a number d ≥ 0 such that for all ρ-structures A, B: The smallest d for which the above holds is called the Hanf-locality rank of Q. Using Hanf-locality to prove that a class of structures Q is not definable in a logic L amounts to proving the every L-definable class of structures is Hanf-local and that Q is not Hanf-local. It is known that every F O-definable class of structures is Hanf-local. We use it below. For details on locality, see Libkin (2004).

Theorem 3 H DF , E DF are not F O-definable over coupled partial orders.
Proof The proof is by contradiction. Let Q be one of the above quantifiers. Assume that Q is F O-expressible over coupled partial orders. Hence, Q is Hanf-local (Libkin 2004). Let L n , for n > 0, denote the type of strict partial order in Fig. 8. We call it a bridge. For each n > 0, we define the length of L n , denoted by |L n |, as 2n. Let d be the Hanf-locality rank of Q. Set m = min{|L n | : n > 0 ∧ |L n | > 2d}. We define two ·→·←· repeated n times Set R(a i , b j ) iff i = j or j = i + 3m. Convince yourself that R a ∩ R a = ∅, for each a, a ∈ A such that a = a . To define R , consider two isomorphisms Convince yourself that the family {R a } a∈A is disjoint. This ends the definition of C and C .
Define a bijection f : A ∪ B → A ∪ B as follows. Label A with a 1 , a 2 , . . . , a 3m , . Overall, there are at most four isomorphism types of d-neighbourhoods of points in C and C . The types correspond to the following conditions (by an edge we mean < A -edge, < B -edge or R-edge): a) c has 4 out-edges (c ∈ A, c has 2 out-< A -edges and 2 out-R-edges), b) c has 2 in-edges and 2 out-edges (c ∈ A, c has 2 in-< A -edges and 2 out-R-edges), c) c has 3 in-edges (c ∈ B, c has 2 in-< B -edges and 1 in-R-edge), d) c has 1 in-edge and 2 out-edges (c ∈ B, c has 2 out-< B -edges and 1 in-R-edge). Clearly, these are all possible immediate surroundings of an arbitrary point c ∈ A ∪ B in models C and C .   A , A , < A ), starting from f (c). Let s be the distance between the two points one can reach in this way. Clearly s ≤ 2d. Another possible path between these points (either in G(A) or G(A )) has length 3m − s ≥ 3m − 2d > 3m − m > 4d. Hence, d-neighbourhoods of c and f (c), restricted to A and A respectively, are simply isomorphic parts of bridges with c and f (c) as their central points, where the endings of the bridges do not connect or overlap because the distance d is to small to make this happen. Now, consider how we move from c at distance d using R-edges and < B -edges as well. c has 2 out-R-edges which send it to different points b, b ∈ B separated by the distance 3m in G(B), where B = (B, B, < B ). This is easily visualized in Fig. 9, where b and b lie on the opposite sides of the hexagon. Now, the movement from c at distance k in a given direction within A is mirrored by the relation R by the two movements from b and b in the same direction at distance k in B (see Fig. 9). The same remark applies to the movement from f (c) ∈ A except that R sends f (c) to the points in B which lie on different triangles and thus the distance between them is isomorphic to the structure in Fig. 10. Getting back to C, we see that if we start from c, we explore B at most at distance d − 1 from b and b . Let s be the distance between the two points that one can reach from c in G(C) by going at most at distance d. Clearly, s ≤ 2d. There are other paths connecting the two points, but they are not included in N C d (c), because the length of these paths is greater than 2d. Hence, N C d (c) actually looks like in Fig. 10.
Going through other cases, we eventually show that C d C . However, C / ∈ Q and C ∈ Q, which contradicts the Hanf-locality of Q.

Semantic complexity
Definition 2 Let A = (A, < A ) be a finite strict partial order. The height of A, denoted by h(A), is the number of vertices in the longest chain in A.

Lemma 1 h is in P.
Proof The argument uses the Sedgewick trick (Sedgewick and Wayne 2011) for finding the longest paths in a directed graph with the help of the Ford-Bellman algorithm. The trick rests on the observation that the shortest path (in terms of weights) in an acyclic directed graph with all weights multiplied by −1 is the same as the longest path in the original graph. The Ford-Bellman algorithm is designed for acyclic weighted directed graphs. Strict partial orders are acyclic directed graphs, so the shortest path in a strict partial order with negative weights always exists. Now, the application of the trick to our problem is straightforward. Take a strict poset X = (X, < X ) as input. Construct a weighted strict poset X = (X, < X , w) by labelling all edges in X with −1 (which means we set w(x, y) = −1 for all x, y ∈ X such that x < X y). For every v ∈ X , run the Ford-Bellman algorithm and find the shortest path from v to all other vertices in X . Return the number of edges of the shortest path in X . The construction of X from X is in P, the Ford-Bellman algorithms works in polynomial time, hence h is in P.

Lemma 2 Let A, B be strict posets. There is a homomorphism from
Proof Let A, B be strict posets.
(⇒) Let f be a homomorphism from A to B. Observe that f maps every path in A into an isomorphic path in B. Hence h(A) ≤ h(B).
(⇐) Assume h(A) ≤ h(B). Let A be the strict poset obtained from A by adding new vertex a, drawing edges from a to every source vertex in A (a source vertex is a vertex with no ingoing edges) and taking the transitive closure of the resulting relation. For i = 1, 2, . . . , h(A) define A i = {v ∈ A − {a} : the longest path from a to v in A has length i}.
We show that But then au 1 u 2 . . . u i v is a path in A from a to v and it has length i + 1, so v ∈ A i+1 , contrary to our assumption.
We show that for every is a partition, u ∈ A i and v ∈ A j , for some unique i, j ∈ {1, 2, . . . , h(A)}. We show that i < j. To prove it, assume i ≥ j. But then we have a path au 1 u 2 . . . u i = u of length i and au 1 u 2 . . . u i v of length i + 1, so v ∈ A i+1 . Hence v ∈ A j ∩ A i+1 , where j = i + 1, which contradicts the fact that {A i } 1≤i≤h(A) is a partition.
We are ready to define a homomorphism from A to B. Let b 1 , b 2 , . . . , b h(A) be a path in B. The desired homomorphism f is defined as follows: f (A i ) = {b i }, for i = 1, 2, . . . , h(A) (see Fig. 11). Since {A i } 1≤i≤h(A) is a partition of A, f is a function. We show that f is indeed a homomorphism. Let x, y ∈ A. Assume x < A y. Then there are unique i, j such that x ∈ A i , y ∈ A j and 1

Theorem 4 H is in P.
Proof Corollary from Lemmas 1 and 2.
Q and Q R are definable by existential SO-sentences over the signature σ = (A, B, < A , < B ) and σ R = (A, B, < A , < B , R), respectively (see Sect. 2). By the Fagin theorem (Fagin 1974), Q and Q R are in NP.
We prove that Q and Q R are NP-hard. We do this by showing that 3SAT is polynomially reducible to Q and Q R . We demonstrate polynomial constructions which, given an arbitrary 3CNF-formula ϕ, output a double partial order D ϕ and a coupled partial order C ϕ such that: be an arbitrary 3CNF-formula, where k is the number of clauses, a i , b i , c i are literals, for i = 1, 2, . . . , k. We construct a double partial order D ϕ = (A ∪ B, A, < A , B, < B ). Let A = {v i : 1 ≤ i ≤ k} ∪ {v i j : 1 ≤ i < j ≤ k} consist of k + k 2 −k 2 elements. Let < A ⊆ A 2 be such that Obviously, (A, < A ) is a strict partial order and verifying whether given two elements of A are in < A is polynomial. To construct (B, < B ), let consist of 3k + 9 k 2 −k 2 elements. The idea is that we construct vertices from all occurrences (tokens) of the literals in the formula ϕ and we add artificial vertices for all (unordered) pairs of literals such that the elements of the pair belong to different clauses. The size of B is polynomial with respect to k. Let < B ⊆ B 2 be such that for all u, w ∈ B: (B, < B ) is easily visualized as follows. Let x i and y j be two tokens of literals from different clauses of ϕ, i < j. Formally, it means that x i ∈ {a i , b i , c i }, y j ∈ {a j , b j , c j }, i < j. If x i and y j are consistent, we add edges v x i v x i y j , v y j v x i y j . It is easy to see that < B is a strict partial order on the set B and computing the characteristic function of the relation < B is polynomial with respect to k. This ends the construction of D ϕ . C ϕ is constructed in the same way as D ϕ , except that we add the coupling relation R.
We prove (10a) and (10b). (⇒) Assume ϕ ∈ 3SAT. Hence, there is a valuation t of propositional variables in ϕ and a sequence of literals l 1 , . . . , l k such that l i ∈ {a i , b i , c i }, for i = 1, 2, . . . , k, and ∀ i ≤ k t(l i ) = 1. Hence, the literals l 1 , l 2 , . . . , l k are consistent. Let f : A → B be as follows: Clearly, f is an embedding of (A, < A ) into (B, < B ) and hence an injective homomorphism from (A, < A ) to (B, < B ). Therefore, D ϕ ∈ Q. Observe that {R a } a∈A is a disjoint family and ∀ a ∈ A f (a) ∈ R a . So C ϕ ∈ Q R .
(⇐) Observe that D ϕ ∈ H 1-1 iff D ϕ ∈ E. Assume f : A → B is an injective homomorphism from (A, < A ) to (B, < B ). Then f (A) cannot have any additional edges apart from those that are mapped by f (we prove C ϕ ∈ H DF ⇔ C ϕ ∈ E DF in a similar way). Now, observe that the conditions C ϕ ∈ H F , C ϕ ∈ H DF , C ϕ ∈ H 1-1 F , C ϕ ∈ E F , C ϕ ∈ E DF are equivalent. The disjointness of {R a } a∈A in C ϕ settles the equivalences C ϕ ∈ H DF ⇔ C ϕ ∈ H 1-1 F , C ϕ ∈ H F ⇔ C ϕ ∈ H DF , C ϕ ∈ E F ⇔ C ϕ ∈ E DF . The equivalence C ϕ ∈ H DF ⇔ C ϕ ∈ E DF is already established. This ends the argument for all equivalences for C ϕ . Now, observe that C ϕ ∈ Q R implies D ϕ ∈ Q. For the converse, assume D ϕ ∈ Q. Let f be an appropriate injective homomorphism.
Let v i , v j ∈ A, i < j. Observe that f maps v i , v j to literals from different clauses (as literals form the same clause cannot point to the same vertex). Hence, f is easily rearranged to satisfy ∀ a ∈ A f (a) ∈ R a . By definition, {R a } a∈A is a disjoint family. Therefore C ϕ ∈ Q R .
We are ready to prove the (⇐) part of (10a) and (10b). Assume C ϕ ∈ Q R . Observe . By definition of < B , f (v i ) and f (v j ) are consistent. Hence, f (v 1 ), f (v 2 ), . . . , f (v k ) are all pairwise consistent. Hence, ϕ is satisfiable. Fig. 4 is valid under the strong reading.

Proposition 1 The inference in
Proof Assume the premise is true in a model. Assign each country its king. It is easy to see that this assignment is a well-behaved similarity function: given two arbitrary countries of different size, the king of the bigger country is more powerful than the king of the smaller country (obviously, kings are countries' officials). Hence, the conclusion is true. Fig. 5 is valid under the strong reading.

Proposition 2 The inference in
Proof Assume the inference is not valid. Take a model in which the premises are true and the conclusion is false. Hence, the sentence The more famous the musician the more beautiful are some of his pieces is true. Observe that every similarity function from composers to pieces of music sends John to the only piece he composed (first premise). Consider a composer that is more famous than John (third premise). Any similarity function must send this composer to a piece of music that is more beautiful than John's piece. However, this is not possible, as nothing is more beautiful than John's piece (second premise). Therefore, the sentence The more famous the musician the more beautiful are some of his pieces is false-a contradiction. Therefore, the inference pattern from Fig. 5 is valid. Fig. 6 is valid under the strong reading.

Proposition 3 The inference in
Proof Suppose the contrary. Take a model in which the premises are true and the conclusion is false. Choose a similarity function (from students to essays) whose existence is granted by the false conclusion. Suppose the function assigns to Tom his first essay. Choose a student who scored lower than Tom at the exam (third premise). The similarity function sends this student to one of his essays which is worse than Tom's essay. However, no essay is worse than Tom's first essay (second premise). Now, suppose the similarity function assigns to Tom his second essay. Choose a student whose score was higher than Tom's. The similarity function sends this student to one of his essays which is better than Tom's essay. However, no essay is better than Tom's second essay (second premise). Either way, we obtain a contradiction. Hence, the inference pattern is valid.