# Draw the proper angle arc

I am trying to draw an arc to indicate angle between y axis and r line, but I don't seem to achive it. My code is

\documentclass[11pt,a4paper]{book}
\usepackage{kerkis}
%\usepackage{kmath}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amsfonts}
\usepackage{amsthm}
\usepackage{color}
%\usepackage[usenames,dvipsnames]{color}
\definecolor{Darkgreen}{rgb}{0,0.4,0}
\definecolor{Darkblue}{rgb}{0,0,0.4}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw[gray,->] (-5,0) -- (5,0);
\draw[gray,->] (0,-5) -- (0,5);
\draw[gray,dashed] (-5,4) -- (5,4);
\node at (5,0.2) {$x$};
\node at (-0.2,5) {$y$};

\fill (0,0) circle (2pt) node[below] (e) {$m,e$};
\fill (-3,4) circle (2pt) node[above] (ion) {$ze$};

\draw[red] (0,0) -- (-3,4);
\draw[gray,->] (4,1.75) -- (4,0);
\draw[gray,->] (4,2.25) -- (4,4);
\node at (4,2) {$b$};
\draw[blue,->] (-3,4) -- (-1.5,4);
\node[blue] at (-1.8,4.2) {$V$};
\node[red] at (-2.7,3) {$r$};

\draw[Darkgreen,->] (0,0) -- (-1.5,2);
\draw[Darkgreen,->] (0,0) -- (0,2);
\draw[Darkgreen,->] (0,0) -- (-1.5,0);
\draw[Darkgreen,very thin,dashed] (0,2) -- (-1.5,2);
\draw[Darkgreen,very thin,dashed] (-1.5,0) -- (-1.5,2);

\node[Darkgreen] at (0.3,2) {$F_y$};
\node[Darkgreen] at (-1.5,-0.3) {$F_x$};
\node[Darkgreen,left] at (-1.7,2) {$F=\dfrac{kze^2}{r^2}$};
%\draw[Darkgreen] (0.5,0.5) arc (80:123:0.8cm);
\draw[Darkgreen] (1cm,0cm) arc (90:125:1cm);

\end{tikzpicture}
\end{document}


My output is Any ideas on that? • Perhaps you mean \draw[Darkgreen] (0cm,1cm) arc (90:125:1cm);? Looks like you have the x and y coordinates reversed. – Brent.Longborough Nov 1 '12 at 21:03
• @Brent.Longborough: Yep that seems like an answer to me. Could also include \pgfmathsetmacro{\EndAngle}{90+atan2(4,3)} to compute the end angle as opposed to guess its value. – Peter Grill Nov 1 '12 at 21:10
• Look at Tikz: joining points on a circle and my answer. – Paul Gaborit Nov 2 '12 at 17:35

First, you don't have to load color as tikz already loads xcolor. You have to put the things in this order though:

\usepackage{tikz}
\definecolor{Darkgreen}{rgb}{0,0.4,0}
\definecolor{Darkblue}{rgb}{0,0,0.4}


Having said that, why to manually calculate the angles? Use clip. First draw a triangle (well almost a triangle)

\path[clip] (0,2) -- (0,0) -- (-3,4);


and then a circle:

\node[circle,draw=Darkgreen,minimum size=40pt] at (0,0) (circ) {};


Code:

\documentclass[11pt,a4paper]{book}
\usepackage{kerkis}
%\usepackage{kmath}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amsfonts}
\usepackage{amsthm}
%\usepackage{color}
%\usepackage[usenames,dvipsnames]{color}
\usepackage{tikz}
\definecolor{Darkgreen}{rgb}{0,0.4,0}
\definecolor{Darkblue}{rgb}{0,0,0.4}

\begin{document}
\begin{tikzpicture}
\draw[gray,->] (-5,0) -- (5,0);
\draw[gray,->] (0,-5) -- (0,5);
\draw[gray,dashed] (-5,4) -- (5,4);
\node at (5,0.2) {$x$};
\node at (-0.2,5) {$y$};

\fill (0,0) circle (2pt) node[below] (e) {$m,e$};
\fill (-3,4) circle (2pt) node[above] (ion) {$ze$};

\draw[red] (0,0) -- (-3,4);
\draw[gray,->] (4,1.75) -- (4,0);
\draw[gray,->] (4,2.25) -- (4,4);
\node at (4,2) {$b$};
\draw[blue,->] (-3,4) -- (-1.5,4);
\node[blue] at (-1.8,4.2) {$V$};
\node[red] at (-2.7,3) {$r$};

\draw[Darkgreen,->] (0,0) -- (-1.5,2);
\draw[Darkgreen,->] (0,0) -- (0,2);
\draw[Darkgreen,->] (0,0) -- (-1.5,0);
\draw[Darkgreen,very thin,dashed] (0,2) -- (-1.5,2);
\draw[Darkgreen,very thin,dashed] (-1.5,0) -- (-1.5,2);

\node[color=Darkgreen] at (0.3,2) {$F_y$};
\node[Darkgreen] at (-1.5,-0.3) {$F_x$};
\node[Darkgreen,left] at (-1.7,2) {$F=\dfrac{kze^2}{r^2}$};
%% First clip
\path[clip] (0,2) -- (0,0) -- (-3,4) -- cycle;
%%The circle
\node[circle,draw=Darkgreen,minimum size=40pt] at (0,0) (circ) {};
%
%\draw[Darkgreen] (0.5,0.5) arc (80:123:0.8cm);
\draw[Darkgreen] (1cm,0cm) arc (90:125:1cm);

\end{tikzpicture}
\end{document} First coordinate determine star of arc. exchange line

\draw[Darkgreen] (1cm,0cm) arc (90:125:1cm);


with

\draw[Darkgreen] (0,1) arc (90:125:1cm);


and your (not MWE) example should draw arc in desired place (if I catch where the arc should be).

• Thank you very much for your answer! Reversing coordinates really works! But I can't understand why! The syntax is \draw (P) arc (a:b:r) (each variable can be seen on my edited answer). My idea was to put P on the x axis, (1,0) that is... – Thanos Nov 2 '12 at 19:03
{"ft_lang_label":"__label__en","ft_lang_prob":0.66955805,"math_prob":0.99136335,"size":1719,"snap":"2020-10-2020-16","text_gpt3_token_len":758,"char_repetition_ratio":0.18717201,"word_repetition_ratio":0.0,"special_character_ratio":0.46771377,"punctuation_ratio":0.27752292,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.9989097,"pos_list":[0,1,2,3,4,5,6],"im_url_duplicate_count":[null,3,null,3,null,3,null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2020-02-21T01:19:06Z\",\"WARC-Record-ID\":\"<urn:uuid:1c39dcbb-4a8e-4689-8306-323009edd986>\",\"Content-Length\":\"150258\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:9eb52214-0e95-49ea-a917-2f92596826d4>\",\"WARC-Concurrent-To\":\"<urn:uuid:4cb23c4b-928b-4660-b5fa-606f5e751f54>\",\"WARC-IP-Address\":\"151.101.193.69\",\"WARC-Target-URI\":\"https://tex.stackexchange.com/questions/80033/draw-the-proper-angle-arc\",\"WARC-Payload-Digest\":\"sha1:QCIPMIDTJXSVZJTHBH4M5RWKHXWMXNGG\",\"WARC-Block-Digest\":\"sha1:JZJH5PKIAWF2NPTME37PLYJJC6APSQK4\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2020/CC-MAIN-2020-10/CC-MAIN-2020-10_segments_1581875145316.8_warc_CC-MAIN-20200220224059-20200221014059-00095.warc.gz\"}"}