### Abstract

We give subquadratic algorithms that, given two necklaces each with n beads at arbitrary positions, compute the optimal rotation of the necklaces to best align the beads. Here alignment is measured according to the ℓ_{p} norm of the vector of distances between pairs of beads from opposite necklaces in the best perfect matching. We show surprisingly different results for p = 1, p = 2, and p = ∞. For p = 2, we reduce the problem to standard convolution, while for p = ∞ and p = 1, we reduce the problem to (min,+) convolution and (median, +) convolution. Then we solve the latter two convolution problems in subquadratic time, which are interesting results in their own right. These results shed some light on the classic sorting X + Y problem, because the convolutions can be viewed as computing order statistics on the antidiagonals of the X + Y matrix. All of our algorithms run in o(n ^{2}) time, whereas the obvious algorithms for these problems run in ⊖(n^{2}) time.

Original language | English (US) |
---|---|

Title of host publication | Algorithms, ESA 2006 - 14th Annual European Symposium, Proceedings |

Pages | 160-171 |

Number of pages | 12 |

Volume | 4168 LNCS |

State | Published - 2006 |

Event | 14th Annual European Symposium on Algorithms, ESA 2006 - Zurich, Switzerland Duration: Sep 11 2006 → Sep 13 2006 |

### Publication series

Name | Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics) |
---|---|

Volume | 4168 LNCS |

ISSN (Print) | 03029743 |

ISSN (Electronic) | 16113349 |

### Other

Other | 14th Annual European Symposium on Algorithms, ESA 2006 |
---|---|

Country | Switzerland |

City | Zurich |

Period | 9/11/06 → 9/13/06 |

### Fingerprint

### ASJC Scopus subject areas

- Computer Science(all)
- Biochemistry, Genetics and Molecular Biology(all)
- Theoretical Computer Science

### Cite this

*Algorithms, ESA 2006 - 14th Annual European Symposium, Proceedings*(Vol. 4168 LNCS, pp. 160-171). (Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics); Vol. 4168 LNCS).

**Necklaces, convolutions, and X + Y.** / Bremner, David; Chan, Timothy M.; Demaine, Erik D.; Erickson, Jeff; Hurtado, Ferran; Iacono, John; Langerman, Stefan; Taslakian, Perouz.

Research output: Chapter in Book/Report/Conference proceeding › Conference contribution

*Algorithms, ESA 2006 - 14th Annual European Symposium, Proceedings.*vol. 4168 LNCS, Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics), vol. 4168 LNCS, pp. 160-171, 14th Annual European Symposium on Algorithms, ESA 2006, Zurich, Switzerland, 9/11/06.

}

TY - GEN

T1 - Necklaces, convolutions, and X + Y

AU - Bremner, David

AU - Chan, Timothy M.

AU - Demaine, Erik D.

AU - Erickson, Jeff

AU - Hurtado, Ferran

AU - Iacono, John

AU - Langerman, Stefan

AU - Taslakian, Perouz

PY - 2006

Y1 - 2006

N2 - We give subquadratic algorithms that, given two necklaces each with n beads at arbitrary positions, compute the optimal rotation of the necklaces to best align the beads. Here alignment is measured according to the ℓp norm of the vector of distances between pairs of beads from opposite necklaces in the best perfect matching. We show surprisingly different results for p = 1, p = 2, and p = ∞. For p = 2, we reduce the problem to standard convolution, while for p = ∞ and p = 1, we reduce the problem to (min,+) convolution and (median, +) convolution. Then we solve the latter two convolution problems in subquadratic time, which are interesting results in their own right. These results shed some light on the classic sorting X + Y problem, because the convolutions can be viewed as computing order statistics on the antidiagonals of the X + Y matrix. All of our algorithms run in o(n 2) time, whereas the obvious algorithms for these problems run in ⊖(n2) time.

AB - We give subquadratic algorithms that, given two necklaces each with n beads at arbitrary positions, compute the optimal rotation of the necklaces to best align the beads. Here alignment is measured according to the ℓp norm of the vector of distances between pairs of beads from opposite necklaces in the best perfect matching. We show surprisingly different results for p = 1, p = 2, and p = ∞. For p = 2, we reduce the problem to standard convolution, while for p = ∞ and p = 1, we reduce the problem to (min,+) convolution and (median, +) convolution. Then we solve the latter two convolution problems in subquadratic time, which are interesting results in their own right. These results shed some light on the classic sorting X + Y problem, because the convolutions can be viewed as computing order statistics on the antidiagonals of the X + Y matrix. All of our algorithms run in o(n 2) time, whereas the obvious algorithms for these problems run in ⊖(n2) time.

UR - http://www.scopus.com/inward/record.url?scp=33750724735&partnerID=8YFLogxK

UR - http://www.scopus.com/inward/citedby.url?scp=33750724735&partnerID=8YFLogxK

M3 - Conference contribution

SN - 3540388753

SN - 9783540388753

VL - 4168 LNCS

T3 - Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics)

SP - 160

EP - 171

BT - Algorithms, ESA 2006 - 14th Annual European Symposium, Proceedings

ER -