
下面是我的 MWE,我喜歡在投影機演示中對齊長方程,但方程的後面部分未在幻燈片中顯示。任何幫助,將不勝感激。
\documentclass{beamer}
\mode<presentation>
\usepackage{beamerthemesplit,graphics,graphicx,amssymb,amsmath,pgf,comment,hyperref}
\usepackage{breqn}
\usepackage[xcolor=pst]{pstricks}
\usepackage{pgfshade}
\usepackage[round]{natbib}
\usetheme{Warsaw}
\usefonttheme[onlylarge]{structuresmallcapsserif}
\setbeamercovered{highly dynamic}
\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10]
\setbeamertemplate{footline}{%
\begin{beamercolorbox}{section in head/foot}
\vskip2pt\centerline{\textcolor[rgb]{0.45,0.45,0.45}{\insertshorttitle}}\vskip2pt
\end{beamercolorbox}%
}
\renewcommand{\bibsection}{\subsubsection*{\bibname } }
\begin{document}
\begin{frame}
\frametitle{Expected utility comparision at renewal}
%\vspace{-0.3cm}
The expected utility of retaining the LTCI policy is written as:
%\begin{equation}
%\begin{align*}
\begin{dmath}
EU_{i}^R= \sum_{t=0}^{T} \beta \left[u_{i}\left\{W_{i}-\sum_{s=1}^5 Q_{t,s}\times P_{s}\right\}+\sum_{s=1}^5 Q_{t,s} \left\{u_{i}\left.(W_{i}-max\left.(X_{t,s}-B_{t,s},0\right)\right)\right\}\right]
%\end{align*}
%\end{equation}
\end{dmath}
\end{frame}
\end{document}
答案1
你有兩個選擇:
- 顯著減小方程式的字體大小(不建議)
- 將方程式分成兩行:
\documentclass{beamer}
\mode<presentation>
\usepackage{beamerthemesplit,graphics,graphicx,amssymb,amsmath,pgf,comment,hyperref}
\usepackage{breqn}
\usepackage[xcolor=pst]{pstricks}
\usepackage{pgfshade}
\usepackage[round]{natbib}
\usetheme{Warsaw}
\usefonttheme[onlylarge]{structuresmallcapsserif}
\setbeamercovered{highly dynamic}
\setbeamertemplate{background canvas}[vertical shading][bottom=red!10,top=blue!10]
\setbeamertemplate{footline}{%
\begin{beamercolorbox}{section in head/foot}
\vskip2pt\centerline{\textcolor[rgb]{0.45,0.45,0.45}{\insertshorttitle}}\vskip2pt
\end{beamercolorbox}%
}
\begin{document}
\begin{frame}
\frametitle{Expected utility comparision at renewal}
%\vspace{-0.3cm}
%\setlength{\noindent}
The expected utility of retaining the LTCI policy is written as:
\begin{multline*}
EU_{i}^R
= \sum_{t=0}^{T} \beta \left[u_{i}\left\{W_{i} -\sum_{s=1}^5 Q_{t,s}\times P_{s}\right\}\right. \\
+\left.\sum_{s=1}^5 Q_{t,s} \Bigl\{u_{i}\left(W_{i} - \max\left(X_{t,s}-B_{t,s},0\right)\right)\Bigr\}\right]
\end{multline*}
\end{frame}
\end{document}
編輯:
關於max
方程式中的單字:它是運算符,所以它的正確用法是\max
關於大括號:
- 大括號對或
\left{
不得包含& 符號或斷線。在這種情況下,您可以使用 example ,但他不能保證下一行中的類似構造將具有相同高度的大括號(因為它取決於內部內容)\right}
left[
\right]
\left[ ....\right. \\
- 對的高度
\left...
,\right...` 取決於它們之間的內容。他們還在之前/之後添加了小的水平空間。 - 大括號的高度,與它們之間的內容無關,您可以使用 、 等手動確定,
\big
其中\Big
添加\bigg
字母l
(\bigl
) 表示大括號位於左側,r
(\bigr)
表示大括號位於右側。
在上面的 MWE 中,我更改了第二個方程式行中大括號的大小。但是,您可以根據需要變更選定的高度。