Winkel berechnen

Winkel berechnen

Noch einmal, es gibt eine Zahl, die mir nicht ganz klar zu sein scheint. Dies ist die gewünschte Ausgabe:

Bildbeschreibung hier eingeben

Das ist, was ich bisher bekomme:

Bildbeschreibung hier eingeben

Und dies ist ein MWE, das das generiert, was ich erhalte:

\documentclass[dvipsnames]{standalone}
\usepackage{tikz}
\usetikzlibrary{fit, calc, matrix, positioning, arrows.meta, intersections, through, backgrounds, patterns}

\begin{document}
\begin{tikzpicture}[node distance = 0pt, every pin/.style = {pin distance=11mm, pin edge={stealth-}}, every node/.style = {color=Blue!60!black}, dot/.style = {circle, fill=black, inner sep=0mm, minimum size=2mm, node contents={}}, line/.style = {-stealth, shorten >=1mm, shorten <= 1mm},]
\coordinate (s) at (3,3);
\coordinate (O) at (0,0);
\coordinate (P) at (-0.5,0.5);
\coordinate[right=55mm of O] (X);
\coordinate[above=55mm of O] (Y);
\coordinate[above right=1 and 2 of O] (d);
\coordinate[right=2 of X |- Y] (e);
\coordinate (a) at (10,10);
\draw[-latex] ([xshift=-0.1] O) -- (X) node[right] {$h_1$};
\draw[-latex] ([yshift=-0.1] O) -- (Y) node[above] {$h_2$};
\path[name path=S] (O) -- (45:6);
\coordinate[left =of s -| O] (s1);
\coordinate[below=of s |- O] (s2);
\draw[Blue,thick] let \p1 = ($(s)-(O)$), \n1 = {veclen(\x1,\y1)} in ($(O)+(\n1,0)$) arc(0:90:\n1);
\draw[Blue,thick] let \p1 = ($(s)-(P)$), \n1 = {veclen(\x1,\y1)} in ($(P)+(\n1,0)$) arc(0:83.5:\n1);
\node[dot,at=(s),pin=60:{$f(T,d)=f(S,d)$}];
\node[below] at (1,1) {$d$};
\node[below] at (1,4) {$S$};
\draw[fill] (1,1) circle (2pt);
\path[name path=D] (s2) -- (15:8);
\end{tikzpicture}
\end{document}

Kann mir bitte jemand helfen, das gewünschte Ergebnis zu erzielen? Ich fürchte, ich übersehe etwas ziemlich Dummes, aber ich weiß nicht, was es ist. Vielen Dank im Voraus für Ihre Zeit.

Antwort1

Sie beginnen die arc0,5 oberhalb der x-Achse, da ihr Startpunkt bei ist (P)+(\n1,0)und Pbei (-0,5,0,5) liegt. Sie können die Kurve von diesem Punkt aus zusätzlich gegen den Uhrzeigersinn zeichnen, um sie bis zur Achse zu verlängern, d. h.

\draw[Blue,thick] let
  \p1 = ($(s)-(P)$),
  \n1 = {veclen(\x1,\y1)}
in
  ($(P)+(\n1,0)$) arc(0:83.4:\n1)
  ($(P)+(\n1,0)$) arc(0:-6.6:\n1);

Aber eine vielleicht einfachere Möglichkeit, dasselbe zu tun, besteht darin, zwei Kreise mit Hilfe der throughBibliothek auszuschneiden, d. h.

\begin{scope}
\clip (X) rectangle (Y);
\node [draw,thick,circle,Blue,circle through=(s)] at (O) {};
\node [draw,thick,circle,Blue,circle through=(s)] at (P) {};
\end{scope}

Vollständiger Code, bei dem ich einige nicht verwendete Elemente entfernt und ein wenig aufgeräumt habe:

Bildbeschreibung hier eingeben

\documentclass[dvipsnames]{standalone}
\usepackage{tikz}
\usetikzlibrary{calc, positioning, arrows.meta, through}

\begin{document}
\begin{tikzpicture}[
  node distance = 0pt,
  every pin/.style = {pin distance=11mm, pin edge={Stealth-}},
  every node/.style = {color=Blue!60!black},
  dot/.style = {circle, fill=black, inner sep=0mm, minimum size=2mm, node contents={}},
]
\coordinate (s) at (3,3);
\coordinate (O) at (0,0);
\coordinate (P) at (-0.5,0.5);
\coordinate[right=55mm of O] (X);
\coordinate[above=55mm of O] (Y);

\draw[Latex-Latex] (Y) node[above] {$h_2$} -- (O) -- (X) node[right] {$h_1$};

%alternative 1
%\begin{scope}
%\clip (X) rectangle (Y);
%\node [draw,thick,circle,Blue,circle through=(s)] at (O) {};
%\node [draw,thick,circle,Blue,circle through=(s)] at (P) {};
%\end{scope}

% alternative 2
\draw[Blue,thick] let
  \p1 = ($(s)-(O)$),
  \n1 = {veclen(\x1,\y1)}
in
 ($(O)+(\n1,0)$) arc(0:90:\n1);
\draw[Blue,thick] let
  \p1 = ($(s)-(P)$),
  \n1 = {veclen(\x1,\y1)}
in
  ($(P)+(\n1,0)$) arc(0:83.4:\n1)
  ($(P)+(\n1,0)$) arc(0:-6.6:\n1);
% end alternative 2
%%%%%%%


\node[dot,at=(s),pin=60:{$f(T,d)=f(S,d)$}];
\node[dot,at={(1,1)},label=below:{$d$}];
\node[below] at (1,4) {$S$};

\end{tikzpicture}
\end{document}

Winkel berechnen

Um zu vermeiden, dass Sie die Winkel in Ihrem Code durch Ausprobieren finden müssen, können Sie sie berechnen, siehe Beispiel unten.

\documentclass[dvipsnames,border=5mm]{standalone}
\usepackage{tikz}
\usetikzlibrary{calc, positioning, arrows.meta, through,intersections}

\begin{document}
\begin{tikzpicture}[
  node distance = 0pt,
  every pin/.style = {pin distance=11mm, pin edge={Stealth-}},
  every node/.style = {color=Blue!60!black},
  dot/.style = {circle, fill=black, inner sep=0mm, minimum size=2mm, node contents={}},
]
\coordinate (s) at (3,3);
\coordinate (O) at (0,0);
\coordinate (P) at (-0.5,0.5);
\coordinate[right=55mm of O] (X);
\coordinate[above=55mm of O] (Y);

% note name path=axis
\draw[Latex-Latex,name path=axis] (Y) node[above] {$h_2$} -- (O) -- (X) node[right] {$h_1$};

\draw[Blue,thick] let
  \p1 = ($(s)-(O)$),
  \n1 = {veclen(\x1,\y1)}
in
 ($(O)+(\n1,0)$) arc[start angle=0,end angle=90,radius=\n1];


% define circle around P through s
\path[overlay,name path=circle] let
  \p1 = ($(s)-(P)$),
  \n1 = {veclen(\x1,\y1)}
in
(P) circle[radius=\n1];
% calculate angles between P and intersection points with circle and axis lines
\draw[Red,thick,name intersections={of=axis and circle,name=i}] let
  \p1 = ($(i-1)-(P)$),
  \p2 = ($(i-2)-(P)$),
  \n1 = {veclen(\x1,\y1)},
  \n2 = {atan2(\y1,\x1)},
  \n3 = {atan2(\y2,\x2)}
in
  (i-1) arc[radius=\n1,start angle=\n2,end angle=\n3];


\node[dot,at=(s),pin=60:{$f(T,d)=f(S,d)$}];
\node[dot,at={(1,1)},label=below:{$d$}];
\node[below] at (1,4) {$S$};

\end{tikzpicture}
\end{document}

Antwort2

Um uns nicht mit Berechnungen herumschlagen zu müssen, zeichnen wir einen vollständigen Kreis und clipden Teil, der uns interessiert (oberes rechtes Viertel).

Bildbeschreibung hier eingeben

\documentclass[dvipsnames]{standalone}
\usepackage{tikz}
\usetikzlibrary{fit, calc, matrix, positioning, arrows.meta, intersections, through, backgrounds, patterns}

\begin{document}
\begin{tikzpicture}[node distance = 0pt, every pin/.style = {pin distance=11mm, pin edge={stealth-}}, every node/.style = {color=Blue!60!black}, dot/.style = {circle, fill=black, inner sep=0mm, minimum size=2mm, node contents={}}, line/.style = {-stealth, shorten >=1mm, shorten <= 1mm},]
  \coordinate (s) at (3,3);
  \coordinate (O) at (0,0);
  \coordinate (P) at (-0.5,0.5);
  \coordinate[right=55mm of O] (X);
  \coordinate[above=55mm of O] (Y);
  \coordinate[above right=1 and 2 of O] (d);
  \coordinate[right=2 of X |- Y] (e);
  \coordinate (a) at (10,10);
  \draw[-latex] ([xshift=-0.1] O) -- (X) node[right] {$h_1$};
  \draw[-latex] ([yshift=-0.1] O) -- (Y) node[above] {$h_2$};
  \path[name path=S] (O) -- (45:6);
  \coordinate[left =of s -| O] (s1);
  \coordinate[below=of s |- O] (s2);
  \draw[Blue,thick] let \p1 = ($(s)-(O)$), \n1 = {veclen(\x1,\y1)} in ($(O)+(\n1,0)$) arc(0:90:\n1);
  \begin{scope}
    \clip (X) rectangle (Y);
    \draw[Blue,thick] let \p1 = ($(s)-(P)$), \n1 = {veclen(\x1,\y1)} in ($(P)+(\n1,0)$) arc(0:360:\n1);
  \end{scope}
  \node[dot,at=(s),pin=60:{$f(T,d)=f(S,d)$}];
  \node[below] at (1,1) {$d$};
  \node[below] at (1,4) {$S$};
  \draw[fill] (1,1) circle (2pt);
  \path[name path=D] (s2) -- (15:8);
\end{tikzpicture}
\end{document}

Antwort3

Noch eine mögliche Lösung (basierend auf den Erfahrungen mit Ihren vorherigen ähnlichen Fragen):

\documentclass[tikz,dvipsnames,margin=3mm]{standalone}
\usetikzlibrary{arrows.meta, backgrounds, calc, fit, intersections, 
                matrix, positioning, 
                through, patterns}

    \begin{document}
\begin{tikzpicture}[node distance = 10mm and 20mm, 
 every pin/.style = {pin distance=11mm, pin edge={stealth-}}, 
every node/.style = {color=Blue!60!black}, 
       dot/.style = {circle, fill=black, inner sep=0mm, minimum size=2mm, node contents={}},
      line/.style = {-stealth, shorten >=1mm, shorten <= 1mm}
                    ]
\coordinate (O) at (0,0);
\coordinate[above right=of O] (d);
% axis
\draw[-latex] (-0.1,0) -- (6.5,0) node[right] {$h_1$};
\draw[-latex] (0,-0.1) -- (0,5.5) node[above] {$h_2$};
% arc
\draw[Blue,thick,name path=A]       (4.0,0) arc(0:90:4);
\draw[TealBlue,thick,name path=B]   (4.5,0) arc(0:90:5 and 3.5);
% intersection, dashed S line
\draw[densely dashed, name intersections={of=A and B, by={s}}]
    (s -| O) -| ( s|- O) node[pos=0.25,above] {$S$};
\node[dot,at=(s), pin=above right:{$f(T,d)=f(S,d)$}];
% d point
\node[dot,at=(d), label=below:$d$];
    \end{tikzpicture}
\end{document}

Bildbeschreibung hier eingeben

Nachtrag:Falls Sund TNamen von Arcus sind, zeigt das folgende MWE, wie das geht:

\documentclass[tikz,dvipsnames,margin=3mm]{standalone}
\usetikzlibrary{arrows.meta, backgrounds, calc, fit, intersections, 
                matrix, positioning, 
                through, patterns}

    \begin{document}
\begin{tikzpicture}[node distance = 10mm and 20mm, 
 every pin/.style = {pin distance=11mm, pin edge={stealth-}}, 
every node/.style = {color=Blue!60!black}, 
       dot/.style = {circle, fill=black, inner sep=0mm, minimum size=2mm, node contents={}},
      line/.style = {-stealth, shorten >=1mm, shorten <= 1mm}
                    ]
\coordinate (O) at (0,0);
\coordinate[above right=of O] (d);
% axis
\draw[-latex] (-0.1,0) -- (6.5,0) node[right] {$h_1$};
\draw[-latex] (0,-0.1) -- (0,5.5) node[above] {$h_2$};
% arc
\draw[Blue,thick,name path=A]       (4.0,0) arc(0:90:4) node[above right] {$S$};
\draw[TealBlue,thick,name path=B]   (4.5,0) arc(0:90:4.5 and 3.5) node[above right] {$T$};
% intersection, dashed S line
\coordinate[densely dashed, name intersections={of=A and B, by={s}}];
\node[dot,at=(s), pin=75:{$f(T,d)=f(S,d)$}];
% d point
\node[dot,at=(d), label=below:$d$];
    \end{tikzpicture}
\end{document}

Bildbeschreibung hier eingeben

verwandte Informationen