f(n)=(log(n))^log(n)
g(n)= n/log(n)
f = O(g(n))?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Take the log of both sides:
log(f(n)) = log(log n) * log n
log(g(n)) = log(n) – log(log(n)) = log(n)(1 – log(log(n))/log(n))
Clearly log(log(n)) dominates (1 – log(log(n))/log(n)), so g is O(f). f is not O(g). Since it’s homework, you may need to fill in the details.
It’s also fairly easily to get an idea what the answer should be just by trying it with a large number. 1024 is 2^10, so taking n=1024:
f(n) = 10^10
g(n) = 1024/10.
Obviously that’s not a proof, but I think we can see who’s winning this race.