# Dimensions of Various Lie Groups

How do you determine the dimensions of a Lie group? Why is the dimension of $O(n)$ the same as $SO(n)$? Similarly for $\text{GL}(n,F)$ and $\text{GL}^+(n,F)$, where $F$ is a field?