2

I am using the beamer class in latex.

My code and result are like the following:

\begin{frame}{The Hamilton-Jacobi-Bellman Equation}
    \begin{columns}
        \begin{column}{.5\textwidth}
            \vfill
            \centering
            {\Huge{Discrete}}
            \\[\baselineskip]
            \begin{itemize}
                \item System
                \[
                    x_{k+1} = f(x_k, u_k)
                \]
                \[
                    k \in \{0, \ldots, N\}
                \]
                \item Cost
                \[
                    g_N(x_N) + \sum_{k=0}^{N-1}g_k(x_k, u_k)
                \]
                \item DP equation
                \[
                    J_N(x_N) = g_N(x_N)
                \]
                \[
                    J_k(x_k) = \min_{u_k\in U_k} [g_k(x_k, u_k) \hspace{5em}
                \]
                \[
                    \hspace{8em} + J_{k+1}(x_k, u_k)]
                \]
            \end{itemize}
            \vfill
        \end{column}
        \vrule width 1.5pt
        \begin{column}{.5\textwidth}
            \vfill
            \centering
            {\Huge{Continuous}}
            \\[\baselineskip]
            \begin{itemize}
                \item System
                \[
                    \dot{x}(t) = f(x(t), u(t))
                \]
                \[
                    t \in [0, T]
                \]
                \item Cost
                \[
                    h(x(T)) + \int_0^T g(x(t), u(t)) dt
                \]
                \item HJB equation
                \[
                    V(T, x) = h(x)
                \]
                \[
                    0 = \min_{u\in U}[g(x,u) + \nabla_t V(t, x) \hspace{4em}
                \]
                \[
                    \hspace{6.5em} + \nabla_x V(t, x)'f(x, u)]
                \]
            \end{itemize}
            \vfill
        \end{column}
    \end{columns}
\end{frame}

screen image

I want each line to be located on same horizontal line. However, My equations are located on different lines, e.g. Cost, equations items, etc.

Danny_Kim
  • 615
  • 1
    The obvious choice is to use a tabular (or tabularx). There are several example here (see http://tex.stackexchange.com/questions/114020/two-columns-of-equations-aligned-and-just-one-number-per-column for example). – John Kormylo Jul 12 '16 at 03:09
  • Another approach would be to close the columns after the two items which should be on the same height and open a new one for the following item. Is certainly not the shortest and cleanest code but will give the desired result. – samcarter_is_at_topanswers.xyz Jul 12 '16 at 09:18

1 Answers1

2

One of option -- see @John Kormylo comment -- is use of tabularx and advance math settings enabled with mathtools:

\documentclass{beamer}
\usepackage{tabularx}
\usepackage{mathtools}

\begin{document}
\begin{frame}{The Hamilton-Jacobi-Bellman Equation}
\renewcommand\arraystretch{1.2}
    \begin{tabularx}{\textwidth}{X | X}%\vrule width 1.5pt
\hfil\Large   Discrete      &   \hfil\Large   Continuous        \tabularnewline 
\textbullet\ System         &   \textbullet\ System             \tabularnewline 
    $\displaystyle\begin{multlined}[t][0.7\hsize]
x_{k+1} = f(x_k, u_k)   \\
          k \in \{0, \ldots, N\}
      \end{multlined}$      &
                                $\displaystyle\begin{multlined}[t][0.7\hsize]
                            \dot{x}(t) = f(x(t), u(t))   \\
                                      t \in [0, T]
                                  \end{multlined}$              \tabularnewline
\textbullet\ Cost           &   \textbullet\ Cost               \tabularnewline
    $\displaystyle
g_N(x_N) + \sum_{k=0}^{N-1}g_k(x_k, u_k)
    $                       &   $\displaystyle
                            h(x(T)) + \int_0^T g(x(t), u(t)) dt
                                $                               \tabularnewline
\textbullet\ DP equation    &   \textbullet\ HJB equation       \tabularnewline
    $\displaystyle\begin{multlined}[t][0.7\hsize]
J_N(x_N) = g_N(x_N) \vphantom{\int_0^T} \\
           J_k(x_k) = \min_{u_k\in U_k} [g_k(x_k, u_k)  \\
           + J_{k+1}(x_k, u_k)]
      \end{multlined}$      &   $\displaystyle\begin{multlined}[t][0.7\hsize]
                            h(x(T)) + \int_0^T g(x(t), u(t)) dt \\
                                            V(T, x) = h(x)      \\
                                            0 = \min_{u\in U}[g(x,u) + \nabla_t V(t, x)\\
                                            + \nabla_x V(t, x)'f(x, u)]
                                  \end{multlined}$  
    \end{tabularx}
\end{frame}
\end{document}

enter image description here

Zarko
  • 296,517