# Is there an algorithm for algorithms time/space complexity optimisation?

In 1950s a number of methods for circuit minimization for Boolean functions have been invented. Is there an extension of those methods or anything similar for optimising time or space complexity of algorithms?

For example an implementation of bubble sort as an input for such an algorithm would produce an implementation of a sorting algorithm with time complexity closer to $O(n\log n)$.

• Go away!! We CS profs make a living from teaching sophisticated algorithms, your suggestion would leave us without a job! – vonbrand Jan 6 '16 at 0:33
• Well... what do you expect from AI then? – Optimiser Jan 6 '16 at 3:56
• Bubble sort isn't a Boolean function. Worse, not all sorting algorithms are equivalent! For example, some are not stable. – Yuval Filmus Jan 6 '16 at 9:19
• You are quite right but bubble sort and "good sort" is just an example of what I see as input and output, let's not concentrate on details. – Optimiser Jan 6 '16 at 18:38
• @YuvalFilmus surely returning a sorted array isn't easier than returning true or false – vonbrand Jan 6 '16 at 22:37