Regular Expressions with Backreferences and Lookaheads Capture NLOG
Yuya Uezato

TL;DR
This paper characterizes the expressive power of regular expressions with backreferences and lookaheads, showing they match the complexity class NLOG and establishing their membership problem as PSPACE-complete.
Contribution
It provides the first precise complexity classification of REGEX with backreferences and lookaheads, connecting them to NLOG and PSPACE-complete problems.
Findings
REWBLk equals NLOG in expressive power
Membership problem for REWBLk is PSPACE-complete
Addresses the complexity of combining backreferences and lookaheads
Abstract
Backreferences and lookaheads are vital features to make classical regular expressions (REGEX) practical. Although these features have been widely used, understanding of the unrestricted combination of them has been limited. Practically, most likely no implementation fully supports them. Theoretically, while some studies have addressed these features separately, few have dared to combine them. In those few studies, it has been made clear that the amalgamation of these features renders REGEX significantly expressive. However, no acceptable expressivity bound for REWBLkREGEX with backreferences and lookaheadshas been established. We elucidate this by establishing that REWBLk coincides with NLOG, the class of languages accepted by log-space nondeterministic Turing machines (NTMs). In translating REWBLk to log-space NTMs, negative lookaheads are the most…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
