# [Tex/LaTex] Contour integrals

tikz-pgf

I checked this post in here Drawing complex integration but what I want is draw the one that exclude zero and negative real numbers instead of positives. I tried to play around with the code in the link above and I couldn't figure it out. I'm a beginner with the drawings in Latex

The quickest solution in this case is to do a reflection using xscale=-1 in the answer to the question linked:

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{calc,decorations.markings}
\begin{document}

\begin{tikzpicture}[xscale=-1]
% Configurable parameters
\def\gap{0.2}

% Axes
% Red path
\draw[red, thick,   decoration={ markings,
mark=at position 0.17 with {\arrow{latex}},
mark=at position 0.53 with {\arrow{latex}},
mark=at position 0.755 with {\arrow{latex}},
mark=at position 0.955 with {\arrow{latex}}},
postaction={decorate}]
let
-- cycle;
\end{tikzpicture}
\end{document}


If you don't want to use a reflection, simply redraw the path using the appropriate points for the arcs and the straight line segments:

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{calc,decorations.markings}
\begin{document}

\begin{tikzpicture}
% Configurable parameters
\def\gap{0.2}

% Axes
% Red path
\draw[red, thick,   decoration={ markings,
mark=at position 0.17 with {\arrow{latex}},
mark=at position 0.53 with {\arrow{latex}},
mark=at position 0.755 with {\arrow{latex}},
mark=at position 0.955 with {\arrow{latex}}},
postaction={decorate}]
let