1

I made a table for a subsection but when I script it, it doesnt show where it should (it shows in the middle and I want the table at the end of the subsection). The script goes like this:

\section{Resolucion}
\subsection{Ejercicio 1}
\paragraph{Para el aire:}
\paragraph{Para aproximar el efecto de la temperatura sobre la viscosidad contamos con los siguientes modelos experimentales:}
\subparagraph{Ley de la potencia $\frac{\mu }{\mu _{0}} \approx\left(\frac{T}{T_{0}}\right)^{n}$}
\subparagraph{Ley de Sutherland $\frac{\mu }{\mu _{0}} \approx \left(\frac{T}{T_{0}}\right)^{3/2}\left(\frac{T_{0} +S}{T+S}\right)$}
\paragraph{Sabemos que la viscosidad del aire a $P_{O}=1 atm$ y 20°C es $\mu_{0}=1,74E^{-5}$ y ademas los valores de las respectivas constantes son $n\approx0,7$ y $S\approx110,4K$. Iterando consecutivamente en cada modelo para las distintas temperaturas obtenemos que:}
\begin{table}[]
\begin{tabular}{|l|l|l|l|}
\hline
$T_{i}$ {[}ºC{]} & Potencia $\mu_{i}$ {[}kg/m.s{]} & Sutherland $\mu_{i}$ {[}kg/m.s{]} & Experimental $\mu_{i}$ {[}kg/m.s{]} \\ \hline
20               & $1,8244E^{-5}$                  & $1,8386E^{-5}$                    & $1,8E^{-5}$                         \\ \hline
40               & $1,9068E^{-5}$                  & $1,9339E^{-5}$                    & $1,9E^{-5}$                         \\ \hline
60               & $1,9876E^{-5}$                  & $2,0264E^{-5}$                    & $2,0E^{-5}$                         \\ \hline
80               & $2,0668E^{-5}$                  & $2,1161E^{-5}$                    & $2,05E^{-5}$                        \\ \hline
\end{tabular}
\end{table}
4
  • 1
    Welcome to TeX SX! Try adding the placement option begin{table}[!h].
    – Bernard
    Commented Aug 30, 2020 at 23:44
  • 4
    \paragraph and \subparagraph are section headings like \section the argument should be the title not the whole text of the section. Commented Aug 30, 2020 at 23:51
  • @Bernard hi! i tried using !h but it didnt move it all the way to the end of the subsection, any variants to that modification that may push it? thanks btw Commented Aug 31, 2020 at 0:09
  • 1
    Not mentioned in the answer, but worth remembering: It is (almost) always a good idea to leave a blank line before entering the code for a float. It's much easier to control that way. Commented Jan 23, 2022 at 22:28

1 Answer 1

1

Here is an example using the float and tabularx packages. Notice how the commands \paragraph{} or \subparagraph{} cause all of the text to become bold. This is because they generate a header for a paragraph, and may be unnecessary. The text is generated in paragraphs without headers by omission of these commands. I included one header for a paragraph called "Name" as an example for the use of the \paragraph{} command.

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{tabularx,booktabs}
\usepackage{float}
\floatstyle{plaintop}
\restylefloat{table}

\begin{document}
\section{Resolucion}
\subsection{Ejercicio 1}
\paragraph{Para el aire:}
Para aproximar el efecto de la temperatura sobre la viscosidad contamos con los siguientes modelos experimentales:
\subparagraph{Ley de la potencia}
 $\frac{\mu }{\mu _{0}} \approx\left(\frac{T}{T_{0}}\right)^{n}$
\subparagraph{Ley de Sutherland}
 $\frac{\mu }{\mu _{0}} \approx \left(\frac{T}{T_{0}}\right)^{3/2}\left(\frac{T_{0} +S}{T+S}\right)$
\paragraph{Name}
Sabemos que la viscosidad del aire a $P_{O}=1 atm$ y 20°C es $\mu_{0}=1,74E^{-5}$ y ademas los valores de las respectivas constantes son $n\approx0,7$ y $S\approx110,4K$. Iterando consecutivamente en cada modelo para las distintas temperaturas obtenemos que:

\begin{table}[H]
\begin{tabularx}{\textwidth}{|X|X|X|X|}
\hline
$T_{i}$ {[}ºC{]} & Potencia $\mu_{i}$ {[}kg/m.s{]} & Sutherland $\mu_{i}$ {[}kg/m.s{]} & Experimental $\mu_{i}$ {[}kg/m.s{]} \\ \hline
20               & $1,8244E^{-5}$                  & $1,8386E^{-5}$                    & $1,8E^{-5}$                         \\ \hline
40               & $1,9068E^{-5}$                  & $1,9339E^{-5}$                    & $1,9E^{-5}$                         \\ \hline
60               & $1,9876E^{-5}$                  & $2,0264E^{-5}$                    & $2,0E^{-5}$                         \\ \hline
80               & $2,0668E^{-5}$                  & $2,1161E^{-5}$                    & $2,05E^{-5}$                        \\ \hline
\end{tabularx}
\end{table}

\end{document}

Not the answer you're looking for? Browse other questions tagged .