does $n^{1/2} = 2^{(\log n) / 2}$?

62 Views Asked by At

I'm reviewing the textbook "Introduction to Algorithms" and I'm stuck on a manipulation... if we have $m = \log n$

Then the book substitutes for $\sqrt n$, the operation $2^{m/2}$. I don't see how this is done. I tried to manipulate this myself:

$\log n^{1/2} = (1/2)\log n = (1/2)m$ But this is not getting me to the desired outcome. Thanks

4

There are 4 best solutions below

0
On BEST ANSWER

For $x>0 \ \sqrt{x} = x^{\frac{1}{2}} = 2^{\log_2 x^{\frac{1}{2}}} = 2^{\frac{\log_2 x}{2}}$

0
On

Maybe $$n^{\frac{1}{2}}=2^{\frac{\log_2n}{2}}$$? If so, it's true because $$2^{\frac{\log_2n}{2}}=2^{\log_2\sqrt{n}}=\sqrt{n}.$$

0
On

$$m= \log_2 n \Rightarrow \frac m2 = \frac 12 \log_2 n\Rightarrow \frac m2 = \log_2 n^{1/2} \Rightarrow 2^{m/2} = n^{1/2}$$

0
On

Similarly

$$n^{\frac{1}{2}} = \exp(\ln (n^{\frac{1}{2}})) = \exp \left(\frac{1}{2}\ln n \right)$$