# Building chemical “ICE” tables with tabular environment

I am starting to write my chemistry lab reports out in LaTeX, but keep getting stuck on the "ICE" tables (see the LaTeX example below).

I can't figure out how to get the + and \rightleftharpoons in the heading to go in between the columns. They should be in the middle between the columns (almost over the &).

    \begin{tabular}[c|ccc]
\hline
X   &   $[H^+]$ $+$ & $[OH^-]$  $\leftrightharpoons$ & $[H_2O]$ \\
\hline
I   &       x.xx    &   x.xx                         &  x.xx    \\
C   &       x.xx    &   x.xx                         &  x.xx    \\
E   &       x.xx    &   x.xx                         &  x.xx    \\
\hline
\end{tabular}


I tried to find a photo example, but there didn't seem to be any on Google Images. Seems like I'm not the only one who hasn't figured out a good way to do this.

-
Welcome to TeX.sx!. You should always post minimal working example (MWE). –  hpesoj626 Mar 11 '13 at 3:05

Firstly, the column specification of tabular requires to be supplied using {..}, not [..]. Secondly, this might be what you're after: inserting a @{}c@{} column to contain the operator. The @{} removes the tabular separation on either side of the c-column.

\documentclass{article}
\usepackage{amssymb}% http://ctan.org/pkg/amssymb
\begin{document}
\begin{tabular}{c|c@{}c@{}c@{}c@{}c}
\hline
X   &   $[H^+]$ & ${}+{}$ & $[OH^-]$ & ${}\leftrightharpoons{}$ & $[H_2O]$ \\
\hline
I   &       x.xx    &&   x.xx                         &&  x.xx    \\
C   &       x.xx    &&   x.xx                         &&  x.xx    \\
E   &       x.xx    &&   x.xx                         &&  x.xx    \\
\hline
\end{tabular}
\end{document}


Using additional braces (empty groups) around the operators allows for proper spacing.

Finally, consider using the booktabs package for a prettier layout of your tables. Here's a take on it:

\documentclass{article}
\usepackage{fixltx2e,booktabs,amssymb}% http://ctan.org/pkg/{booktabs,amssymb}
\begin{document}
\begin{tabular}{cc@{}c@{}c@{}c@{}c}
\toprule
X   &   [H\textsuperscript{+}] & ${}+{}$ & [OH$^-$] & ${}\leftrightharpoons{}$ & [H\textsubscript{2}O] \\
\midrule
I   &       x.xx    &&   x.xx                         &&  x.xx    \\
C   &       x.xx    &&   x.xx                         &&  x.xx    \\
E   &       x.xx    &&   x.xx                         &&  x.xx    \\
\bottomrule
\end{tabular}
\end{document}

-
I would suggest the use of the mhchem package to typeset chemical compounds (using e.g. \ce{OH-}) –  Lionel MANSUY Mar 11 '13 at 8:18
Thank you, solves my problem. –  Michael Molter Mar 11 '13 at 21:41