Is there a way to use tabular or some other method to create a table that expands to use the entire available space? So if I created a table with 4 rows, each row would use 25% of the space. Thanks!
[Tex/LaTex] Creating a table that uses all available space
horizontal alignmenttables
Related Solutions
\documentclass{article}
\usepackage{mathtools}
\begin{document}
\subsubsection*{Fourier Transform properties}
{\def\arraystretch{2}\tabcolsep=10pt
\begin{tabular}{@{}l | l | l | l @{}}
Property & Time domain & Frequency domain & Condition \\
\hline
Time-shift & $f(t - \tau)$ & $\hat{f}(\omega)e^{-i \omega \tau}$ \\
Frequency-shift & $f(t) e^{i \omega_0 t}$ & $\hat{f}(\omega - \omega_0)$ \\
\rule{0pt}{5ex}% EXTRA vertical height
Modulation Thm. & $f(t)\cos(\omega_0 t)$ & $\dfrac{ \hat{f}(\omega-\omega_0)+\hat{f}(\omega+\omega_0) }{2}$ \\
Differentiation (time) & $f^{(n)}(t)$ & $(i\omega)^n \hat{f}(\omega)$ & $\displaystyle\lim_{\mathclap{t \to \pm \infty}} f(t) = 0$
\end{tabular}%
}
\end{document}
another possibility is to use package tabls
. But this may cause problems when using other tabular packages. Try it and maybe the possible optional arguments are of interest, as minimal distance between tabulkar lines.
\documentclass{article}
\usepackage{mathtools}
\usepackage{tabls}
\begin{document}
\subsubsection*{Fourier Transform properties}
{\tablinesep=2ex\tabcolsep=10pt
\begin{tabular}{@{}l | l | l | l @{}}
Property & Time domain & Frequency domain & Condition \\
\hline
Time-shift & $f(t - \tau)$ & $\hat{f}(\omega)e^{-i \omega \tau}$ \\
Frequency-shift & $f(t) e^{i \omega_0 t}$ & $\hat{f}(\omega - \omega_0)$ \\
Modulation Thm. & $f(t)\cos(\omega_0 t)$ & $\dfrac{ \hat{f}(\omega-\omega_0)+\hat{f}(\omega+\omega_0) }{2}$ \\
Differentiation (time) & $f^{(n)}(t)$ & $(i\omega)^n \hat{f}(\omega)$ & $\displaystyle\lim_{\mathclap{t \to \pm \infty}} f(t) = 0$
\end{tabular}%
}
\end{document}
Just put the tabular into one of the cell, as said by David Carlisle: you can nest itemize or tabular inside a longtable cell in a p column.
Code
\documentclass{article}%[border=10pt]{standalone}
\usepackage[left=0.5cm,right=0.5cm,top=0.5cm,bottom=0.5cm]{geometry}
\usepackage{multirow,lipsum,longtable,colortbl,xcolor}
\usepackage{dcolumn}%,tabularx,tabulary}%,threeparttable,longtable,tabu}
%
\setlength{\arrayrulewidth}{.3em}
\begin{document}
%
\begin{longtable}{%
|>{\columncolor{gray}}p{\dimexpr0.3\textwidth-2\tabcolsep-2\arrayrulewidth\relax}
|p{\dimexpr0.7\textwidth -2\tabcolsep-\arrayrulewidth\relax}|} \hline
\multicolumn{1}{|c|}{{\cellcolor{gray}} A column} &\multicolumn{1}{c|}{B column}\\ \hline
\lipsum[2] & \lipsum[3] \\
\lipsum[2] &
{\setlength{\arrayrulewidth}{.1em}
\begin{tabular}{|m{0.3\textwidth}|m{0.3\textwidth}|}\hline
A & B \\ \hline
A & B \\ \hline
A & B \\ \hline
\end{tabular}} \\
\lipsum[2] & \lipsum[3] \\
\hline
\end{longtable}
\end{document}
Best Answer
Possible with
\usepackage{tabularx}
I modified the code to add space vertically