\rbrace 垂直對齊

\rbrace 垂直對齊

我嘗試解決以下問題一段時間,但尚未找到解決方案。我想垂直對齊兩個 \r大括號。這段程式碼

\begin{align}
  L = &\left. \text{short eq} \right\rbrace &&\text{description 1} \\
      &\left. \begin{aligned}
                \text{very long equation}\\
                \text{over multiple lines}
              \end{aligned}
       \right\rbrace &&\text{description 2}
\end{align} 

產生

在此輸入影像描述

但是,我想調整它們位於彼此下方的支架

在此輸入影像描述

我希望有人能在這裡幫助我。謝謝你!

答案1

像這樣的東西嗎?

在此輸入影像描述

\documentclass{article} 
\usepackage{amsmath} % for 'align' environment and '\text' macro
\newlength\mylen     % create a "length" variable
\settowidth\mylen{very long equation} % calculate default width of '\mybox'
\newcommand\mybox[2][\mylen]{\parbox{#1}{\raggedright #2}}

\begin{document}
\begin{align}
L = &\left.\mybox{short eq}\right\rbrace &&
     \text{description 1} \\
    &\left.\mybox{very long equation over multiple lines}\right\rbrace &&
     \text{description 2}
\end{align} 
\end{document}

答案2

像這樣的事情怎麼樣?

\documentclass{article}
\usepackage{amsmath}
\begin{document}

\begin{equation}
\begin{alignedat}{4}
 L = & \text{short eq } && \left. \text{ }  \right\rbrace  && \qquad \text{description 1} \\
     &\begin{aligned}
         &\text{22244 very long equation 5555}\\
         &\text{over multiple lines }
      \end{aligned} && \left. 
      \begin{aligned}
           \text{ }\\
           \text{ }
      \end{aligned}  \right\rbrace && \qquad \text{description 2}
\end{alignedat}
\end{equation}

\end{document}

看起來像這樣 在此輸入影像描述

所有的線都被視為一個方程式。我從下面的帖子中藉用了這個想法。

多線方程式的垂直對齊

相關內容