![一些表格问题](https://linux22.com/image/335880/%E4%B8%80%E4%BA%9B%E8%A1%A8%E6%A0%BC%E9%97%AE%E9%A2%98.png)
有人能帮我解决我遇到的一些表格问题吗?基本上,我的表格超出了页面范围(我不太擅长用文本定义表格),如果有人有其他好主意可以让这个表格更整洁,我将不胜感激。这是我正在使用的代码:
\documentclass[a4paper]{article}
\usepackage{amsmath}
\usepackage[english]{babel}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage[margin=1.25in,top=1in,bottom=1in]{geometry}
\makeatletter
\setlength\parindent{0pt}
\usepackage{ amssymb }
\usepackage{booktabs}% http://ctan.org/pkg/booktabs
\newcommand{\tabitem}{~~\llap{\textbullet}~~}
\begin{document}
\begin{tabular}{llll}
\toprule
Topics & General $(n \times n)$ matrix & Hermitian & Real Symmetric \\
\midrule
Eigenvalues & Always have $n$ eigenvalues, \\
& some may be repeated or c.c & All real eigenvalues & Real symmetric \\[.5\normalbaselineskip]
Eigenvectors & \\ \tabitem eigenvectors are l.i \\ for distinct eigenvalues \\
\tabitem If there are $n$ distinct \\ eigenvalues, then the eigenvectors forms \\ a basis for $C^n$ \\ & Orthogonal for distinct eigenvalues \\ & They always form an orthonormal matrix \\
\bottomrule
\end{tabular}
\end{document}
我不太熟悉在表格中添加较长的文本,因为我主要用它来显示数字,但如果有人能给出一些建议,我将不胜感激。
谢谢
答案1
我认为以下内容可能是您正在寻找的,但我不确定。
\documentclass[a4paper]{article}
\usepackage{amsmath}
\usepackage[english]{babel}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage[margin=1.25in,top=1in,bottom=1in]{geometry}
\usepackage{amssymb}
\usepackage{tabularx}
\usepackage{booktabs}% http://ctan.org/pkg/booktabs
\newcommand{\tabitem}{~~\llap{\textbullet}~~}
\begin{document}
\begin{tabularx}{\linewidth}{l>{\raggedright\arraybackslash}X>{\raggedright\arraybackslash}Xl}
\toprule
Topics & General $(n \times n)$ matrix & Hermitian & Real Symmetric \\
\midrule
Eigenvalues & Always have $n$ eigenvalues, some may be repeated or c.c & All real eigenvalues & Real symmetric \\
Eigenvectors & \tabitem eigenvectors are l.i for distinct eigenvalues \par
\tabitem If there are $n$ distinct eigenvalues, then the eigenvectors forms a basis for $C^n$ & Orthogonal for distinct eigenvalues They always form an orthonormal matrix \\
\bottomrule
\end{tabularx}
\end{document}