[Tex/LaTex] Epsilon and log functions

amsmathmath-mode

I m trying this

T(n) \epsilon \left(\Theta(n^\log_22$\right) = $\Theta(n^\log_22 )$ = $\Theta(n)$

but i want below result. Is E sign is epsilon only . And also log bracket not coming properly and space before aND AFTER EPSILON NOT CORRECT.

enter image description here

Generally online it is given as

\[

    $A(n) \in \Theta(n^{\log_b a}) = \Theta(n^{\log_2 2} ) = \Theta(n)$

\]

so i am asking what these \[ and \] brackets do.

Best Answer

  • Don't use \epsilon for "element of"; instead, use the \in macro.

  • You need to place curly braces around the material that's to be placed in the exponent positions.

  • Don't switch in and out of math mode in one and the same equation.

enter image description here

\documentclass{article}
\begin{document}
$A(n) \in \Theta(n^{\log_b a}) = \Theta(n^{\log_2 2} ) = \Theta(n)$
\end{document}
Related Question