Budgeted decision procedures on checked context-free grammars and supported pushdown classes. Screens admit a class, preparation checks its shape, and certificates keep the original operands.
createDpdaRegularProcedure, createDpdaInclusionProcedure, createDpdaUniversalityProcedure)Greibach bisimulation. Builds a finite relation on variable sequences by closing all pairs of same-terminal successors. It checks the empty start production and declines when a proposed pair cannot be matched. A budget stop reports exhaustion. (decideGreibachBisimulation, greibachBisimulationProcedure)
Census equality. Proves equality from two original LL(1) or LR(1) unambiguity certificates, one induction inclusion and exact algebraic coefficients through an independently derived degree bound. The count system keeps nullable multiplicities and weighted unit paths. Budget exhaustion leaves the question undecided. (Chomsky and Schützenberger 1963; Balaji et al. 2023; decideCensus, censusProcedure)
Isomorphism. Proves two grammars equivalent by a bijection of their variables that preserves every production, found as a graph isomorphism of an encoding of variables, productions and symbol positions. (decideIsomorphism, isomorphismProcedure)
Orbit equality. Tries normalizations including reduction, concatenation closure, unit closure and the Chomsky normal form trace, and compares the endpoints by isomorphism. A session caches checked positive proofs by canonical grammar hashes. Reuse checks an exact renaming of each operand and joins the proofs by transitivity. (decideOrbit, orbitProcedure)
Synchronized linear equality. Decides equality of linear grammars whose context-bearing productions share one ratio of prefix to suffix length. It encodes words by blocks of that ratio, which gives automata that are compared with HKC (Bonchi and Pous, POPL 2013). (decideLinearSynchronized, linearSynchronizedProcedure)
Composition and closure. Proves equality of disjoint unions and concatenations from their parts, and of balanced grammars by direct closure. (decideComposition, decideTypeClosure)
Visible pushdown equality. Admits height-deterministic pushdown pairs with one verified shared visible partition, empty initial and accepting stacks, and no rejecting controls. It builds the balanced return grammars and keeps both original machines in the checked type-closure claim. (prepareTypeClosure, decideTypeClosure)
Bounded equality. Proves equality inside envelopes of distinct or supported repeated tokens by exact covers. The optional third argument selects an arithmetic Backend, with Cooper as the default. A fourth backend requests corroboration and yields CrossChecked trust on agreement. Disagreement declines the attempt. (decideBounded)
Periodic word bounds. Proposes the primitive roots of literal runs in derivation order, proves containment in a proposed word envelope with a regular invariant, and tries equality with the existing induction prover. The prefix failure function computes roots over atomic terminals. A proposal alone proves nothing. (discoverWordBounds, primitiveRoot, proveWordBound)
Supplied word envelopes. Compares two grammars after proving containment in a supplied product of word stars. A typed construction port supplies the inverse homomorphisms and their intersections with the ordered block tokens. Exact covers give a Semilinear equality certificate. A separating exponent vector gives an original-word BlockExponents certificate. Unsupported count components and failed covers decline the attempt. (envelopeEquality, EnvelopePort)
Boundedness recognition. Returns a proved candidate word bound, a direct same-side pumping witness of unboundedness, an unknown result or resource exhaustion. The unbounded witness names two noncommuting terminal contexts at the start variable and a terminal base production. An independent checker verifies those original production identities. The recognizer is incomplete outside these cases. (recognizeBounded, BoundedRecognitionStatus)
Finite versus grammar. Decides equality of a finite language and a grammar by two inclusions. Each finite word is parsed with the grammar, and a shortest-yield product of the grammar with a trie of the finite words searches for a word outside the finite set. (decideFiniteVersusGrammar, finiteVersusGrammarProcedure)
Finite languages. Compares two finite languages by enumeration, and compares finiteness and emptiness. (decideFiniteBoth, decideFiniteness, decideFinitenessDifference, decideEmptiness)
decideMinLength, minLengthProcedure)refuteBySlices, slicesProcedure)refuteBySampling)Backend, with Cooper as the default, to test the proposed separating vector against the target image. A fourth backend requests CrossChecked trust and disagreement declines. It also shares completed Parikh formulas for the same reference grammar, pool and coordinate identities. (decideParikhSeparation, parikhFormula)decideInduction, inductionProcedure)a as b has the weights 1 and -2. (decideValuation, valuationProcedure)decideRegularSeparation)Noncanonical unambiguity. Searches flagged original-production position pairs and proves that their closed reachable set has no conflicting completion. The successor relation includes distinct exposed reductions. Potential ambiguity declines the procedure. (Schmitz 2007; decideNoncanonical, noncanonicalProcedure)
Regular overlap unambiguity. Computes closed first-token, last-token and capped-length summaries at precision 1. Every original alternative pair and split carries a regular-invariant emptiness proof of its regular overlap. (Brabrand, Giegerich and Møller 2010; decideApproximation, approximationProcedure)
Tree census ambiguity. Compares exact original tree counts with complete word slices and extracts two original-production trees when the counts differ. Useful zero-length cycles decline this procedure. (decideAmbiguityCensus, ambiguityCensusProcedure)
Regular invariant. Proves that a grammar is contained in the language of a DFA by assigning each variable a relation on the DFA states, closed under relational composition of every production, with the start relation ending in accepting states. (decideRegularInvariant, regularInvariantProcedure)
Simple grammars. Decides equivalence of two simple grammars, whose productions are a terminal followed by variables with at most one production for each variable and terminal (Korenjak and Hopcroft 1966). It accepts grammars whose variables all derive words, and builds a finite base of equations between leading variables by cutting each obligation at a shortest word. The search records a congruence derivation for the start and for each successor pair, as a Bisimulation certificate of the form SimpleGrammar. A separate search finds a word that one grammar accepts and the other rejects, as a Word certificate. Both searches charge the caller budget. It runs in the Class lane. (decideSimpleGrammar, simpleGrammarProcedure)
One-counter automata. Decides equivalence of two real-time deterministic pushdown automata that have one bottom symbol and one counter symbol and accept by state (Valiant and Paterson 1975; Böhm, Göller and Jančar 2013). It reads each machine as moves that depend on the state, the letter and whether the counter is zero, and drops moves into states that cannot reach an accepting state. A search in order of word length over pairs of configurations gives a shortest word that one automaton accepts and the other rejects, as a Word certificate. When none exists in the searched pairs, it builds a bisimulation from single pairs of small counters and from families of pairs whose counters grow together. A family needs one check for all its members because every move keeps both counters positive. The relation is a Bisimulation certificate of the form OneCounter. The proof covers the automata whose counters keep a fixed distance once they are large, which includes a machine and any renamed or state-split copy of it. It does not build the periodic relation of the general case, so a pair outside that fragment stays undecided. It runs in the Class lane. (decideOneCounter, oneCounterProcedure)
Inclusion between two grammars. Decides whether the language of one grammar lies inside the language of another. It walks the words of the smaller grammar in order of length, from the exact word table of its useful normal form, and tests each on the Earley recognizer of the larger grammar. The first rejected word refutes the inclusion with a Word certificate. When the words up to length 6 are all accepted, it runs the induction prover for one direction and, on success, returns an Induction certificate with the forward proof alone. Otherwise it compares words up to length 14. A pair with no short counterexample and no induction stays undecided. It runs in the General lane. (decideGrammarInclusion, grammarInclusionProcedure)
Inclusion in a regular language. Refutes inclusion of a grammar in a regular language. (decideInclusionInRegular)
Nonmembership. Proves that a word is outside a grammar when the Earley recognizer rejects it. (decideNonMember, nonmemberProcedure)
Membership. Parses a word with Earley's algorithm and lifts one parse tree to a leftmost derivation over original production IDs. (membershipProcedure)
Rewrite nonmembership. Rejects a word for context-sensitive and unrestricted grammars when a complete search finds no derivation. (decideRewriteNonMember)
Ambiguity. Proves a grammar unambiguous from a conflict-free LL(1), LALR(1) or canonical LR(1) table. It finds ambiguity from useful nullable-aware unit cycles, from unifying parser conflicts and from two distinct trees of one word found in slices. Each witness carries original production IDs. (decideAmbiguityLl1, decideAmbiguityLr1, decideAmbiguityCycle, decideAmbiguityCounterexample, decideAmbiguitySlices)
Balanced presentations. Finds and compiles a matched presentation of a grammar and recognizes words with it. (discoverBalanced, compileBalanced, recognizeBalancedWord)
Syntactic screens. Answer "no" before any preparation when a grammar pair is outside a procedure's class. Linear synchronization needs linear grammars, the finite procedures need a side that no pumping cycle makes infinite, and Parikh separation needs count images that the bounded solver reaches. A screen refuses only when the procedure would decline.
Scheduler adapters. Wrap the remaining expert functions for the scheduler. They cover composition, emptiness, finiteness of one grammar and of a pair, comparison of two finite languages, sampling, inclusion in a regular language, the five ambiguity engines, bounded equality, type closure, Parikh separation and regular separation. (compositionProcedure, emptinessProcedure, finitenessProcedure, finitenessPairProcedure, finiteBothProcedure, samplingProcedure, inRegularProcedure, grammarInclusionProcedure, simpleGrammarProcedure, oneCounterProcedure, ambiguitySlicesProcedure, ambiguityLl1Procedure, ambiguityLr1Procedure, ambiguityCycleProcedure, ambiguityCounterexampleProcedure, boundedProcedure, typeClosureProcedure, parikhSeparationProcedure, regularSeparationProcedure, rewriteNonmemberProcedure)
Reason explanation. Explains a local refusal in words and maps it to the code of the scheduler. Counter preparation keeps the failed restriction in CounterRefusal, recognised by isCounterRefusal and explained by explainCounterRefusal. (explainContextFreeReason, inapplicableOf)
Parikh encoding dump. Prints the coordinate mappings and the formula graph of an encoding. (dumpParikhEncoding)
prepareCfg, prepareCfgPair, CfgPair)ParikhEncoding)prepareCfgQuestion, PreparedCfg, prepareComposition, prepareFinitenessQuestion, PreparedFiniteness, prepareInRegular, InRegularPrepared, prepareRegularInvariant, PreparedRegularInvariant, prepareAmbiguityQuestion, PreparedAmbiguity, prepareTypeClosure, PreparedTypeClosure, prepareMembershipQuestion, PreparedMembership, prepareRewriteMembership, PreparedRewriteMembership)BalancedPresentation)WordBound, dumpWordBound)ContextFreeProcedureId, ContextFreeReason, CounterRefusalReason)Counter preparation funds isRealTime and reports an epsilon move through its existing
refusal code. The simple-grammar screen continues to inspect grammars. Its existing
terminal-first production restriction excludes epsilon rules and requires one consumed
terminal for each grammar step.