2

I have found this image in a paper, which is hard to read due to poor scanning, and I would like to create a more legible version:

enter image description here

I'm still fairly new to TikZ, so I'm not sure of the best way to start going about a diagram like this.

Freddie R
  • 123

1 Answers1

2

A slightly less painful method is to use the "Engauge Digitizer" app.

The Engauge Digitizer app is intuitive, works great for what I need and is open source.

If developers include the export in the format needed to use in Tikz, it would be even easier to use.

It is possible to convert arbitrary curves into coordinates and plot in tikz.

If what you want is to draw the figure with straight segments and arcs, Engauge will help you to determine the points of interest in scale from the figure, as shown in the second tikz file.

In Engauge, load the image, indicate the points that define the axes, and then select "scan along segments". On these curves, some points were not selected by the segments tool, I digitized them one by one (about ten points for these curves). If the curve is not smooth enough, change the position of some points with the reposition tool. I prefer to scan one curve at a time. When you're satisfied, export to csv, getting something like:

x,Curve1
"0,0836","14,0468"
"0,4403","13,9776"
"0,8362","13,9591"
"1,2323","13,8877"

Open the .csv file in a text editor, and do "replaces". The generated format is according to my region, so I'll indicate the sequence I used.

First: <","> to <%>

Then <,> was replaced by <.>

replace <%> with <,>

then <" newline "> by

<*\yScale) (\xScale*>

Hit the first and last lines so that it becomes something like:

(\xScale*0.0836,14.0468*\yScale) (\xScale*0.4403,13.9776*\yScale) ...

Then use in the tikz file as indicated.

\documentclass[margin=1cm]{standalone}
\usepackage{tikz}

\begin{document} \begin{tikzpicture} \def\xScale{-0.4} \def\yScale{0.4}

\draw[thick,-latex] (0,0) -- (10\xScale-0.5,0) node[below] {x}; \draw[thick,-latex] (0,0) -- (0,14\yScale+0.5) node[right] {y};

\draw[very thick,red] plot[smooth, tension=.7] coordinates {(\xScale0.0836,14.0468\yScale) (\xScale0.4403,13.9776\yScale) (\xScale0.8362,13.9591\yScale) (\xScale1.2323,13.8877\yScale) (\xScale1.6283,13.7987\yScale) (\xScale2.0245,13.6921\yScale) (\xScale2.4042,13.5503\yScale) (\xScale2.8004,13.426\yScale) (\xScale3.1637,13.249\yScale) (\xScale3.527,13.0544\yScale) (\xScale3.8409,12.8423\yScale) (\xScale4.1129,12.6365\yScale) (\xScale4.3991,12.4528\yScale) (\xScale4.7687,12.1745\yScale) (\xScale5.1628,11.888\yScale) (\xScale5.4769,11.623\yScale) (\xScale5.8074,11.358\yScale) (\xScale6.1214,11.1283\yScale) (\xScale6.3532,10.7755\yScale) (\xScale6.6676,10.3696\yScale) (\xScale6.9323,10.0167\yScale) (\xScale7.1806,9.6814\yScale) (\xScale7.3837,9.3664\yScale) (\xScale7.5818,9.0886\yScale) (\xScale7.7768,8.6936\yScale) (\xScale7.9757,8.3056\yScale) (\xScale8.191,7.9352\yScale) (\xScale8.4063,7.5648\yScale) (\xScale8.5888,7.1416\yScale) (\xScale8.7547,6.7361\yScale) (\xScale8.9042,6.3306\yScale) (\xScale9.0371,5.9251\yScale) (\xScale9.1701,5.5021\yScale) (\xScale9.3031,5.0966\yScale) (\xScale9.4031,4.656\yScale) (\xScale9.5196,4.233\yScale) (\xScale9.6196,3.81\yScale) (\xScale9.7031,3.3871\yScale) (\xScale9.7701,2.9466\yScale) (\xScale9.8207,2.5237\yScale) (\xScale9.8547,2.0833\yScale) (\xScale9.9053,1.6428\yScale) (\xScale9.9393,1.2023\yScale) (\xScale9.9607,0.805\yScale) (\xScale9.9619,0.7034\yScale) (\xScale9.9729,0.0615\yScale)}; \draw[very thick,blue] plot[smooth, tension=.7] coordinates {(\xScale0.0353,10.9665\yScale) (\xScale0.3983,10.8952\yScale) (\xScale0.7943,10.859\yScale) (\xScale1.1903,10.7877\yScale) (\xScale1.5865,10.681\yScale) (\xScale1.9662,10.5392\yScale) (\xScale2.3459,10.3798\yScale) (\xScale2.7093,10.2028\yScale) (\xScale3.0397,9.973\yScale) (\xScale3.3867,9.7432\yScale) (\xScale3.7172,9.4782\yScale) (\xScale4.0312,9.2133\yScale) (\xScale4.3288,8.9307\yScale) (\xScale4.6264,8.6482\yScale) (\xScale4.8912,8.2953\yScale) (\xScale5.1393,7.9952\yScale) (\xScale5.3876,7.6424\yScale) (\xScale5.6772,7.2806\yScale) (\xScale5.9667,6.9188\yScale) (\xScale6.1486,6.7246\yScale) (\xScale6.3639,6.363\yScale) (\xScale6.4966,6.0721\yScale) (\xScale6.6296,5.649\yScale) (\xScale6.7296,5.226\yScale) (\xScale6.8541,4.891\yScale) (\xScale6.9046,4.4594\yScale) (\xScale7.0294,4.0099\yScale) (\xScale7.1459,3.5869\yScale) (\xScale7.2459,3.1639\yScale) (\xScale7.3295,2.7233\yScale) (\xScale7.3965,2.3004\yScale) (\xScale7.4635,1.8599\yScale) (\xScale7.4976,1.4195\yScale) (\xScale7.5317,0.979\yScale) (\xScale7.5491,0.5915\yScale) (\xScale7.5917,0.0365\yScale)}; \end{tikzpicture} \end{document}

enter image description here

\begin{tikzpicture}
\def\xScale{-0.4}
\def\yScale{0.4}
\pgfmathsetmacro\raioA{((6.9035*\xScale)^2+(4.6452*\yScale)^2)^0.5}
\pgfmathsetmacro\angA{atan(4.6452/6.9035)}
\pgfmathsetmacro\angB{atan(10.6743/6.455)}
\pgfmathsetmacro\angC{atan((4.6452-12.1668)/(6.9035-4.7364))}

\draw[thick,-latex] (0,0) -- (10\xScale-0.5,0); \draw[thick,-latex] (0,0) -- (0,14\yScale+0.5); \draw (0,0) --(6.455\xScale,10.6743\yScale); \draw (0,0) --(6.9035\xScale,4.6452\yScale); \draw (6.455\xScale,10.6743\yScale) --(6.9035\xScale,4.6452\yScale); \draw (6.9035\xScale,4.6452\yScale) -- (4.7\xScale,12.4\yScale); \draw (0,0) --(6.9035\xScale,4.6452\yScale); \draw (0,0) ++(180-\angA:\raioA) arc(180-\angA:90:\raioA); \draw (6.9035\xScale,4.6452\yScale) ++(-\angA:1.1) arc (-\angA:-0.5\angC:1.1) coordinate (maa) arc (-0.5\angC:-\angC:1.1); \node[right] at (maa) {\tiny$El+90$}; \draw (0,0) ++(180-\angB:0.8) arc (180-\angB:180-\angA:0.8) ; \node[rotate = 90-0.5\angA-0.5\angB , above] at (180-0.5\angB-0.5\angA :0.8) {$\theta'$}; \draw[thick] (0,0) ++(180-\angB:1.5) arc (180-\angB:180:1.5) ; \node[rotate = 90-0.5\angB , above] at (180-0.5\angB+5 :1.5) {$\theta$}; \node[right] at (\xScale0.0836,14.0468\yScale) {Orbital}; \node[right] at (\xScale0.0353,10.9665\yScale) {Earth radius}; \draw[blue, very thick] (\xScale0.0353,10.9665\yScale) arc (90:180:-\xScale7.5917 and 10.9665\yScale); \draw[red, very thick] (\xScale0.0836,14.0468\yScale) arc (90:180:-\xScale9.9729 and 14.0468\yScale); \end{tikzpicture}

enter image description here

NCrown
  • 353