# Plotting an elliptical arc in TikZ with minimal additional packages and as simple as possible functions

I have the above output from Mathematica that I would like to reproduce exactly in LaTeX, but I am just beginning with TikZ and do not understand the huge layers of code that are presented in other questions with similarly shaped elliptical arcs.

For that reason, I am not particularly interested in advanced packages, but if there is a package that allows me to do it using just the polar equation I will accept it as a solution.

I tried polar plotting but TikZ just breaks arbitrarily when I put in the polar form of the curve and for some reason ignores the square root.

• Hi Jack, please help us to help you: if you put the code that didn't work for you in a form a M(N)WE we can try to see what happens. See minimal working example (MWE) Oct 8, 2018 at 12:07
• @Rmano I tried the following line: \draw [thick,color=black,domain=1:89,samples=200,smooth] plot (xy polar cs:angle=\x,radius= {sqrt(1-0.9800139176438553*cos(\x)*cos(\x))}); But it just renders a rotated semicircle (The angles are not the ones I am after this was just the initial test run) Oct 8, 2018 at 12:17

## 1 Answer

\documentclass[tikz]{standalone}

\begin{document}
\begin{tikzpicture}
% 7/90*180=14
% -1/7*180=-25.71428571
% 6/7*180=154.2857143
\draw
[thick,color=black,domain=-25.71428571:154.2857143,samples=200,smooth]
plot (xy polar cs:angle=\x,
radius=
{1/sqrt(1-0.9800139176438553*cos(\x-14)*cos(\x-14))});
\end{tikzpicture}
\end{document}


TikZ's cos and sin use degrees per default.

• how can I shift the curve along the x and y axes? I need it to align with something else that already exists. Oct 8, 2018 at 14:09
• \draw[...,xshift=1cm, yshift=-1cm]
– user4686
Oct 8, 2018 at 14:48