edited by
1,505 views
3 votes
3 votes
$T(n)=4 T(n/2) + n^2 \sqrt{2}$

I have solved this by back substitution .. and it forms equations of the form

$4k T(n/2k) + k n^2 \sqrt 2$

its giving time complexity as n2 + n2 log2n

the answer is Theta(n2.5).

i have two questions .. a) how can we get Theta(n2.5).

b) is n2 log2n Asymptotically faster than n2 ?
edited by

1 Answer

1 votes
1 votes

O(n^2) is a subset of O((n^2) * log(n)), and thus the first is "better", it is easy to see that since log(n) is an increasing function, by multiplying something with it, you get a "higher" function then the original (f(n) <= f(n) * log(n) for each increasing non negative f and n>2).

Source: StackOverflow

Related questions

1 votes
1 votes
0 answers
1
syncronizing asked Mar 15, 2019
1,293 views
Is this the correct way to solve ?Q) int algorithm(int n){ int sum =0;k,j; for (k=0;k<n/2;k++) for(j=0;j<10;j++) sum++; return 4*algorithm(n/2)*algorit...
1 votes
1 votes
1 answer
2
VikramRB asked Jan 20, 2019
1,037 views
What is the time complexity of the following recurrence relation and step to derive the same$T(n) = T(\sqrt{n}) + log(logn)$
0 votes
0 votes
0 answers
4
garvit_vijai asked Nov 17, 2018
467 views
How to solve the following recurrence relation?T(n) = T(n-6) + n2 , n>7T(n) = 1 , n<= 7