A Space-Efficient Algorithm for Longest Common Almost Increasing Subsequence of Two Sequences
Data Structures and Algorithms
2025-05-08 v2
Abstract
Let and be two number sequences of length and , respectively, where . Given a positive number , a common almost increasing sequence is a common subsequence for both and such that for all , . The LCaIS problem seeks to find the longest common almost increasing subsequence (LCaIS) of and . An LCaIS can be computed in time and space [Ta, Shieh, Lu (TCS 2021)], where is the length of the LCaIS of and . In this paper we first give an -time and -space algorithm to find LCaIS, which improves the space complexity. We then design an -time and -space algorithm, which is faster when the number of matching pairs and the number of compatible matching pairs are in .
Cite
@article{arxiv.2503.15442,
title = {A Space-Efficient Algorithm for Longest Common Almost Increasing Subsequence of Two Sequences},
author = {Md Tanzeem Rahat and Md. Manzurul Hasan and Debajyoti Mondal},
journal= {arXiv preprint arXiv:2503.15442},
year = {2025}
}