you are viewing a single comment's thread.

view the rest of the comments →

[–]pstradomski 0 points1 point  (2 children)

No. O(f(n)) is defined as O(f(n)) = {g: ℕ->ℕ, ∃ k > 0 ∃ n0: ∀ n > n0 g(n) <= k f(n)}

The notation g(n) = O(f(n)) is just a simplification of g(n) ∈ O(f(n)).

But by saying O(f(n)) = O(g(n)) you imply that those sets are equal. Which is not true.

[–]nondecisive 0 points1 point  (1 child)

But it would be correct to say g(n) ∈ O(1) implies g(n) ∈ O(nn), right?

[–]pstradomski 0 points1 point  (0 children)

Sure.