2

enter image description here

3 Questions:

  1. Ways to change the position of the arrows in between the pictures? (Preferably in the middle)
  2. If possible, how do I add small text above or below the arrows?
  3. Lastly, how can I modify the vertical axis label in image 2? (-2.5k and 2.5k)

My Code:

\documentclass[10pt, twoside]{article}
\usepackage[utf8]{inputenc}
\usepackage{pgfplots}
\usepackage{tikz}
\pgfplotsset{compat=1.18, width=10cm}
\usepackage[fleqn]{amsmath}
\usepackage{amssymb}

%%%%%%%%%%%%%%%First image

\hspace{-40pt}\begin{tikzpicture}
\begin{axis}[compat=newest,
axis x line=center ,
axis y line=center ,
xlabel = {$y$} ,
ylabel = {$x$} ,
xlabel style={right} ,
ylabel style={above} ,
xtick = {11},
ytick = {-2.5,2.5},
xmin=-0.6 ,
xmax=12.1 ,
ymin=-4.1 ,
ymax=4.1,axis on top,
scale=0.45,
unit vector ratio=1 1 1,
clip = false,
title = Original plot]

\addplot [domain=0:11, samples=200]{0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\addplot [domain=0:11, samples=200]{-0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\end{axis}
\end{tikzpicture}%%%%%%%%%%%%%%%Second Image
\hspace{2pt}$\longrightarrow$\hspace{2pt}
\begin{tikzpicture}
\begin{axis}[compat=newest,
axis x line=center ,
axis y line=center ,
xlabel = {$y$} ,
ylabel = {$x$} ,
xlabel style={right} ,
ylabel style={above} ,
xtick = {0},
extra x ticks={10.8995},
    extra x tick style={
        grid=minor,
        xticklabel={$11k$},
        xticklabel style={xshift=0.7ex, anchor=north}},
ytick = {0},
extra y ticks={2.4772},
    extra y tick style={
        grid=major,
        yticklabel={$2.5k$},
        yticklabel style={yshift=0.7ex, anchor=east}},
xmin=-0.6 ,
xmax=12.1 ,
ymin=-4.1 ,
ymax=4.1,axis on top,
scale=0.45,
unit vector ratio=1 1 1,
clip = false,
title = Scaled plot to match the model]

\addplot [domain=0:10.8995, samples=200]{0.825723*(1.010408384*(sqrt(0.825723*x))-0.0004182726234*(0.825723*x)^4+0.01182267004*(0.825723*x)^3-0.1768908372*(0.825723*x)^2+0.9358325433*(0.825723*x))};
\addplot [domain=0:10.8995, samples=200]{-0.825723*(1.010408384*(sqrt(0.825723*x))-0.0004182726234*(0.825723*x)^4+0.01182267004*(0.825723*x)^3-0.1768908372*(0.825723*x)^2+0.9358325433*(0.825723*x))};

\node at (6.5,1.8) {\small$f(y)=c\cdot h(cy)$};
\node at (6.5,0.8) {\small$c\approx 0.825723$};
\end{axis}
\end{tikzpicture}%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%Third Image
\hspace{2pt}$\longrightarrow$\hspace{2pt}
\begin{tikzpicture}
\begin{axis}[compat=newest,
axis x line=center ,
axis y line=center ,
xlabel = {$y$} ,
ylabel = {$x$} ,
xlabel style={right} ,
ylabel style={above} ,
xtick = {11},
ytick = {-2.5,2.5},
xmin=-0.6 ,
xmax=12.1 ,
ymin=-4.1 ,
ymax=4.1,axis on top,
scale=0.45,
unit vector ratio=1 1 1,
clip = false,
title = Transform back to the original plot]

\addplot [domain=0:11, samples=200]{0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\addplot [domain=0:11, samples=200]{-0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\node at (6.7,1.8) {\small$f(y)=\frac{c}{k}\cdot h\left(cky\right)$};
\node at (6.7,0.8) {\small$c\approx 0.825723$};
\end{axis}
\end{tikzpicture}
\end{document}

2 Answers 2

5

You could draw this in one single tikzpicture using shifted scopes, then adding your arrows between them. I used standalone document class because your margins aren't correctly set to show the entire picture.

EDIT

I didn't see that there were three questions in one at the firt time, so I just edited my answer to put text underneath the arrows and change the y ticks on the second graph.

V2

\documentclass[tikz,border=3.14mm]{standalone}
% https://tex.stackexchange.com/questions/655344/how-to-change-the-position-of-arrows-between-separate-tikzpicture

\usepackage[utf8]{inputenc}
\usepackage{pgfplots}
\pgfplotsset{compat=1.18, width=10cm}
\usepackage[fleqn]{amsmath}
\usepackage{amssymb}

\begin{document}
%%%%%%%%%%%%%%%First image

\begin{tikzpicture}

\begin{axis}[compat=newest,
axis x line=center ,
axis y line=center ,
xlabel = {$y$} ,
ylabel = {$x$} ,
xlabel style={right} ,
ylabel style={above} ,
xtick = {11},
ytick = {-2.5,2.5},
xmin=-0.6 ,
xmax=12.1 ,
ymin=-4.1 ,
ymax=4.1,axis on top,
scale=0.45,
unit vector ratio=1 1 1,
clip = false,
title = Original plot]

\addplot [domain=0:11, samples=200]{0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\addplot [domain=0:11, samples=200]{-0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\end{axis}

\begin{scope}[xshift=6cm]

\begin{axis}[compat=newest,
axis x line=center ,
axis y line=center ,
xlabel = {$y$} ,
ylabel = {$x$} ,
xlabel style={right} ,
ylabel style={above} ,
xtick = {0},
extra x ticks={10.8995},
    extra x tick style={
        grid=minor,
        xticklabel={$11k$},
        xticklabel style={xshift=0.7ex, anchor=north}},
ytick = {-2.4772,2.4772},
yticklabels={$-2.5k$,$2.5k$},
xmin=-0.6 ,
xmax=12.1 ,
ymin=-4.1 ,
ymax=4.1,axis on top,
scale=0.45,
unit vector ratio=1 1 1,
clip = false,
title = Scaled plot to match the model]

\addplot [domain=0:10.8995, samples=200]{0.825723*(1.010408384*(sqrt(0.825723*x))-0.0004182726234*(0.825723*x)^4+0.01182267004*(0.825723*x)^3-0.1768908372*(0.825723*x)^2+0.9358325433*(0.825723*x))};
\addplot [domain=0:10.8995, samples=200]{-0.825723*(1.010408384*(sqrt(0.825723*x))-0.0004182726234*(0.825723*x)^4+0.01182267004*(0.825723*x)^3-0.1768908372*(0.825723*x)^2+0.9358325433*(0.825723*x))};

\node at (6.5,1.8) {\small$f(y)=c\cdot h(cy)$};
\node at (6.5,0.8) {\small$c\approx 0.825723$};
\end{axis}

\end{scope}

\begin{scope}[xshift=12cm]

\begin{axis}[compat=newest,
axis x line=center ,
axis y line=center ,
xlabel = {$y$} ,
ylabel = {$x$} ,
xlabel style={right} ,
ylabel style={above} ,
xtick = {11},
ytick = {-2.5,2.5},
xmin=-0.6 ,
xmax=12.1 ,
ymin=-4.1 ,
ymax=4.1,axis on top,
scale=0.45,
unit vector ratio=1 1 1,
clip = false,
title = Transform back to the original plot]

\addplot [domain=0:11, samples=200]{0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\addplot [domain=0:11, samples=200]{-0.83333*(1.010408384*(sqrt(0.81818*x))-0.0004182726234*(0.81818*x)^4+0.01182267004*(0.81818*x)^3-0.1768908372*(0.81818*x)^2+0.9358325433*(0.81818*x))};
\node at (6.7,1.8) {\small$f(y)=\frac{c}{k}\cdot h\left(cky\right)$};
\node at (6.7,0.8) {\small$c\approx 0.825723$};
\end{axis}

\end{scope}

\draw[->] (4.5,1.22) --++ (1,0) node[midway,below]{first};
\draw[->] (10.5,1.22) --++ (1,0) node[midway,below]{second};
\end{tikzpicture}
\end{document}


2
  • Just edited my answer to comply with all three questions from OP and not just the arrows.
    – SebGlav
    Aug 28 at 8:39
  • 1
    Thank you so much. Problem Solved!!! Aug 28 at 10:20
1

You could try and encapsulate your tikzpicture environments in minipages, using the default central position:

\begin{minipage}{some_length}
  \begin{tikzpicture}
    ...
  \end{tikzpicture}
\end{minipage}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.