
\newcommand{\vx}{\ensuremath{\mathbf{x}} }
\newcommand{\vv}{\ensuremath{\mathbf{x}} }
\newcommand{\vu}{\ensuremath{\mathbf{u}} }
\newcommand{\n}{\ensuremath{\mathbf{n}} }
\newcommand{\R}{\ensuremath{\mathbb{R}} }
\newcommand{\curl}[1]{\nabla \times #1} % for curl
\newcommand{\sa}[1]{\hyperref[#1]{#1}}
\newcommand{\ventry}[1]{\begin{sideways}#1\end{sideways}}


\newcommand\optiontable[1]{\begin{tabularx}{\linewidth}{llcX}\hline #1 \end{tabularx}}

\newcommand\cmdgroup[1]{\multicolumn{4}{l}{\bf #1}\\\hline}
\newcommand\cmdopt[4]{\texttt{-{}-#1} & \ifthenelse{\equal{#2}{}}{}{\texttt{-#2}} & #3 & #4 \\\hline}

\newcommand\optinset{\cmdopt{in-file}{i}{string}{input segmentation set}}
\newcommand\optoutset{\cmdopt{out-file}{o}{string}{output segmentation set}}


\newcommand\optinfile{\cmdopt{in-file}{i}{string}{input file name}}
\newcommand\optreffile{\cmdopt{ref-file}{r}{string}{reference image file name}}
\newcommand\optoutfile{\cmdopt{out-file}{o}{string}{output file name}}
\newcommand\optoutbase{\cmdopt{out-base}{o}{string}{output file name base - a number and the type suffix 
    will be added automatically}}
\newcommand\opttypetwod{\cmdopt{type}{t}{string}{output image file type (Table \ref{tab:fileformats})}}
\newcommand\opttypetwodb{\cmdopt{type}{t}{string}{output image file type (Table \ref{tab:fileformats})}}
\newcommand\opttypethreed{\cmdopt{type}{t}{string}{output image file type (Table \ref{tab:fileformats})}}
\newcommand\optrepn{\cmdopt{repn}{r}{string}{output pixel type (Table \ref{tab:pixform}), 
                                             must be supported by the output file type (Table \ref{tab:fileformats})}}
\newcommand\opthelpplugin{\cmdopt{help-plugins}{}{}{print out all plugins and a short description}}

\newcommand\plugtabstart{\begin{tabular}{|p{0.1\columnwidth}|p{0.1\columnwidth}|p{0.5\columnwidth}|p{0.1\columnwidth}|}\hline
Name & Type & Description & Default \\\hline\hline} 
\newcommand\plugtabend{\hline\end{tabular}}

\newcommand\miamex{{\tt miamex} }
\newcommand{\tw}[1]{{\tt #1}}
