Definition of a Galactic Algorithm
Definition of a Galactic Algorithm
An algorithm, even if impractical, may show new techniques that may eventually be used to
create practical algorithms.
Available computational power may catch up to the crossover point, so that a previously
impractical algorithm becomes practical.
An impractical algorithm can still demonstrate that conjectured bounds can be achieved, or
that proposed bounds are wrong, and hence advance the theory of algorithms. As Lipton
states:[1]
This alone could be important and often is a great reason for finding such
algorithms. For example, if tomorrow there were a discovery that showed there is a
factoring algorithm with a huge but provably polynomial time bound, that would
change our beliefs about factoring. The algorithm might never be used, but would
certainly shape the future research into factoring.
Similarly, a hypothetical algorithm for the Boolean satisfiability problem with a large but
polynomial time bound, such as , although unusable in practice, would settle the P
versus NP problem, considered the most important open problem in computer science and
one of the Millennium Prize Problems.[2]
Examples
Integer multiplication
An example of a galactic algorithm is the fastest known way to multiply two numbers,[3] which is based
on a 1729-dimensional Fourier transform.[4] It needs bit operations, but as the constants
hidden by the big O notation are large, it is never used in practice. However, it also shows why galactic
algorithms may still be useful. The authors state: "we are hopeful that with further refinements, the
algorithm might become practical for numbers with merely billions or trillions of digits."[4]
Matrix multiplication
The first improvement over brute-force matrix multiplication (which needs multiplications) was
the Strassen algorithm: a recursive algorithm that needs multiplications. This algorithm is not
galactic and is used in practice. Further extensions of this, using sophisticated group theory, are the
Coppersmith–Winograd algorithm and its slightly better successors, needing multiplications.
These are galactic – "We nevertheless stress that such improvements are only of theoretical interest, since
the huge constants involved in the complexity of fast matrix multiplication usually make these algorithms
impractical."[5]
Sub-graphs
The problem of deciding whether a graph contains as a minor is NP-complete in general, but where
is fixed, it can be solved in polynomial time. The running time for testing whether is a minor of
[8]
in this case is , where is the number of vertices in and the big O notation hides a constant
that depends superexponentially on . The constant is greater than in Knuth's
up-arrow notation, where [9]
is the number of vertices in . Even the case of cannot be
reasonably computed as the constant is greater than 2 pentated by 4, or 2 tetrated by 65536, that is,
Cryptographic breaks
In cryptography jargon, a "break" is any attack faster in expectation than brute force – i.e., performing
one trial decryption for each possible key. For many cryptographic systems, breaks are known, but are
still practically infeasible with current technology. One example is the best attack known against 128-bit
AES, which takes only operations.[10] Despite being impractical, theoretical breaks can provide
insight into vulnerability patterns, and sometimes lead to discovery of exploitable breaks.
Hutter search
A single algorithm, "Hutter search", can solve any well-defined problem in an asymptotically optimal
time, barring some caveats. It works by searching through all possible algorithms (by runtime), while
simultaneously searching through all possible proofs (by length of proof), looking for a proof of
correctness for each algorithm. Since the proof of correctness is of finite size, it "only" adds a constant
and does not affect the asymptotic runtime. However, this constant is so big that the algorithm is entirely
impractical.[13][14] For example, if the shortest proof of correctness of a given algorithm is 1000 bits long,
the search will examine at least 2999 other potential proofs first.
Hutter search is related to Solomonoff induction, which is a formalization of Bayesian inference. All
computable theories (as implemented by programs) which perfectly describe previous observations are
used to calculate the probability of the next observation, with more weight put on the shorter computable
theories. Again, the search over all possible explanations makes this procedure galactic.
Optimization
Simulated annealing, when used with a logarithmic cooling schedule, has been proven to find the global
optimum of any optimization problem. However, such a cooling schedule results in entirely impractical
runtimes, and is never used.[15] However, knowing this ideal algorithm exists has led to practical variants
that are able to find very good (though not provably optimal) solutions to complex optimization
problems.[16]
Hash tables
Researchers have found an algorithm that achieves the provably best-possible[20] asymptotic performance
in terms of time-space tradeoff.[21] But it remains purely theoretical: "Despite the new hash table’s
unprecedented efficiency, no one is likely to try building it anytime soon. It’s just too complicated to
construct."[22] and "in practice, constants really matter. In the real world, a factor of 10 is a game
ender.”[23]
References
1. Lipton, Richard J.; Regan, Kenneth W. (2013). "David Johnson: Galactic Algorithms" (https://
books.google.com/books?id=eLC9BAAAQBAJ&pg=PA109). People, Problems, and Proofs:
Essays from Gödel's Lost Letter: 2010. Heidelberg: Springer Berlin. pp. 109–112.
ISBN 9783642414220.
2. Fortnow, L. (2009). "The status of the P versus NP problem" (http://people.cs.uchicago.edu/
~fortnow/papers/pnp-cacm.pdf) (PDF). Communications of the ACM. 52 (9): 78–86.
doi:10.1145/1562164.1562186 (https://doi.org/10.1145%2F1562164.1562186).
S2CID 5969255 (https://api.semanticscholar.org/CorpusID:5969255).
3. David, Harvey; Hoeven, Joris van der (March 2019). "Integer multiplication in time O(n log
n)" (https://hal.archives-ouvertes.fr/hal-02070778/document). HAL. hal-02070778.
4. Harvey, David (9 April 2019). "We've found a quicker way to multiply really big numbers" (htt
ps://theconversation.com/weve-found-a-quicker-way-to-multiply-really-big-numbers-11492
3). The Conversation. Retrieved 9 March 2023.
5. Le Gall, F. (2012), "Faster algorithms for rectangular matrix multiplication", Proceedings of
the 53rd Annual IEEE Symposium on Foundations of Computer Science (FOCS 2012),
pp. 514–523, arXiv:1204.1111 (https://arxiv.org/abs/1204.1111), doi:10.1109/FOCS.2012.80
(https://doi.org/10.1109%2FFOCS.2012.80), ISBN 978-0-7695-4874-6, S2CID 2410545 (htt
ps://api.semanticscholar.org/CorpusID:2410545)
6. Larry Hardesty (January 19, 2010). "Explained: The Shannon limit" (https://news.mit.edu/20
10/explained-shannon-0115). MIT News Office.
7. "Capacity-approaching codes (Chapter 13 of Principles Of Digital Communication II)" (http
s://ocw.mit.edu/courses/6-451-principles-of-digital-communication-ii-spring-2005/1a3ad00d8
3d1d042da3328a8edd9edc2_chap13.pdf) (PDF). MIT OpenCourseWare. 2005.
8. Kawarabayashi, Ken-ichi; Kobayashi, Yusuke; Reed, Bruce (2012). "The disjoint paths
problem in quadratic time" (https://doi.org/10.1016%2Fj.jctb.2011.07.004). Journal of
Combinatorial Theory. Series B. 102 (2): 424–435. doi:10.1016/j.jctb.2011.07.004 (https://do
i.org/10.1016%2Fj.jctb.2011.07.004).
9. Johnson, David S. (1987). "The NP-completeness column: An ongoing guide (edition 19)".
Journal of Algorithms. 8 (2): 285–303. CiteSeerX 10.1.1.114.3864 (https://citeseerx.ist.psu.e
du/viewdoc/summary?doi=10.1.1.114.3864). doi:10.1016/0196-6774(87)90043-5 (https://do
i.org/10.1016%2F0196-6774%2887%2990043-5).
10. Biaoshuai Tao & Hongjun Wu (2015). Information Security and Privacy. Lecture Notes in
Computer Science. Vol. 9144. pp. 39–56. doi:10.1007/978-3-319-19962-7_3 (https://doi.org/
10.1007%2F978-3-319-19962-7_3). ISBN 978-3-319-19961-0.
11. Anna R. Karlin; Nathan Klein; Shayan Oveis Gharan (September 1, 2020). "A (Slightly)
Improved Approximation Algorithm for Metric TSP". arXiv:2007.01409 (https://arxiv.org/abs/2
007.01409) [cs.DS (https://arxiv.org/archive/cs.DS)].
12. Klarreich, Erica (8 October 2020). "Computer Scientists Break Traveling Salesperson
Record" (https://www.quantamagazine.org/computer-scientists-break-traveling-salesperson-
record-20201008/). Quanta Magazine.
13. Hutter, Marcus (2002-06-14). "The Fastest and Shortest Algorithm for All Well-Defined
Problems". arXiv:cs/0206022 (https://arxiv.org/abs/cs/0206022).
14. Gagliolo, Matteo (2007-11-20). "Universal search" (https://doi.org/10.4249%2Fscholarpedia.
2575). Scholarpedia. 2 (11): 2575. Bibcode:2007SchpJ...2.2575G (https://ui.adsabs.harvar
d.edu/abs/2007SchpJ...2.2575G). doi:10.4249/scholarpedia.2575 (https://doi.org/10.4249%
2Fscholarpedia.2575). ISSN 1941-6016 (https://search.worldcat.org/issn/1941-6016).
15. Liang, Faming; Cheng, Yichen; Lin, Guang (2014). "Simulated stochastic approximation
annealing for global optimization with a square-root cooling schedule". Journal of the
American Statistical Association. 109 (506): 847–863. doi:10.1080/01621459.2013.872993
(https://doi.org/10.1080%2F01621459.2013.872993). S2CID 123410795 (https://api.semanti
cscholar.org/CorpusID:123410795).
16. Ingber, Lester (1993). "Simulated annealing: Practice versus theory" (https://doi.org/10.101
6%2F0895-7177%2893%2990204-C). Mathematical and Computer Modelling. 18 (11): 29–
57. CiteSeerX 10.1.1.15.1046 (https://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.1
5.1046). doi:10.1016/0895-7177(93)90204-C (https://doi.org/10.1016%2F0895-7177%289
3%2990204-C).
17. Karger, David R.; Klein, Philip N.; Tarjan, Robert E. (1995-03-01). "A randomized linear-time
algorithm to find minimum spanning trees" (https://doi.org/10.1145%2F201019.201022).
Journal of the ACM. 42 (2): 321–328. doi:10.1145/201019.201022 (https://doi.org/10.1145%
2F201019.201022). ISSN 0004-5411 (https://search.worldcat.org/issn/0004-5411).
18. Thiesen, Francisco. "A C++ implementation for an Expected Linear-Time Minimum
Spanning Tree Algorithm(Karger-Klein-Tarjan + Hagerup Minimum Spanning Tree
Verification as a sub-routine)" (https://github.com/FranciscoThiesen/karger-klein-tarjan).
GitHub. Retrieved 2022-11-19.
19. Geiman Thiesen, Francisco. "Expected Linear-Time Minimum Spanning Trees" (https://franc
iscothiesen.github.io/Linear-Time-MST/). franciscothiesen.github.io. Retrieved 2022-11-13.
20. Tianxiao Li, Jingxun Liang, Huacheng Yu, and Renfei Zhou. "Tight Cell-Probe Lower Bounds
for Dynamic Succinct Dictionaries" (https://www.cs.princeton.edu/~hy2/files/dynamic_succin
ct_dictionary_lower_bound.pdf) (PDF).
21. Bender, Michael; Farach-Colton, Martin; Kuszmaul, John; Kuszmaul, William; Mingmou, Liu
(4 Nov 2021). "On the Optimal Time/Space Tradeoff for Hash Tables". arXiv:2111.00602 (htt
ps://arxiv.org/abs/2111.00602) [cs (https://arxiv.org/archive/cs)].
22. "Scientists Find Optimal Balance of Data Storage and Time" (https://www.quantamagazine.o
rg/scientists-find-optimal-balance-of-data-storage-and-time-20240208/). 8 February 2024.
23. William Kuszmaul, as quoted in "Scientists Find Optimal Balance of Data Storage and Time"
(https://www.quantamagazine.org/scientists-find-optimal-balance-of-data-storage-and-time-2
0240208/). 8 February 2024.