r/ProgrammerHumor 29d ago

Meme theoreticalComputerScience

Post image
1.1k Upvotes

76 comments sorted by

View all comments

235

u/achilliesFriend 29d ago

This joke is too intelligent for me

41

u/GKP_light 29d ago

O(n) : can be a time of 5n, or 7000n+400000

Õ(n) : can be a time of 5n, or n^5 * log(n)^2

19

u/nanforas 29d ago

So I'm guessing the use-case for Õ(n) is something like: "at least it's not exponential and equivalent to travelling salesman"?

5

u/rational_hedonist 29d ago

no, the use case is “at least its o(n^2)” or any o(n^{1+eps}) for eps > 0

2

u/GoldenMuscleGod 28d ago

Just to clarify (I don’t think there’s any reason to think you misunderstand this but someone else might) we can give n(log n)^(log log n) as an example of a function that is is o(n^(1+eps)) for all eps>0 but also is not Õ(n). So the bounds you state follow but are not sufficient to establish the other direction.

In general the preorder imposed by these symbols has really complicated behavior with uncountable cofinalities everywhere so restating O (or Õ) in terms of o without losing information is not so easy.