Quantcast
Channel: Adding arrows to a complex contour with Tikz - TeX - LaTeX Stack Exchange
Viewing all articles
Browse latest Browse all 3

Answer by Salim Bou for Adding arrows to a complex contour with Tikz

$
0
0

First figure

\documentclass[border=10pt,tikz,multi]{standalone}\usetikzlibrary{decorations.markings}\begin{document}\begin{tikzpicture}  [line width=.8pt,    decoration={%      markings,      mark=at position 0.25 with {\arrow[line width=1pt]{>}},      mark=at position 0.5 with {\arrow[line width=1pt]{>}},          mark=at position 0.75 with {\arrow[line width=1pt]{>}}        }  ]  \draw [help lines,->] (-4,0) -- (4,0) coordinate (xaxis);  \draw [help lines,->] (0,-1)coordinate(-yaxis) -- (0,4) coordinate (yaxis);  \node  at (1.5,0) {$\times$};  \node  at (-1.5,0) {$\times$};  \draw [postaction=decorate] (3,0) arc (0:180:3) ;  \draw [postaction=decorate] (-3,0) --(-2,0) arc  (180:0:.5) --(1,0) arc  (180:0:.5)--(3,0) ;  \node [below] at (xaxis) {$Re(z)$};  \node [above] at (yaxis) {$Im(z)$};  \node [below left] {$O$};  \node at (-1.5,.8) {$\gamma_{1}$};  \node at (1.5,.8) {$\gamma_{2}$};  \node at (2,3) {$\Gamma_{1}$};  \node at (3,-.5){$R$};  \node at (-3,-.5){$-R$};  \node at (1.5,-.5){$1$};  \node at (-1.5,-.5){$-1$};\end{tikzpicture}\end{document}

for the second figure just add yscale=-1 to tikzpicture environment and replace \node [above] at (yaxis) {$Im(z)$}; with \node [above] at (-yaxis) {$Im(z)$};

\documentclass[border=10pt,tikz,multi]{standalone}\usetikzlibrary{decorations.markings}\begin{document}\begin{tikzpicture}  [yscale=-1,line width=.8pt,    decoration={%      markings,      mark=at position 0.25 with {\arrow[line width=1pt]{>}},      mark=at position 0.5 with {\arrow[line width=1pt]{>}},          mark=at position 0.75 with {\arrow[line width=1pt]{>}}        }  ]  \draw [help lines,->] (-4,0) -- (4,0) coordinate (xaxis);  \draw [help lines,->] (0,-1)coordinate(-yaxis) -- (0,4) coordinate (yaxis);  \node  at (1.5,0) {$\times$};  \node  at (-1.5,0) {$\times$};  \draw [postaction=decorate] (3,0) arc (0:180:3) ;  \draw [postaction=decorate] (-3,0) --(-2,0) arc  (180:0:.5) --(1,0) arc  (180:0:.5)--(3,0) ;  \node [below] at (xaxis) {$Re(z)$};  \node [above] at (-yaxis) {$Im(z)$};  \node [below left] {$O$};  \node at (-1.5,.8) {$\gamma_{1}$};  \node at (1.5,.8) {$\gamma_{2}$};  \node at (2,3) {$\Gamma_{2}$};  \node at (3,-.5){$R$};  \node at (-3,-.5){$-R$};  \node at (1.5,-.5){$1$};  \node at (-1.5,-.5){$-1$};\end{tikzpicture}\end{document} 

Viewing all articles
Browse latest Browse all 3

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>