Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top
 Please could someone advise on the two questions below. I have to expand the functions
 first. Admittedly, I have a weak understanding of logs. Then I try to ascertain a 
 Big-O estimate. Any help would be appreciated. 

 1.) (nlogn + n^2)(n^3 +2)

 Expanding the above.. Is it correct to say
 nlogn(n^3) + nlogn(2) + n^2(n^3) + n^2(2)

 ==> n^3 (due to the cancellation laws) +2nlogn + n^5 +2n^2
 ==> therefore a Big-O estimate would be n^5 ??

 2.)  nlog(n^2 +1) + n^2logn
  expanding the above it correct to say
  2nlogn + nlogn + n^2logn
  As n<n^2logn<n^2, 
  the Big - O estimate is (n^2)?
share|cite|improve this question
up vote 2 down vote accepted

On the first problem, the dominant term is $n^5$, so it's $O(n^5)$. On the second one, your dominant termis $n^2\log(n)$ so it is $O(n^2\log(n))$.

share|cite|improve this answer
thx ncmathsadist – bosra Oct 8 '12 at 16:57

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.