Tikz 图表在研究论文中的位置

Tikz 图表在研究论文中的位置

我正在使用 tikz 环境绘制结果图。运行代码后,图表绘制在研究论文底部的参考标题之后,但在 latex 中,图表代码插入在研究论文之间。

那么,如何将图表定位在研究论文的适当位置。

\begin{figure}\small
        \begin{minipage}[b]{.57\linewidth}
            \centering
            \begin{tikzpicture}
            \begin{axis}[
            xlabel={Migration Time (Seconds)},
            ylabel={Bandwidth Transfer Rate (Mbps)},
            xmin=0, xmax=50,
            ymin=0, ymax=550,
            xtick={0,10,20,30,40,50},
            tick={0,100,200,300,400,500,550},
            legend pos=north west,
            %ymajorgrids=true,
            grid style=dashed,
            ]
            \addplot+[
            color=blue,
            mark size=50pt,
            mark=solid,
            style={ultra thick},
            ]
            coordinates {
                (14.551,100)
                (0,100)(10,100)(20,100)(30,100)(40,100) (50,100)};
            \legend{Idle VM}
            %\addlegendentry{Downtime:232ms}
            %\addplot [variable=\t,samples=200,domain=0:360] ({0.950052*cos(t)},{0.945021*sin(t)});
            %\addlegendentry{Parametric analytic}
            %\legend{Downtime:233ms}
            %\draw[blue] (axis cs: 28,131) -- (axis cs: 28,131)node[anchor=east,rotate=90]{Some label};
            %\draw (axis cs:28,axis cs:131);

            %\addplot[solid, purple, latex-latex]
            %coordinates{(28,0) (28,131)};

            \addplot[color=purple,mark=triangle*,mark size=2,style={thick},mark options={solid}] coordinates {
                (14.551,0)
                (14.551,100)
            };
            \node at (axis cs:38,500) {Downtime: 144 ms};

            %title={Fig. 1.Live Migration Process with Bw=131Mbps},
            \end{axis}
            %title={Temperature dependence of CuSO$_4\cdot$5H$_2$O solubility},

            \end{tikzpicture}
            \subcaption{Live Migration Process with Bw= 100 Mbps}\label{fig:10a}
        \end{minipage}
        \begin{minipage}[b]{.57\linewidth}
            \centering
            \begin{tikzpicture}
            \begin{axis}[
            xlabel={Migration Time (Seconds)},
            ylabel={Bandwidth Transfer Rate (Mbps)},
            xmin=0, xmax=50,
            ymin=0, ymax=550,
            xtick={0,10,20,30,40,50},
            tick={0,100,200,300,400,500,550},
            legend pos=north west,
            %ymajorgrids=true,
            grid style=dashed,
            ]

            \addplot+[
            color=blue,
            mark size=50pt,
            mark=solid,
            style={ultra thick},
            ]
            coordinates {
                (11.124,200)
                (0,200)(10,200)(20,200)(30,200)(40,200) (50,200)};
            \legend{Idle VM}
            %\addlegendentry{Downtime:232ms}
            %\addplot [variable=\t,samples=200,domain=0:360] ({0.950052*cos(t)},{0.945021*sin(t)});
            %\addlegendentry{Parametric analytic}
            %\legend{Downtime:233ms}
            %\draw[blue] (axis cs: 28,131) -- (axis cs: 28,131)node[anchor=east,rotate=90]{Some label};
            %\draw (axis cs:28,axis cs:131);

            %\addplot[solid, purple, latex-latex]
            %coordinates{(28,0) (28,131)};

            \addplot[color=purple,mark=triangle*,mark size=2,style={thick},mark options={solid}] coordinates {
                (11.124,0)
                (11.124,200)
            };
            \node at (axis cs:38,500) {Downtime: 92 ms};

            %title={Fig. 1.Live Migration Process with Bw=131Mbps},
            \end{axis}
            %title={Temperature dependence of CuSO$_4\cdot$5H$_2$O solubility},
            \end{tikzpicture}

相关内容