## LaTeX forum ⇒ Graphics, Figures & Tables ⇒ Problem with equation in table

Information and discussion about graphics, figures & tables in LaTeX documents.
mexxwel
Posts: 1
Joined: Mon Nov 16, 2015 10:54 am

### Problem with equation in table

Hey there!

I'd like to create a table with two parameters and the corresponding equation.
Somehow Latex gives me the error: '! Missing $inserted.' and I don't know what that means... \begin{table}[H]\centering\caption{XXX}\label{tab:XXX}\begin{adjustbox}{max width=\textwidth} \begin{tabular}{c c} \hline\hline \vspace{0.25cm} Parameter & Mathematical Equation \\ \hline \vspace{0.25cm} Standard Deviation & \sigma=\sqrt{\frac{\sum(X-\mu)$^2$}{N}} \\ \vspace{0.25cm} Variance & \sigma^2=\frac{\sum(X-\mu)$^2$}}{N} \\ \\ \hline \end{tabular}\end{adjustbox}\end{table} Thanks for your help! Tags: Johannes_B Site Moderator Posts: 3966 Joined: Thu Nov 01, 2012 4:08 pm Welcome, you put only the superscript in mathmode, but the whole equation needs to be in mathmode. Below, an example that sets the second column in math mode as a whole. \documentclass{article}\usepackage{mathtools}\usepackage{booktabs}\usepackage{array}\setlength{\defaultaddspace}{.75em}\begin{document}\begin{tabular}{c >{$\displaystyle}c<{$}} \toprule Parameter &$Mathematical Equation\$ \\			\midrule			Standard Deviation & \sigma=\sqrt{\frac{\sum(X-\mu)^2}{N}} \\\addlinespace			Variance           & \sigma^2=\frac{\sum(X-\mu)^2}{N} \\			\bottomrule		\end{tabular}\end{document}
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.