변수 사용 \tabularx: 추가 열을 추가하는 방법은 무엇입니까?

변수 사용 \tabularx: 추가 열을 추가하는 방법은 무엇입니까?

무슨 일이에요?

tabularx방정식 아래 범례의 사용을 단순화하기 위해 -environment를 구축했습니다 . 이것은 두 개의 열이 있는 매우 일반적인 테이블입니다.


최소 작업 예(MWE):

\documentclass{scrartcl}

\usepackage{amsmath}
\usepackage[english, ngerman]{babel}
\usepackage{tabularx}

    \newenvironment{legend*}{
        \begingroup
            \tabularx{\columnwidth}{>{$}l<{$} @{${}\hspace{1.5em}{}$} >{\raggedright\arraybackslash}X}}
            {\endtabularx\par\vspace{\belowdisplayskip}
            \par
        \endgroup
    }

\begin{document}

    \begin{legend*}
        P_{ges} & Power [unit] \\
        A_{ges} & Area [unit] \\
        V_{ges} & Volume [unit]
    \end{legend*}

\end{document}

결과 스크린샷:

두 개의 열을 볼 수 있습니다. 왼쪽 열은 변수 이름이고 오른쪽 열은 설명 및 관련 단위입니다.


질문:

텍스트 자체에서는 이 환경을 호출하고 \begin{environment}테이블에 입력을 제공하기만 하면 됩니다. 다만, 이전 설명과 단위를 구분하기 위해 오른쪽에 추가 컬럼을 추가하고 싶습니다. 어떻게 얻을 수 있나요?


그러면 다음과 같이 보일 것입니다:

\begin{legend*}
    P_{ges} & Power & [unit] \\
    A_{ges} & Area & [unit] \\
    V_{ges} & Volume & [unit]
\end{legend*}

당신의 도움을 주셔서 대단히 감사합니다!

답변1

@David Carlisle에게 감사드립니다!

\tabularx{\columnwidth}{>{$}l<{$} @{${}\hspace{1.5em}{}$} >{\raggedright\arraybackslash}X l }

... 해결책을 가져왔습니다!

관련 정보