Abstract

In this paper, we first define the longest almost increasing subsequence with sliding windows (LaISW), a generalization that combines the longest increasing subsequence with sliding windows (LISW) problem and the longest almost increasing subsequence (LaIS) problem. For a numeric sequence A, a window size w and a tolerance constant c, the goal of the LaISW problem is to identify the LaIS within all windows of size w in A. In an almost increasing subsequence, slight decreases smaller than c are permitted. We propose an efficient algorithm for solving the LaISW problem. Instead of constructing the entire row tower, our algorithm computes the change in drop out (occurrence) for each element in the row tower. The time complexity of our algorithm is O(nL), and the space complexity is O(L), where n and L represent the lengths of the input sequence and the LaISW answer, respectively.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call