Manuscript Offprint
arXiv:2611.08319An order-reversing embedding of Turing degrees into Arthur-Nimue-Merlin degrees (short version)
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
The Arthur–Nimue–Merlin degrees are a generalization of the Turing degrees introduced by Kihara as a tangible description of the partially ordered set of Lawvere–Tierney topologies on the effective topos (equivalently, subtoposes of the effective topos). They are defined in terms of a three-player game that introduces both angelic and demonic non-determinism into oracle queries. We construct an order embedding of the Turing degrees with their order reversed into the Arthur–Nimue–Merlin degrees, whose image we call the “co-Turing degrees”; we then study the order relationship of these co-Turing degrees with the (naturally embedded) Turing degrees within the Arthur–Nimue–Merlin degrees.
2012 ACM Subject Classification Theory of computation → Computability
Keywords and phrases Turing degree, Arthur–Nimue–Merlin degree, oracle, realizability, effective topos, Lawvere–Tierney topology, modality
Related Version Full version: https://arxiv.org/abs/2603.19946
Funding Jean Abou Samra: Funded by the European Union (ERC, HOTT, 101170308). Views and opinions expressed are however those of the author(s) only and do not necessarily reflect those of the European Union or the European Research Council. Neither the European Union nor the granting authority can be held responsible for them.
Acknowledgements We thank Andrej Bauer, Laurent Bienvenu, Joel David Hamkins, James E. Hanson, Takayuki Kihara, Ulysse Léchine, Mabel Najdovski, the pseudonymous MathOverflow user “Pastebee”, Arno Pauly, Andrei Romashchenko, Will Sawin, Sasha Shen, and anonymous reviewers for helpful discussions and comments. No AI tool was used in this research or in the writing of this paper.
1 Introduction
We begin with a riddle. King Arthur is desperate to know whether the Grail is in a particular French castle. He can ask arbitrary questions to the all-knowing mage Merlin, who promises to answer truthfully, but with a twist. Instead of merely answering “yes” or “no” in plain English, the mischievous Merlin provides a Turing machine, which halts if and only if the answer is “yes”. Can Arthur, a mere mortal limited by the Church–Turing thesis, find the Grail’s location before the end of days?
Indeed he can, with a simple trick: first ask Merlin whether the Grail is in the castle, then ask whether it is not in the castle. Exactly one of the two resulting Turing machines halts, and he can run them in parallel to know which one, revealing the answer.
Let us spice up the rules. Each of Merlin’s replies now consists of two Turing machines; for a “yes” answer, both or none halt, whereas for a “no” answer, exactly one halts. It
We are indebted to Will Sawin for suggesting this particularly elegant variant of the riddle.
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
2
turns out that, under these rules, no strategy can ensure that Arthur learns the answer to an arbitrary boolean question in finite time. A proof of this fact (which we give in Remark 3.7) seems to require the main technical result of this paper (Theorem 3.6), which shows that asking the question then its negation is essentially the only useful trick in a precise sense.
Context Our object of study is an extension of Turing degrees where the oracles can feature certain forms of non-determinism, as in this riddle. We call these generalized degrees the Arthur–Nimue–Merlin degrees, owing to their explicit description by Kihara using a three-player game whose players are conventionally named Arthur, Nimue and Merlin [7].² Whereas Turing degrees are defined as a quotient of oracles which are functions , Arthur–Nimue–Merlin degrees are a quotient of a richer set of oracles, namely functions . Informally, when a program that uses as an oracle makes a query to the oracle, a set is chosen in a benevolent way (“angelic non-determinism”), then a value is chosen in an adversarial way (“demonic non-determinism”), and the program receives the answer . The mathematical meaning to “benevolent” and “adversarial” is made precise by introducing a game where Arthur, a player restricted to computable strategies, is allied to Nimue, the player choosing , and both play against Merlin, the player choosing . (The details of the game are recalled in Section 2.)
While Arthur–Nimue–Merlin games were introduced recently by Kihara, they are a concrete description of objects that arose much earlier, in a different guise, in the study of realizability. To reassure the reader unfamiliar with realizability from the outset, this paper is meant to be accessible with only a background in basic computability theory, except for Section 5 where we explain how the proof of our main result can be understood from the point of view of realizability. Nevertheless, let us recall the historical link.
The effective topos, defined by Hyland, is a model of constructive mathematics — more precisely, an elementary topos with natural numbers object and thus a model of intuitionistic higher-order logic — which can be viewed as the “world of computable mathematics”. This topos contains the topos of sets, namely the “world of classical mathematics”, as a smallest non-degenerate subtopos, and in between them is an array of subtoposes, which are therefore intermediate worlds between computable and classical mathematics.
In his seminal work introducing the effective topos, Hyland associated to each Turing degree a subtopos of “-computable mathematics”. This subtopos admits a description similar to the effective topos with plain computability replaced by computability relative to (this was checked by Phoa [14]). Hyland proved that this defines an embedding of Turing degrees into subtoposes of the effective topos [4, Theorem 17.2]. However, there are many subtoposes which do not arise in this way.
As a general fact of topos theory, the subtoposes of an elementary topos are described by the so-called Lawvere–Tierney topologies (also known as modalities, local operators, or nuclei) on the topos. This characterization is already much more concrete: Lawvere–Tierney topologies on the effective topos can be defined in a simple way without reference to the effective topos, as maps satisfying a few reasonable properties to expect of an oracle (see the beginning of Section 5). Nevertheless, it remains somewhat mysterious. A first step towards a more explicit description was undertaken by Lee and van Oosten [11], who introduced the subclass of basic Lawvere–Tierney topologies on the effective topos, and described them using certain well-founded trees called sights. However, the main advance
² In [6], Kihara uses the term “extended Turing–Weihrauch degrees”. We prefer to eschew the association with Weihrauch’s name since we never deal with oracles that can only be queried once.
was made by Kihara [7], who proposed Arthur–Nimue–Merlin degrees as a considerably simpler description which encompasses all Lawvere–Tierney topologies on the effective topos. This description also sheds light on Hyland’s embedding of Turing degrees into Arthur–Nimue–Merlin degrees: it is obtained by identifying a Turing oracle with the Arthur–Nimue–Merlin oracle , (the choices of Nimue and Merlin are forced, so that Arthur is in essence using an ordinary, deterministic Turing oracle). Lee and van Oosten’s basic degrees, on the other hand, are those represented by oracles which are constant functions .
This provides a first motivation for studying Arthur–Nimue–Merlin degrees, among the many kinds of degrees that appeared in computability theory in the last 70 years (such as enumeration degrees, Medvedev degrees, Muchnik degrees, etc.): although the details of the Arthur–Nimue–Merlin game may at first appear arbitrary, in fact it arises as a more explicit description of all “reasonable” oracles, which are also all “intermediate worlds between computable and classical mathematics”.
Another motivation is that Arthur–Nimue–Merlin degrees seem to be a natural completion of Turing degrees in the sense that several notions studied in classical computability theory find a natural home in the Arthur–Nimue–Merlin degrees. For example, define if the -th program with no input and boolean output terminates and returns false, if it terminates and returns true, and if it does not terminate. This corresponds informally to having an oracle that will give Arthur the return value of a boolean-valued program that terminates, but may return either boolean for one that does not terminate.³ The Turing degrees above are exactly the so-called “PA degrees”, a classical object of study in computability (see [2, Definition 15.3.11] and [17, Theorem 10.3.3]). Furthermore, is an intermediate degree between the computable degree and the degree of the halting problem , while, famously, no natural such degree is known in the Turing degrees.
Another example is the oracle where does not depend on and consists of the cofinite subsets of . Informally, this means that Nimue chooses a natural number, then Merlin can replace it by any larger number before Arthur can see it. This example is due to Pitts [15, Example 5.8], and van Oosten proved [19, Theorem 2.2] that the functions computable from this oracle exactly coincide with the hyperarithmetical functions. These can be defined in many other ways (e.g., as the functions in the analytical hierarchy, or as the functions belonging to the -th level of the constructible hierarchy), and have been intensely studied in effective descriptive set theory, where they are the analogue of Borel functions in classical descriptive set theory.
Recently, Kihara and (Ming) Ng studied the preorder on basic Arthur–Nimue–Merlin degrees defined by when for some Turing degree , exhibiting a connection with the Katétov order in set theory [9, 10], while Ahman and Bauer explained how to understand the characterization of Lawvere–Tierney topologies on the effective topos in terms of Arthur–Nimue–Merlin games in a more conceptual way via “oracle modalities” [1], which we use in Section 5.
Contribution We make a further advance in the understanding of Arthur–Nimue–Merlin degrees by exhibiting an embedding of the Turing degrees with the opposite of their standard order into the Arthur–Nimue–Merlin degrees — in fact into the basic ones. Explicitly, this means that we define for each Turing degree a basic Arthur–Nimue–Merlin degree
³ This degree is called LLP0 by Kihara [7, Example 2.8 in published version, 2.5 in arXiv version] due to its connection with the lesser limited principle of omniscience in constructive mathematics.
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
4
coT(a), called its co-Turing degree, so that the map coT is an order-reversing embedding, i.e., for all Turing degrees . Furthermore, we show that a non-zero Turing degree is never comparable with the co-Turing degree of a non-zero Turing degree.
Our “co-Turing degree” construction provides one answer to [7, section 6, Question 1] which asked for other “interesting” basic Arthur–Nimue–Merlin degrees.
Outline Section 2 precisely describes the Arthur–Nimue–Merlin game and recalls their basic properties. This is essentially a summary of some parts of [7] but with a few inessential differences in notation and terminology. In Section 3 we define the decoding degree and coding degree associated with a promise problem and we prove our main technical result, Theorem 3.6. In Section 4, we define co-Turing degrees as a particular case of coding degrees and prove our main theorem, Corollary 4.3, according to which the mapping from Turing degrees to co-Turing degrees is an order-reversing embedding, as well as Theorem 4.5 on the incomparability of Turing and co-Turing degrees. Section 5 is devoted to reinterpreting the construction of co-Turing degrees in terms of Lawvere–Tierney topologies on the effective topos and is the only section which requires familiarity with the effective topos (after an initial recapitulation on Lawvere–Tierney topologies on the effective topos, which is self-contained).
Notations We work in classical logic unless otherwise specified. However, we still adopt the convention from constructive mathematics to call inhabited a set which has an element (this is classically equivalent to being non-empty). We write for a total function and for a partial function. In the latter case, we write to mean that is defined at , and to mean that furthermore the value equals . The powerset of is denoted by . We fix a computable Gödel coding of tuples by natural numbers, denoted . The -th partial computable function is and the -th partial computable function with oracle is . (The numbering of programs is independent of the oracles, e.g., there exists such that for all .)
The story is entirely similar for Arthur–Nimue–Merlin degrees, but the reducibility is more complicated.
► Definition 2.1. An Arthur–Nimue–Merlin oracle is a function .
Let be Arthur–Nimue–Merlin oracles. The reduction game from to is a game between three players named Arthur, Nimue and Merlin, played as follows. Arthur and Nimue are allied against Merlin. The game starts with an initial configuration, which consists of a natural number and a target set . Nimue and Merlin can see both and , while Arthur can only see . Accordingly, we call the public part of the initial configuration, and the secret part. The moves are played in the following order: Arthur, then Nimue, then Merlin play in turn, repeatedly, until Arthur, during his turn, plays a special move that ends the game (or until a player cannot play and loses). When it is his turn to play, Arthur has two kinds of moves available: either declare a natural number of his choice as the “final value”, which ends the game, or query the oracle at a natural number of his choice, the
“question”. If Arthur declares as the final value, then Arthur and Nimue win if (where is the secret part of the initial configuration), otherwise Merlin wins. If Arthur queries the oracle on a question , both Nimue and Merlin can see the question, and it is Nimue’s turn to play next. Nimue chooses a set . (If is empty, then she has no move available, so she and Arthur lose immediately.) Nimue communicates the choice of to Merlin, but Arthur cannot see it. Then Merlin chooses a reply (if is empty, Merlin has no move available and immediately loses). Both Arthur and Nimue can see , and the game continues with Arthur’s turn. If the game never ends, then Merlin wins by default.
A Nimue strategy for this game is a function taking an initial configuration and a finite sequence of moves by Merlin and Arthur to an element of to be played by Nimue. An Arthur strategy is a partial computable function taking a natural number (representing the public part, , of the initial configuration and a finite sequence of natural numbers (representing moves by Merlin) to a move to be played by Arthur (coded, e.g., as either to query the oracle for , or to declare as the final value). (If the move returned by the strategy is undefined or not of the appropriate form, then Arthur and Nimue will lose the game.)
An Arthur–Nimue strategy is a pair consisting of an Arthur strategy and a Nimue strategy. It is winning when Arthur and Nimue win the game when they play following that strategy, no matter what the initial configuration and Merlin’s moves are.⁴ The oracle is reducible to , written , when such a winning strategy exists.
This definition is due to Kihara [7, Definitions 2.13 & 2.14⁵]. Our description differs from Kihara’s in two inessential ways. The first is that for technical convenience, we used functions for the oracles instead of what is called a “bilayer function” in [7], namely a partial function , where is an unspecified set that varies from oracle to oracle (the idea being that Arthur chooses a question , Nimue chooses a “parameter” , they must ensure that is defined, and Merlin returns an element of this set). The second difference is that we consider the data as an “initial configuration” rather than an opening move by Merlin, which is immaterial but more convenient when we need to speak of the sequence of moves by Merlin.
► Proposition 2.2 (Kihara [7, Proposition 2.19⁶]). The reducibility relation is a preorder on Arthur–Nimue–Merlin oracles.
Proof. We leave reflexivity as an exercise. Assume through an Arthur strategy and a Nimue strategy , and through and . Then through the following strategy. Arthur receives and must find an element of some . He simulates until it makes a query . Nimue simulates to choose . Then Arthur simulates using as the public part of the initial configuration, and Nimue simulates using and as the initial configuration. As and reduce to , this ultimately allows Arthur to compute an element . Then Arthur and Nimue pretend was played by Merlin and go back to simulating and . They continue in the same way, simulating each oracle query via a full run of and , until declares a final value which Arthur returns.
► Definition 2.3. Two Arthur–Nimue–Merlin oracles are equivalent, denoted , when and . The partially ordered set of Arthur–Nimue–Merlin
⁴ We do not define the notion of winning Merlin strategy because Merlin cannot have one except in trivial cases: Arthur might win “by accident” by declaring a good value on his very first move.
⁵ Numbered 2.9 and 2.10 in the arXiv version
⁶ Numbered 2.13 in the arXiv version
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
degrees, denoted is the quotient of Arthur–Nimue–Merlin oracles by equivalence, equipped with the order induced by . We write for the degree of an oracle .
As announced, Arthur–Nimue–Merlin degrees generalize Turing degrees.
► Remark 2.4. Let be Turing oracles. Define the Arthur–Nimue–Merlin oracles by and likewise . Then (i.e., is Turing-reducible to ) if and only if (i.e., is Arthur–Nimue–Merlin reducible to ). In particular, is a well-defined embedding of the partially ordered set of Turing degrees into the partially ordered set of Arthur–Nimue–Merlin degrees .
In the sequel, we implicitly identify a Turing oracle with the Arthur–Nimue–Merlin oracle and we view Turing degrees as a subset of Arthur–Nimue–Merlin degrees.
The bottom degree 0 is the Turing degree of computable functions. It is the least Arthur–Nimue–Merlin degree since Arthur can simply compute the function without querying the oracle at all.
We also single out the basic degrees in the sense of Lee and van Oosten [11].
► Definition 2.5. A basic oracle is a subset , which we implicitly identify with the Arthur–Nimue–Merlin oracle defined by the constant function . A basic degree is a degree represented by some basic oracle.
In the reduction game to a basic oracle, the questions asked by Arthur are irrelevant. Evocatively, Nimue tries to communicate information to Arthur, but with Merlin scrambling it on the way, and Arthur can listen for as long as he wants but must ultimately decide on an answer to return.
Conversely, in the reduction game from a basic oracle, Arthur starts with no information at all on the target set of which he must declare an element, and must entirely rely on the help of Nimue to obtain such information.
► Remark 2.6. In particular, a basic oracle has degree 0 if and only if is inhabited (this is [11, Proposition 3.1(iii)]) since, in the reduction game from to a computable oracle, there is no help available, so Arthur can only win by always returning the same constant.
There is no greatest Turing degree since every Turing degree is less than its Turing jump . On the other hand, there is a “degenerate” greatest Arthur–Nimue–Merlin degree and a greatest element of the rest.
► Definition 2.7. The top degree is the basic degree represented by the basic oracle . The omniscient degree is the basic degree represented by the basic oracle .
► Remark 2.8. The top degree is the greatest Arthur–Nimue–Merlin degree and the omniscient degree is the greatest Arthur–Nimue–Merlin degree different from the top degree.
Proof. If is an oracle such that for some , then Arthur and Nimue can win the reduction game from any oracle to through the following strategy: Arthur queries the oracle on and Nimue plays , so that Merlin loses by lack of available move. In particular, is the maximum Arthur–Nimue–Merlin degree.
The omniscient degree is denoted by Kihara in [7].
Now let be an oracle whose degree is not . Then reduces to by the following Arthur–Nimue strategy. Consider an initial configuration consisting of and . By the previous remark, is inhabited. Arthur and Nimue can win the reduction game from to by the following strategy: Arthur queries the oracle on ; Nimue picks any and plays ; Merlin is forced to answer to Arthur, and Arthur returns .
► Remark 2.9. The basic oracle has degree (if Nimue can repeatedly communicate one bit to Arthur, she can communicate an arbitrary natural number, by encoding it in unary).
Finally, we note that least upper bounds exist in the Arthur–Nimue–Merlin degrees and are just as easy to compute as in the Turing degrees.
► Remark 2.10. Let and be Arthur–Nimue–Merlin oracles. The least upper bound of their degrees exists and can be explicitly constructed as where and . The inclusion of Turing degrees into Arthur–Nimue–Merlin degrees preserves least upper bounds.
3 Decoding and coding degrees for promise problems
We borrow terminology from complexity theory [3] by calling promise problem a pair of disjoint inhabited subsets , informally understood as the computational problem “given an element , determine whether or ”.⁸ (Requiring and to be inhabited excludes annoying special cases in what follows.)
► Definition 3.1. Let be a promise problem. The decoding oracle is defined by for and for and for . The coding oracle is the basic oracle defined by . At the level of degrees, we write and .
The decoding oracle is the most natural Arthur–Nimue–Merlin oracle associated to the promise problem . It is decidable (has degree ) precisely when is decidable as a promise problem in the sense just described: given , it can be computably determined whether or . As an oracle, it answers questions of the form “is in or in ?”, where questions are forbidden. Remark that when and are complements of each other, is the ordinary Turing degree of both.
The coding oracle is more interesting: it communicates bits helpfully chosen by Nimue in a form adversarially encoded by Merlin as instances of the promise problem . Namely, Merlin returns an element of if Nimue chose 0 and an element of if Nimue chose 1.
► Remark 3.2. We have because this oracle allows both to obtain answers to arbitrary questions coded as instances of the promise problem and to decode these answers (and it is not because we required and to be inhabited).
It is intuitively plausible that the harder the promise problem is, the weaker the oracle is because it becomes harder for Arthur to decode the messages sent by Nimue. Thus, the higher , the lower . However, this is not strictly true.
► Example 3.3. In our opening riddle, we asked whether where is the halting set and its complement. We observed that this is indeed the case, because
⁸ This should not be confused with the separation problem , which requires the program solving the problem to terminate (with any value) even on inputs outside .
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
Nimue can transmit a bit to Arthur by either playing followed by , or followed by . Arthur receives two Turing machines and runs them in parallel, so that which one terminates reveals the bit chosen by Nimue. This shows that can be made non-zero while remains omniscient.
More generally, if , then because the following Arthur–Nimue strategy allows Nimue to communicate a bit to Arthur: he queries the oracle twice, and depending on the bit, she plays then or then , and Arthur solves the resulting instance of the promise problem .
► Example 3.4. In fact, can be made an arbitrary Turing degree while keeping omniscient. Let be the Dedekind cut of a real number , namely and (viewed as subsets of through a Gödel coding of rational numbers). Then is the Turing degree of in the standard sense, but can be decided by simply comparing rationals.
► Example 3.5. For another example of the same phenomenon, let and define as the set of codings of a prefix of this function, , such that , and likewise with . Then (for the direction, compute iteratively using the oracle until the desired value), yet is decidable because if we have a prefix of in and another prefix in , one of them is strictly longer and reveals which of and the other belongs to.
We now arrive at our main technical result: the implication is in fact an equivalence. Moreover, the result relativizes to an arbitrary Turing degree, and this fact will be the crux of the proof that the construction of co-Turing degrees defines an embedding.
► Theorem 3.6. (Plain version.) Let be a promise problem. We have if and only if .
(Relativized version.) Let be a promise problem and let be a Turing degree. We have if and only if .
Proof. Let us first prove the “plain” version. For the entirety of the proof, we fix elements and , which exist by assumption.
We assume that is omniscient, which means that there exists a winning Arthur–Nimue strategy in the game reducing to . We fix such a strategy and call Arthur’s part of the strategy; thus, takes a finite sequence of natural numbers representing moves by Merlin to a move by Arthur, which can be “query the oracle once more” or “declare a final value ”.
Given an element , we consider the function (where are two labels) defined explicitly by
The notation suppresses the implicit conversion of pairs of natural numbers to natural numbers through the pairing .
If the reader has difficulty distinguishing from typographically, we hasten to reassure that this will not cause any confusion.
This function is designed to ensure the following property (): if , then and for any , and symmetrically, if , then and for any .
We define an ancillary game, which is a two-player imperfect information game parameterized by . The two players are “Left” and “Right”. On the -th turn, Left chooses a value , and Right simultaneously chooses . (Each player has seen the other’s moves up to this turn, but the two moves on this turn are chosen independently.) What happens next depends on the value of Arthur’s strategy on the sequence . If returns “query the oracle”, then the ancillary game continues. If returns “declare a final value ” where , then Left wins if , whereas Right wins if . If fails to return or returns a malformed value, or if the game lasts infinitely long, then the result is a draw (no player wins).
Assume temporarily that . We observe that Left has a winning strategy in the ancillary game. Indeed, by (), Left can control whether the successive elements provided to are in or , and using Nimue’s part of the Arthur–Nimue winning strategy, this enables Left to make Arthur’s strategy output 0. Let be a winning strategy for Left. This is a function from finite sequences in , representing past moves by Right, to elements of , representing the next move by Left. For every sequence of moves by Right, the play where Left plays according to and Right plays the successive elements of must end in a victory for Left after a finite number of moves. The function is continuous (where is topologized by the product of the discrete topology) because only depends on the first terms of . By compactness of the Cantor space , it must be bounded by some constant . This means that a finite fragment of — its restriction to finite sequences in of length at most — already suffices to witness that Left has a winning strategy.
We have proved that for all , there exists a finite fragment of strategy, namely a function only defined on finite sequences in up to a certain length , which certifies that Left can win, in the sense that running the game up to the -th turn using this strategy fragment for the moves of Left and any sequence of length in for the moves of Right results in the game already ending with a victory for Left. Symmetrically, for , there exists a finite strategy fragment which certifies that Right can win. Finally, the two conditions are mutually exclusive since the players cannot both win at the same time. This shows that if and only if Left has a winning finite strategy fragment and if and only if Right has a winning finite strategy fragment.
We deduce an algorithm to decide, given , whether or : enumerate finite strategy fragments in parallel to search at the same time for a winning strategy fragment for Left and a winning strategy fragment for Right. Whether a strategy fragment is winning for a given player can be semi-decided by simulating the plays with this fragment for the given player and all possible sequences up to the length of the fragment for the other player.
This concludes the proof of the “plain” version of the theorem. To prove the “relativized” version, we make the following observation: the proof of the “plain” version which we have just given applies just as well if we replace computability by computability relative to a Turing oracle . The assumption that is a Turing oracle and not a general Arthur–Nimue–Merlin oracle is used so that the ancillary game is well-defined as Arthur’s strategy is using a deterministic oracle, as well as to ensure it is possible to run several computations in parallel under this oracle, some of which are not guaranteed to be well-behaved. (This might be impossible under an oracle such that some of the sets are
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
empty, which means that is a “forbidden question” that makes the computation immediately fail if asked to the oracle, including any other “threads” that the program might be running.) This gives us the following result: if Arthur–Nimue have a winning strategy in the game reducing to , but where now Arthur is allowed to access the oracle in computing his strategy, then there is an -computable way to solve to the promise problem . The hypothesis is equivalent to Arthur–Nimue having a winning strategy in the game reducing to (because an -computable strategy for Arthur is the same thing as a strategy for Arthur that can make the move of querying the -oracle), and the conclusion is equivalent to Arthur having a winning strategy in the game reducing to .
► Remark 3.7. This provides an answer to the second part of our opening riddle, which asks whether where (here is the halting set), and thus . If such were the case, then by Theorem 3.6 the promise problem would be decidable. This would allow to decide whether a program halts, by deciding the instance ((loop, ), (halt, )) of this problem, where loop is a fixed program that does not halt and halt is a fixed program that does.
4 Co-Turing degrees
We turn to the construction of co-Turing degrees, as special cases of . For technical convenience, we use Turing degrees of subsets (namely the Turing degrees of their characteristic functions ) instead of functions .
One might naively attempt to define the co-Turing degree of to be , but this is not a function of the Turing degree of . For example, we have just seen (Remark 3.7) that there is an undecidable set for which , and using Dedekind cuts (Example 3.4), we can find another set with the same Turing degree such that . Instead, we use a slight modification, for which a conceptual explanation will be provided in Section 5.
► Definition 4.1. Let . For , we let be the set of programs without argument which return when run with as an oracle (i.e., ). We define the co-Turing oracle of as the basic oracle .
In words, the oracle cooperatively answers arbitrary boolean questions but, instead of directly providing the answers, it adversarially encodes each answer in the form of a program which returns the answer when run with as an oracle.
► Theorem 4.2. The map from Turing oracles with the opposite of their normal preorder to Arthur–Nimue–Merlin oracles (with their normal preorder) is order-preserving and order-reflecting.
Proof. Let .
Assume . We seek to prove . Unfolding the reduction game, Arthur needs to declare a program with oracle which outputs a bit known to Nimue but not to him. The following Arthur–Nimue strategy works: Arthur queries the oracle once; Nimue chooses this bit, so that Merlin gives Arthur a program with oracle which outputs this bit; then Arthur modifies this program to replace each call to the oracle by a full run of a fixed Turing reduction from to .
Conversely, assume and let us prove . We have because (Remark 3.2) and . Since the join is order-preserving in both arguments, . By Theorem 3.6, this entails . It remains to see that (this is in fact an equality since the converse inequality is trivial). We use the following reduction. Given , we construct a program with oracle which returns 0 if and 1 if , and likewise which returns 1 if and 0 if . Then if and if so querying the oracle on solves the problem.
► Corollary 4.3. The map coT induces an embedding coT : of the partially ordered set of Turing degrees with the opposite of their normal order into the partially ordered set of Arthur–Nimue–Merlin degrees.
We call coT(a) the co-Turing degree of a. The definition means that coT(a) = [coT(A)] for any subset of Turing degree a.
Having completely described the ordering inside the co-Turing degrees, we turn to the ordering between Turing and co-Turing degrees inside the Arthur–Nimue–Merlin degrees. The bottom degree 0 is a Turing degree below all co-Turing degrees, and the omniscient degree is a co-Turing degree (namely ) above all Turing degrees. It turns out that apart from these two trivial cases, a Turing degree and a co-Turing degree are never comparable. The proof involves the following lemma, which is a reformulation of a result of Kihara and (Keng) Ng [8, Corollary 4.8], but we give a more direct proof, for the idea of which we are indebted to the pseudonymous MathOverflow user “Pastebee” [16].
► Lemma 4.4. Let . If the promise problem is decidable, then one of and is decidable.
Proof. Let decide the promise problem .
For , let be the code of the oracle program that (ignores its argument and) returns 0 if is in the oracle, otherwise 1, and likewise let return 1 if is in the oracle, otherwise 0. We can arrange for and to be computable.
Consider the following putative algorithm to decide . Given an input , we use dovetailing to search in parallel for such that and are both defined and equal, and then return their common value.
Let us check the partial correctness of this algorithm. For a fixed , if it finds such an in its search, then either the booleans and are the same, in which case is this boolean, or and are the same, in which case is this boolean. Either way, the algorithm returns the boolean . Hence, if the algorithm always terminates, it decides .
Now assume that is an input for which the above algorithm does not terminate. In this case, we claim that the following other algorithm decides . Given an input , we run two computations in parallel: in the first, if terminates, we return it; in the second, if terminates with a boolean output, we return its opposite boolean. The assumption that the previous algorithm does not terminate on means that and the opposite of can never be both defined and different, so it suffices to see that one of them must be defined and correct. If , the first is, while if , the second is.
► Theorem 4.5. Let and be Turing degrees.
-
We always have coT() .
-
We have coT() if and only if or .
Proof. 1. Assume coT() . From this and coT() (Remark 3.2), we deduce . We know that least upper bounds of Turing degrees in the Arthur–Nimue–Merlin
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
degrees are computed as in the Turing degrees, so is a Turing degree, but it is not (no Turing oracle will let Arthur guess a secret number).
- The “if” direction is clear. Assume . From this and (Remark 3.2 again), we deduce .
To put this in a form where Theorem 3.6 applies, we make the general observation that for all . (For the inequality , Arthur is either asked to return a boolean known to Nimue as an instance of the promise problem , or as an instance of . In either case, he can obtain it as an instance of from the oracle and apply either projection. The direction is also easy and we do not need it anyway.)
In our particular case, letting and be respectively represented by some , we obtain that . By Theorem 3.6,
To simplify this, observe that without any assumptions on , we have in general
Indeed, a possible reduction for takes programs , constructs the oracle program that runs and exchanges 0 and 1 before returning the result, likewise constructs , queries the oracle on and returns the result. (Again, the inequality is easy and we do not even use it.)
Coming back to our specific situation, we obtain , and we conclude by Lemma 4.4.
5 The internal point of view
As explained in the introduction, Arthur–Nimue–Merlin games were introduced by Kihara to give a more concrete description of Lawvere–Tierney topologies on the effective topos. So far, we have worked entirely at the level of Arthur–Nimue–Merlin games. However, our results exemplify the usefulness of having both points of view. On the one hand, the proofs, especially that of Theorem 3.6, involve Arthur–Nimue–Merlin games, and we have not yet found a natural way to explain them purely in terms of Lawvere–Tierney topologies. On the other hand, the idea of the construction, and especially the twist of using instead of , comes from the other side, and the purpose of this section is to explain how.
A contrario, we will also show that our main theorem cannot follow merely from general abstract nonsense because although the co-Turing degree construction makes sense in other toposes than the effective topos, it is ill-behaved in general. Even in the effective topos, its extension from Turing degrees to all Arthur–Nimue–Merlin degrees is not injective. Nevertheless, it could be interesting for further research to investigate the construction in toposes related to the effective topos, especially the Kleene–Vesley topos [18, section 5.4].
We first recapitulate the connection between Arthur–Nimue–Merlin degrees and Lawvere–Tierney topologies on the effective topos exhibited by Kihara [7]. In the interest of exposition, to enable a broader audience able to understand why Arthur–Nimue–Merlin oracles are the most general kind of reasonable oracles, we do not presuppose at this point that the reader understands the effective topos or Lawvere–Tierney topologies in general. We can nevertheless define Lawvere–Tierney topologies on the effective topos as follows. We consider the maps such that there exist programs
where we have used the notation
for the set of programs which, given any element of , terminate and return some element of . (The notation is right-associative, like implication: means .) These maps are endowed with the preorder defined by when there exists a program . The partially ordered set of Lawvere–Tierney topologies on the effective topos is obtained by quotienting this preorder by the associated equivalence relation, when and .
Informally, we think of as the computational problem of “finding an element in ”, and as ways to solve the problem with the help of some kind of oracle. The existence of and puts two reasonable requirements: if we have already solved the problem, we can turn the solution without help into a solution with help; and if we have a way to solve with help and a way to use that solution to solve again with help, then we can compose them to produce a way to solve with help. The requirements are strongly reminiscent of the definition of a monad in functional programming (and the names and are accordingly borrowed from the Haskell programming language). The connection will be made precise soon: such a map defines an actual monad when we view it internally in the effective topos.
As a first example, for each Turing oracle , the following map represents a Lawvere–Tierney topology on the effective topos: is the set of programs with oracle which (run without input) output an element of . The Arthur–Nimue–Merlin games generalize this to obtain all Lawvere–Tierney topologies on the effective topos.
► Definition 5.1. For each Arthur–Nimue–Merlin oracle , we define as follows: is the set of Arthur strategies for producing an element of using the oracle (more formally, the set of Arthur strategies which are part of some winning Arthur–Nimue strategy in the reduction game from the basic oracle to ).
Conversely, for each map , we define by .
► Theorem 5.2 (Kihara [7, Corollary 3.6]). For all , the map represents a Lawvere–Tierney topology on the effective topos (the programs and as above exist). Furthermore, and define an equivalence of preordered sets between Arthur–Nimue–Merlin oracles and maps representing Lawvere–Tierney topologies on the effective topos. In other words, they induce inverse isomorphisms between the partially ordered set of Arthur–Nimue–Merlin degrees and the partially ordered set of Lawvere–Tierney topologies on the effective topos.
In order to spare the reader the inconvenience of converting between Kihara’s and our setup and notations, and also because the proof in [7] contains a repairable error, we sketch a proof in Appendix A.
Numbered 3.5 in arXiv version
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
► Remark 5.3. Let be an Arthur–Nimue–Merlin oracle and let . The set can be characterized by the following inductive definition (which will turn out useful for computations with the effective topos, in Proposition 5.5):
-
If is an Arthur strategy that outputs an element of without consulting the oracle, then .
-
If is an Arthur strategy which starts by making a query to the oracle, and there exists such that for all , we have , then . Here, denotes the strategy that gives to as a first move and continues simulating it from that point.
This is merely a reformulation of the definition: applying countable choice to pick an entire well-founded tree of such sets gives precisely the data of a Nimue strategy such that the combined Arthur–Nimue strategy is winning.
From this point on, we assume familiarity with basic topos theory, especially the internal language of an elementary topos, and with the effective topos in particular. A standard reference on the effective topos is van Oosten's monograph on realizability [18]; see also McLarty [12, chapter 24], the lecture notes by Phoa [13], and Hyland's seminal paper [4].
Recall that a Lawvere–Tierney topology on an elementary topos is a morphism which is internally a monad on preordered by implication, viewed as a thin category. Explicitly, the following conditions must be satisfied internally (we omit the equations required for a monad, which are trivially satisfied because the category is thin): (like in Haskell), and (like in Haskell). Lawvere–Tierney topologies are preordered by pointwise implication: when internally . Unfolding the internal language, one recovers the previous definition in the particular case of the effective topos; corresponds to the Lawvere–Tierney topology id while corresponds to and corresponds to .
Returning to the general case, recall that a subobject is said to be -dense when internally . The following fact is part of the topos theory folklore:
► Proposition 5.4. For every subobject in an elementary topos, there is a least Lawvere–Tierney topology making the subobject -dense, which we call the Lawvere–Tierney topology induced by , and it can be internally defined by
This formula should be understood as the impredicative encoding of the following inductive definition:
-
If , then .
-
For all , if implies , then .
One checks that, internally, is the least truth value satisfying the above conditions.
Proof. The closest reference we could find for this exact formula is the work of Ahman and Bauer [1, Proposition 3.6], which takes place in a type-theoretic setting that is a bit different from our setup (e.g., the quantification over and the quantification implied by “the least” are internal rather than external), but the proof is the same and is in any case a straightforward verification. This is also sketched by Hyland in [4, Proposition 16.3] (in the specific case of the effective topos, but this is irrelevant).
We proceed to unfold this in the effective topos, in a special case that suffices for our needs. We denote an assembly by where is the underlying set and is such that each is inhabited.
► Proposition 5.5. Let and be two assemblies on the same underlying set such that the identity defines a morphism of assemblies . The Lawvere–Tierney topology on the effective topos induced by this subobject is associated (through the correspondence from Theorem 5.2) to the oracle .
In words, when using the oracle , Arthur chooses a realizer , Nimue chooses such that realizes in the assembly , then Merlin chooses realizing in the assembly .
Proof. The idea is that externalizing the inductive definition of the induced Lawvere–Tierney topology recovers the inductive characterization of from Remark 5.3, as observed by Ahman and Bauer [1, section 5].
To formally make sense of this, we could work out general facts about the semantics of such inductive definitions (essentially, propositional W-types) in the effective topos. We can also check just this special case by externalizing the formula from Proposition 5.4, which gives
and verifying that this is equivalent for to .
An immediate consequence is a description of and as induced Lawvere–Tierney topologies.
► Corollary 5.6. Let be a promise problem. Let be the assembly with underlying set , where elements of realize 0 and elements of realize 1. The identity on the underlying sets define monomorphisms of assemblies . The subobject induces the Lawvere–Tierney topology on the effective topos associated to the Arthur–Nimue–Merlin degree , while induces the Lawvere–Tierney topology associated to .
The next step is to define in a purely internal way. Working in any topos, let be the object of classical (or -stable) truth values, and for a Lawvere–Tierney topology , let be the object of classical truth values which are -decidable. When , there is a natural inclusion . For example, is the object of decidable truth values , which is isomorphic to 2, while is simply (isomorphic to) the object of classical truth values .
► Proposition 5.7. Let and let be the Lawvere–Tierney topology on the effective topos associated to the Turing degree of . The sequence of morphisms in the effective topos is isomorphic to (defined by ).
Proof sketch. The isomorphism is standard (it is used without proof in van Oosten's monograph [18, p. 129]) and the rest is for completely similar reasons, noting that and per Definition 5.1.
In summary, the previous discussion establishes the following theorem, which provides some intuition for the construction of coT: “the closer is to 2, the further it is from ”.
► Theorem 5.8. Let be a Turing degree and let be the associated Lawvere–Tierney topology on the effective topos. The subobject inclusion induces itself, while induces the Lawvere–Tierney topology associated to coT().
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
This construction makes sense in an arbitrary elementary topos, but it is ill-behaved in general. For example, consider an elementary topos where the weak law of excluded middle holds, but the law of excluded middle fails (which exists [5, Examples D4.6.3]). Then the Lawvere–Tierney topologies id and are distinct, but for all , so both inclusions always induce id.
Staying in the effective topos, we can observe that this construction extends coT in a natural way to all Arthur–Nimue–Merlin degrees. Explicitly, coT([g]) is . However, the resulting map is not injective. For example, consider the basic oracle Error (such Error oracles have been studied in detail by Lee and van Oosten [11, section 5], then by Kihara [7, section 4.1]). The promise problem is decidable: given , we can run in parallel on all finite sequences of elements of (“explore the tree of reactions to all possible Merlin moves”), and label by those nodes such that returns , and also those nodes with two children labeled by . When the root is labeled by , we know that . Therefore coT([Error]) = , although [Error] > (by Remark 2.6).
As a concluding remark, we could alternatively define as the sheaffication of 2 for . This and much else will be expanded on in the full version of this paper.
References
- Daniel Ahman and Andrej Bauer. Sheaves as oracle computations. 2026. arXiv:2602.22135.
- S. Barry Cooper. Computability theory. Chapman & Hall/CRC, 2004. ISBN 9781584882374.
- Oded Goldreich. On promise problems: a survey. In Oded Goldreich, Arnold L. Rosenberg, and Alan L. Selman, editors, Theoretical computer science: essays in memory of Shimon Even, pages 254–290. Springer Berlin Heidelberg, 2006. doi:10.1007/11685654_12.
- J. Martin E. Hyland. The effective topos. In Anne S. Troelstra and Dirk van Dalen, editors, The L. E. J. Brouwer centenary symposium: proceedings of the conference held in Noordwijkerhout, 8–13 June, 1981, volume 110 of Studies in Logic and the Foundations of Mathematics, pages 165–216. North-Holland Publishing Company, 1982. URL: https://dpmms.cam.ac.uk/~jmeh1/Research/Pub81-90/hyland-effectivetopos.pdf, doi:10.1016/S0049-237X(09)70129-6.
- Peter T. Johnstone. Sketches of an elephant: a topos theory compendium. Clarendon Press, 2002. ISBN 9780198534259 (vol. 1) / 9780198515982 (vol. 2).
- Takayuki Kihara. Rethinking the notion of oracle: a prequel to Lawvere–Tierney topologies for computability theorists. 2022. arXiv:2202.00188.
- Takayuki Kihara. Lawvere–Tierney topologies for computability theorists. Transactions of the American Mathematical Society, series B, 10:48–85, 2023. doi:10.1090/btran/134.
- Takayuki Kihara and Keng M. Ng. The subTuring degrees. Canadian Journal of Mathematics, pages 1–26, 2025. doi:10.4153/S0008414X25101922.
- Takayuki Kihara and Ming Ng. The game-theoretic Katétov order and idealised effective subtoposes. 2026. arXiv:2602.08138.
- Takayuki Kihara and Ming Ng. The gamified Katétov order is not linear (in fact, very much not so). 2026. arXiv:2605.21473.
- Sori Lee and Jaap van Oosten. Basic subtoposes of the effective topos. Annals of Pure and Applied Logic, 164:866–883, 2013. doi:10.1016/j.apal.2013.04.001.
- Colin McLarty. Elementary categories, elementary toposes. Oxford University Press, 1992. ISBN 9780198533924. doi:10.1093/oso/9780198533924.001.0001.
- Wesley Phoa. An introduction to fibrations, topos theory, the effective topos and modest sets. URL: https://www.lfcs.inf.ed.ac.uk/reports/92/ECS-LFCS-92-208/.
- Wesley Phoa. Relative computability in the effective topos. Mathematical Proceedings of the Cambridge Philosophical Society, 106(3):419–422, 1989. doi:10.1017/S0305004100068146.
15 Andrew M. Pitts. The theory of triposes. PhD thesis, 1981. URL: https://www.cl.cam.ac.uk/~amp12/papers/thet/thet.pdf. 16 Pastebee (pseudonym). Answer to “Uniformly’ minimal pairs of Turing degrees” on the MathOverflow website, 2026. URL: https://mathoverflow.net/a/507736. 17 Robert I. Soare. Turing computability. Theory and Applications of Computability. Springer, 2016. doi:10.1007/978-3-642-31933-4. 18 Jaap van Oosten. Realizability: an introduction to its categorical side, volume 152 of Studies in Logic and the Foundations of Mathematics. Elsevier, 2008. ISBN 9780444515841. doi: 10.1016/s0049-237X(08)X8001-2. 19 Jaap van Oosten. Realizability with a local operator of A. M. Pitts. Theoretical Computer Science, 546:237–243, 2014. doi:10.1016/j.tcs.2014.03.011.
A Proof of isomorphism between Arthur–Nimue–Merlin degrees and Lawvere–Tierney topologies on the effective topos
For convenience of the reader and completeness of the literature, we sketch a proof of Theorem 5.2, which is due to Kihara. The proof in [7] contains a mistake which does not affect the result: in the proof of Theorem 3.5, b is assumed more uniform than it is. We thank Kihara for promptly acknowledging the issue in private communication and providing helpful explanations. The fix is the “continuation-passing trick” explained below.
This fix in fact already appears in the literature in a hidden way, namely as the external unfolding of Ahman and Bauer’s proof that every modality is an oracle modality, which happens internally in a slightly different, type-theoretic setup [1]. This roughly corresponds to the fact that every Lawvere–Tierney topology on an elementary topos is induced by some subobject as in Proposition 5.4 (the proof is the same as theirs: is tautologically the least Lawvere–Tierney topology such that internally , so is induced by ). However, Ahman and Bauer do not obtain an actual isomorphism because they use a different preorder on oracles, namely morphisms of containers, which correspond to Weihrauch reduction (call-once oracles).
Proof sketch of Theorem 5.2. The map represents a Lawvere–Tierney topology: The program exists simply because we can computably convert a natural number to a program that just returns . For , given and , we can compute (without knowing and ) the Arthur strategy that simulates , yielding a final value , then simulates . (A corresponding winning strategy for Nimue simulates a winning strategy associated to , then a winning strategy associated to .)
The map is monotone: If , then because we can computably convert a program that uses the oracle to a program using , by replacing each oracle call with a full run of a fixed reduction from to .
The map is monotone: If , then by the following reduction. Arthur has an element for unknown to him. He converts it to an element using a fixed witness of , then calls the oracle on . Nimue chooses , which is valid because . Merlin gives Arthur an element of which Arthur just returns.
We have : Arthur has and must find an element of for some unknown . He constructs the Arthur strategy which queries the oracle on and returns the result. Then he queries the oracle on . We have , so Nimue can choose , and Merlin gives Arthur an element of which Arthur returns.
We have : Arthur has a strategy which can find an element of some unknown using the oracle , and simply simulates .
An order-reversing embedding of Turing degrees into Arthur–Nimue–Merlin degrees
We have : Given for some unknown , we can compute the Arthur strategy that calls the oracle on and returns the result.
We have : This is the delicate point, proved with a “continuation-passing trick”. We witness this using the following program . Fix and for . Our program receives a strategy which lets Arthur find an element of some unknown using the oracle. It starts simulating . If declares a final value then returns . If queries the oracle on a question , then constructs the program which takes an input and runs itself on the following strategy (“”): give to as the first oracle answer and continue simulating it after that point. Then computes and returns . (As usual, the self-reference in the definition of is justified by Klenee’s second recursion theorem.) The correctness is proved by induction on using the inductive characterization of from Remark 5.3. If declares the final value , then returns , which is in by assumption on . Suppose queries the oracle on and let (i.e., such that ) be a Nimue move as in the inductive characterization. The induction hypothesis ensures that and therefore and thus , by assumption on . ◀