
\documentclass{article}
\usepackage{enumitem,amssymb}
\usepackage{amsmath}
\usepackage{multicol}
\usepackage{hyperref}
\usepackage{multirow}
\usepackage{xcolor}
\usepackage{array}
\usepackage{makecell}
\usepackage{tabularx}
\usepackage{booktabs}
\newcolumntype{L}{>{\(} l <{\)}}
\begin{document}
\everymath{\displaystyle}
\renewcommand{\arraystretch}{2}
\begin{tabularx}{\textwidth}{|LLL|}
\hline
\sin 2x = 2 \cos x \sin x &
\parbox{101pt}{
\begin{flalign*}
\cos 2x & = \cos^2 x - \sin^2 x \\
& = 2\cos^2 x - 1 \\
& = 1 - 2\sin^2 x
\end{flalign*}
} &
\tan 2x = \frac{2\tan x}{1 - \tan^2 x} \\
\hline
\end{tabularx}
\end{document}
(간결함을 위해 코드의 중요한 부분만 여기에 표시됩니다.)
그림에서 볼 수 있듯이 모든 셀을 tabular
위쪽으로 정렬하고 싶습니다. 그렇게하는 방법?
참고: 표시할 방정식 행이 많기 때문에 표 형식이 필요하다고 생각합니다. 아래 그림을 참조하세요.
답변1
이를 위해서는 실제로 표 형식이 필요하지 않습니다. 환경 framed
주변의 간단한 환경이 flalign*
이를 수행합니다.
\documentclass{article}
\usepackage{enumitem,amssymb}
\usepackage{amsmath}
\usepackage{multicol}
\usepackage{hyperref}
\usepackage{multirow}
\usepackage[svgnames]{xcolor}
\usepackage{makecell}
\usepackage{tabularx}
\usepackage{booktabs}
\usepackage{framed}
\newcolumntype{L}{>{\(} l <{\)}}
\begin{document}
\setlength{\FrameRule}{0.6pt}
\renewcommand{\FrameCommand}{\setlength{\fboxrule}{0.6pt}\fcolorbox{Coral}{white}}
\begin{framed}
\begin{flalign*}
\sin 2x & = 2 \cos x \sin x & \cos 2x & = \cos^2 x - \sin^2 x & \tan 2x & = \smash{\frac{2\tan x}{1 - \tan^2 x}} \\
& & & = 2\cos^2 x - 1 \\
& & & = 1 - 2\sin^2 x
\end{flalign*}
\end{framed}
\end{document}