3

I would like to reproduce the following picture, using Tikz: enter image description here

I can do everything except for the two hyperbolic paths. Any help is appreciated.

I have part of the picture, and here is my code:

\begin{figure}[h]
\centering
\begin{tikzpicture}
    \draw (0,0) circle (2.5);
    \draw (0,0) -- ({2.5*cos(45)},{2.5*sin(45)});
    \draw (0,0) -- (2.5,0);
    \draw ({2.5*cos(45)},-{2.5*sin(45)}) -- (-{2.5*cos(45)},{2.5*sin(45)});
    \draw (0.5,0) arc (0:45:0.5);
    \node[below left] at (0,0) {$O$};
    \node[above left] at (-{2.5*cos(45)},{2.5*sin(45)}) {$D$};
    \node[above right] at ({2.5*cos(45)},{2.5*sin(45)}) {$B$};
    \node[below right] at ({2.5*cos(45)},-{2.5*sin(45)}) {$C$};
    \node[right] at (2.5,0) {$\theta=0$};
    \node[below left] at ({1.25*cos(45)},-{1.25*sin(45)}) {$r^0=\frac{\omega}{c}$};
    \node[right] at ({0.5*cos(22.5)},{0.5*sin(45)}) {$\theta_B$};
\end{tikzpicture}
\end{figure}
  • Depending on how accurate you need it, something like \draw (C) to[bend left] (B); might be sufficient. – Torbjørn T. Nov 03 '16 at 19:14
  • It would be nice if the line segment CB is orthogonal to the straight line at $A$. – B. Pasternak Nov 03 '16 at 19:15
  • 2
    It would be helpful to show us what you have tried. Posting a minimal working example that indicates what you are trying to do makes it easier for people to understand what you want. It also makes it easier for people to help you, since they have some code to start from, and much more likely that some one will try to help you. –  Nov 03 '16 at 19:30
  • Fair point, I always do that, but it seemed of not much help here, since the rest of the picture is easy. But I will do it! – B. Pasternak Nov 03 '16 at 19:34
  • Are the answers to http://tex.stackexchange.com/q/16617/86 any use to you? – Andrew Stacey Nov 03 '16 at 19:47
  • In the picture the inner arcs DB and BC are NOT hyperbolic, as they touch the potential asymptote. Actually, they like as arcs of the circle, symmetric to their outer versions. – Przemysław Scherwentke Nov 03 '16 at 20:05
  • @PrzemysławScherwentke That's precisely what hyperbolic paths are in the Poincaré disc model of hyperbolic space. Paths DB and BC should be circular arcs which intersect the outer circle orthogonally. – Andrew Stacey Nov 03 '16 at 20:20

2 Answers2

5

Ehm, turned into a complete rewrite of the code. Anyway, you can still pick out the few bits needed for the missing pieces. I saw Przemysław Scherwentke's comment, so those missing lines are drawn as circle segments.

Parameterized the drawing a bit, and added some comments.

enter image description here

\documentclass[tikz, border=3mm]{standalone}
\usetikzlibrary{calc,intersections,quotes,angles}
\begin{document}
\begin{tikzpicture}
% set up a few macros
\newcommand\circlerad{2.5cm}
\pgfmathsetmacro\Bangle{45}
\pgfmathsetmacro\Dangle{\Bangle-90}
\pgfmathsetmacro\Cangle{\Bangle+90}

% draw circle
\node [circle,draw,minimum size=2*\circlerad,name path=circ] (A) {};

% draw line to B and add named coordinate with label
\draw (A.center) coordinate[label=below left:$O$] (O)
   -- (A.\Bangle) coordinate[label=above right:$B$] (b);

% ditto for horizontal line from origin
\draw [name path=h1] (O) -- (A.0) coordinate[label=right:{$\theta=0$}] (e);

% draw line from D to C, add labels and r^0 node
\draw (A.\Dangle) coordinate[label=below right:$D$] (d) 
       -- (A.\Cangle) coordinate[label=above left:$C$] (c)
          node[below left,pos=0.25] {$r^0=\frac{\omega}{c}$};

% draw angle arc
\pic ["$\theta_B$",angle eccentricity=1.7,draw] {angle=e--O--b};

% draw hyperbolic arcs
\draw [name path=hypish] (d) arc[start angle=\Dangle-90,delta angle=-90,radius=\circlerad];
\draw (c) arc[start angle=\Cangle+90,delta angle=90,radius=\circlerad];

%find intersection of hyperbole and horizontal line, name coordinate i-1, and draw invisible
% verticle line from this point upwards
\path [name intersections={of=hypish and h1,name=i},overlay,name path=dashing] (i-1) -- ++(0,2*\circlerad);

% find intersection of invisible path and circle, draw line from to A
\draw [densely dashed,name intersections={of=dashing and circ,name=j}] (i-1) -- (j-1);

% label A
\node [below right,font=\footnotesize] at (i-1) {$A:(r_0,0)$};
\end{tikzpicture}
\end{document}
Torbjørn T.
  • 206,688
2

For comparison in Metapost, wrapped up in luamplib. Compile with lualatex.

enter image description here

\RequirePackage{luatex85}
\documentclass[border=5mm]{standalone}
\usepackage{luamplib}
\begin{document}
\mplibtextextlabel{enable}
\begin{mplibcode}
beginfig(1);
path c, r[], h[];
pair A,B,C,D;

c = fullcircle scaled 160;

t = 45*8/360; % the diagram should work for values other than 45°
B = point t of c;
C = point t-2 of c;
D = point t+2 of c;

r0 = origin -- point 0 of c;
r1 = origin -- B;
r2 = origin -- C;
r3 = origin -- D;

h1 = B{-B} .. C{C};
h2 = B{-B} .. D{D};

A = r0 intersectionpoint h1;

draw r0; draw r1; draw r2; draw r3;
draw h1; draw h2;

draw c withcolor .67 blue;
draw fullcircle scaled 16 cutafter r1 withcolor .67 blue;

draw A -- A shifted 1000 up cutafter c 
     dashed evenly scaled 2/3 
     withcolor .53 red;

label.llft("$O$", origin);
label.rt("$\vartheta=0$", point 0 of c);
label("$\vartheta_B$", 16 right rotated 20);
label.lrt("$A:(r_0,0)$", A);
label.llft("$r^0=c/\omega$", 1/2 C);

label("$B$", 1.08 B);
label("$D$", 1.08 D);
label("$C$", 1.08 C);

endfig;
\end{mplibcode}
\end{document}

Note: In several places, the MP code depends on the circle being centred at the origin.

Thruston
  • 42,268