International audienceOriginating from the work of Navarro and Thankanchan [TCS 2016], the problem of consecutive pattern matching is a variant of the fundamental pattern matching problem, where one is given a text and a pair of patterns p1,p2, and must compute consecutive occurrences of p1,p2 in the text. Assuming that the text is given as a straight-line program of size g, we develop an algorithm that computes all consecutive occurrences of p1,p2 in optimal O(g+∣p1∣+∣p2∣+output) time. As a corollary, we also derive an algorithm that reports all co-occurrences separated by a distance d∈[a,b] in O(g+|p_1|+|p_2|+\occ) time and an algorithm that reports the top-k closest co-occurrences in O(g+∣p1∣+∣p2∣+k) time
Is data on this page outdated, violates copyrights or anything else? Report the problem now and we will take corresponding actions after reviewing your request.