rolling icon indicating copy to clipboard operation
rolling copied to clipboard

Implement longest increasing subsequence algorithm

Open ajcr opened this issue 8 years ago • 1 comments

It would be interesting to try and implement an algorithm to find the longest increasing subsequence in a sliding window.

Such an approach is described in Albert et al., 2004:

  • https://pdfs.semanticscholar.org/5517/cc2a743fa07f2ae2fa6442ca77a8b419a8ee.pdf

ajcr avatar Dec 31 '17 17:12 ajcr

Actually, there is another algorithm by Chen et al. that computes the value in O( output ) time:

  • https://ac.els-cdn.com/S0304397507001235/1-s2.0-S0304397507001235-main.pdf?_tid=945b9a2a-034f-11e8-b8f0-00000aab0f6c&acdnat=1517050276_a53f458b7d7310f11436f72772056dfa

This is (theortically) an improvement on the O ( log log n + output ) approach in the paper above.

Also, the construction looks possibly easier to implement and more practical as it does not rely on Emde Boas trees.

ajcr avatar Jan 27 '18 10:01 ajcr