An oracle Turing machine is a standard Turing machine augmented with a black-box oracle for some decision problem — it can query the oracle and receive an answer in a single step, regardless of the problem's actual complexity. Oracle machines formalize "relative computability": what could be computed if a particular problem were solvable for free. The oracle hierarchy, built by iterating the halting oracle (K, K', K'', ...), produces a strict hierarchy of unsolvable problems. Baker, Gill, and Solovay showed that relativized results can go either way for P vs NP, demonstrating that any proof resolving P vs NP must use non-relativizing techniques.
Start with a concrete oracle — the halting problem K — and show how a TM with oracle K can decide problems that no ordinary TM can, such as the totality problem. Then construct K' (the halting problem relativized to K) and show it is strictly harder than K. This iterated construction makes the arithmetical hierarchy tangible.
You already know that a Turing machine is a formal model of computation, and that the halting problem K is undecidable — no TM can determine whether an arbitrary TM halts on a given input. An oracle Turing machine (OTM) extends the standard model with a special tape and three states (QUERY, YES, NO): the machine writes a string on the oracle tape, enters the QUERY state, and receives a yes/no answer in a single step, for free, regardless of how hard the question is in reality. The oracle is not a subroutine; it is a hypothetical black box. This lets us ask: *if* we could solve some problem instantly, what else could we compute?
The first example to internalize is OTM with the halting oracle K. A standard TM cannot decide the totality problem — "does machine M halt on *every* input?" — because it is Σ₂-complete, strictly harder than K. But a TM with oracle K can decide totality: enumerate all inputs, ask K for each one, and return "yes" iff all queries return "yes." This shows oracle machines access a new tier of computability above ordinary TMs. Iterating this construction produces K' (the halting problem relative to K), K'' (relative to K'), and so on, yielding a strict infinite hierarchy of unsolvable problems known as the arithmetical hierarchy — each level encoding problems of exactly n alternations of ∃ and ∀ quantifiers.
For complexity theory, oracles serve a different purpose: they are a tool for understanding proof techniques. Baker, Gill, and Solovay showed in 1975 that there exist oracles A and B such that P^A = NP^A and P^B ≠ NP^B. Since the P vs NP question changes its answer depending on the oracle, any proof or disproof of P = NP cannot be "relativizing" — it cannot work by viewing the computation as a black box. This eliminates whole families of proof strategies, including most diagonalization arguments. The Baker-Gill-Solovay result does not say P = NP or P ≠ NP is independent of formal set theory; it only constrains the *methods* available for resolving the question.
The deeper lesson is that oracles formalize relative computability — the same idea behind Turing reducibility and many-one reducibility. Problem A reduces to problem B if a TM with oracle B can solve A. This ordering on problems by computational difficulty is the foundation of the Turing degrees, where problems cluster into equivalence classes of mutual reducibility. The oracle framework thus bridges computability theory (classifying undecidable problems) and complexity theory (classifying tractable versus intractable problems) under a single conceptual umbrella.