103 research outputs found

    Fast Frechet Distance Between Curves With Long Edges

    Full text link
    Computing the Fr\'echet distance between two polygonal curves takes roughly quadratic time. In this paper, we show that for a special class of curves the Fr\'echet distance computations become easier. Let PP and QQ be two polygonal curves in Rd\mathbb{R}^d with nn and mm vertices, respectively. We prove four results for the case when all edges of both curves are long compared to the Fr\'echet distance between them: (1) a linear-time algorithm for deciding the Fr\'echet distance between two curves, (2) an algorithm that computes the Fr\'echet distance in O((n+m)log⁥(n+m))O((n+m)\log (n+m)) time, (3) a linear-time d\sqrt{d}-approximation algorithm, and (4) a data structure that supports O(mlog⁥2n)O(m\log^2 n)-time decision queries, where mm is the number of vertices of the query curve and nn the number of vertices of the preprocessed curve

    Approximability of the Discrete {Fr\'echet} Distance

    No full text
    <p>The Fréchet distance is a popular and widespread distance measure for point sequences and for curves. About two years ago, Agarwal et al. [SIAM J. Comput. 2014] presented a new (mildly) subquadratic algorithm for the discrete version of the problem. This spawned a flurry of activity that has led to several new algorithms and lower bounds.</p><p>In this paper, we study the approximability of the discrete Fréchet distance. Building on a recent result by Bringmann [FOCS 2014], we present a new conditional lower bound showing that strongly subquadratic algorithms for the discrete Fréchet distance are unlikely to exist, even in the one-dimensional case and even if the solution may be approximated up to a factor of 1.399.</p><p>This raises the question of how well we can approximate the Fréchet distance (of two given dd-dimensional point sequences of length nn) in strongly subquadratic time. Previously, no general results were known. We present the first such algorithm by analysing the approximation ratio of a simple, linear-time greedy algorithm to be 2Θ(n)2^{\Theta(n)}. Moreover, we design an α\alpha-approximation algorithm that runs in time O(nlog⁥n+n2/α)O(n\log n + n^2/\alpha), for any α∈[1,n]\alpha\in [1, n]. Hence, an nΔn^\varepsilon-approximation of the Fréchet distance can be computed in strongly subquadratic time, for any \varepsilon > 0.</p

    Dynamic Time Warping and Geometric Edit Distance: Breaking the Quadratic Barrier

    Get PDF
    Dynamic Time Warping (DTW) and Geometric Edit Distance (GED) are basic similarity measures between curves or general temporal sequences (e.g., time series) that are represented as sequences of points in some metric space (X, dist). The DTW and GED measures are massively used in various fields of computer science and computational biology, consequently, the tasks of computing these measures are among the core problems in P. Despite extensive efforts to find more efficient algorithms, the best-known algorithms for computing the DTW or GED between two sequences of points in X = R^d are long-standing dynamic programming algorithms that require quadratic runtime, even for the one-dimensional case d = 1, which is perhaps one of the most used in practice. In this paper, we break the nearly 50 years old quadratic time bound for computing DTW or GED between two sequences of n points in R, by presenting deterministic algorithms that run in O( n^2 log log log n / log log n ) time. Our algorithms can be extended to work also for higher dimensional spaces R^d, for any constant d, when the underlying distance-metric dist is polyhedral (e.g., L_1, L_infty)

    Tighter Connections Between Formula-SAT and Shaving Logs

    Get PDF
    A noticeable fraction of Algorithms papers in the last few decades improve the running time of well-known algorithms for fundamental problems by logarithmic factors. For example, the O(n2)O(n^2) dynamic programming solution to the Longest Common Subsequence problem (LCS) was improved to O(n2/log⁥2n)O(n^2/\log^2 n) in several ways and using a variety of ingenious tricks. This line of research, also known as "the art of shaving log factors", lacks a tool for proving negative results. Specifically, how can we show that it is unlikely that LCS can be solved in time O(n2/log⁥3n)O(n^2/\log^3 n)? Perhaps the only approach for such results was suggested in a recent paper of Abboud, Hansen, Vassilevska W. and Williams (STOC'16). The authors blame the hardness of shaving logs on the hardness of solving satisfiability on Boolean formulas (Formula-SAT) faster than exhaustive search. They show that an O(n2/log⁥1000n)O(n^2/\log^{1000} n) algorithm for LCS would imply a major advance in circuit lower bounds. Whether this approach can lead to tighter barriers was unclear. In this paper, we push this approach to its limit and, in particular, prove that a well-known barrier from complexity theory stands in the way for shaving five additional log factors for fundamental combinatorial problems. For LCS, regular expression pattern matching, as well as the Fr\'echet distance problem from Computational Geometry, we show that an O(n2/log⁥7+Δn)O(n^2/\log^{7+\varepsilon} n) runtime would imply new Formula-SAT algorithms. Our main result is a reduction from SAT on formulas of size ss over nn variables to LCS on sequences of length N=2n/2⋅s1+o(1)N=2^{n/2} \cdot s^{1+o(1)}. Our reduction is essentially as efficient as possible, and it greatly improves the previously known reduction for LCS with N=2n/2⋅scN=2^{n/2} \cdot s^c, for some c≄100c \geq 100
    • 

    corecore