2

I have the code provided below. The code produces the following picture:

enter image description here

I want to rotate \ddots, which are showed in red circle, but can not figure out how to do this.

CODE:

\documentclass{standalone}

\usepackage{tikz}
\usetikzlibrary{math,calc,trees,positioning,arrows,fit,shapes}
\usetikzlibrary{patterns}


\begin{document}
\begin{tikzpicture}
\tikzmath{\x =1.8; \y =2.4; \d=1;}

\coordinate[label={[below,yshift=-.1cm]$x$}] (Origin)   at (0,0) circle (.5ex);

\coordinate [label={[below,xshift=0.1cm]$l_1$}](Lone) at ({\x*cos(0)},{\x*sin(0)});
\coordinate [](Lonelong) at ({\y*cos(0)},{\y*sin(0)});

\coordinate [label={[right]$l_2$}](Ltwo) at ({\x*cos(60)},{\x*sin(60)});
\coordinate [](Ltwolong) at ({\y*cos(60)},{\y*sin(60)});

\coordinate [label={[left]$l_3$}](Lthree) at ({\x*cos(120)},{\x*sin(120)});
\coordinate [](Lthreelong) at ({\y*cos(120)},{\y*sin(120)});



\coordinate [label={[above]$l_i$}](Li) at ({\x*cos(180)},{\x*sin(180)});
\coordinate [](Lilong) at ({\y*cos(180)},{\y*sin(180)});

\coordinate [label={[below,xshift=0.3cm, yshift=0cm]$l_{i+1}$}](Liplusone) at ({\x*cos(240)},{\x*sin(240)});
\coordinate [](Liplusonelong) at ({\y*cos(240)},{\y*sin(240)});

\coordinate [label={[below]$l_n$}] (Ln) at ({\x*cos(300)},{\x*sin(300)});
\coordinate [] (Lnlong) at ({\y*cos(300)},{\y*sin(300)});

\coordinate [label={[above,xshift=.2cm,yshift=-.25cm ]$O_n$}](On) at ({\x*cos(330)},{\x*sin(330)});
\coordinate [label={[below,xshift=-.1cm, yshift=.3cm]$O_i$}](Oi) at ({\x*cos(210)},{\x*sin(210)});
\coordinate [label={[below,xshift=.0cm, yshift=.3cm]$O_2$}](O2) at ({\x*cos(90)},{\x*sin(90)});
\coordinate [label={[below,xshift=.1cm, yshift=.3cm]$O_1$}](O1) at ({\x*cos(30)},{\x*sin(30)});


\coordinate [label={[below,yshift=.4cm]\reflectbox{$\ddots$}}](Dots2) at ({\d*cos(150)},{\d*sin(150)});
\coordinate [label={[below,yshift=.1cm]$\dots$}](Dots3) at ({\d*cos(270)},{\d*sin(270)}); % dots



\draw[dotted,pattern=north west lines,opacity=0.5, pattern color=blue](Origin)--(Lone)--(Ln) -- cycle;

\draw[dotted,pattern=north west lines,opacity=0.5, pattern color=blue](Origin)--(Ltwo)--(Lone) -- cycle;


\draw[dotted,pattern=north west lines,opacity=0.5, pattern color=blue](Origin) -- (Ltwo) -- (Lthree) -- cycle;

\draw[dotted,pattern=north west lines,opacity=0.5, pattern color=blue](Origin) -- (Li) -- (Liplusone) -- cycle;

\draw[-](Origin)--(Lone);
\draw[dashed](Lone)--(Lonelong);

\draw[-](Origin)--(Ltwo);
\draw[dashed](Ltwo)--(Ltwolong);

\draw[-](Origin)--(Lthree);
\draw[dashed](Lthree)--(Lthreelong);



\draw[-](Origin)--(Li);
\draw[dashed](Li)--(Lilong);

\draw[-](Origin)--(Ln);
\draw[dashed](Ln)--(Lnlong);

\draw[-](Origin)--(Liplusone);
\draw[dashed](Liplusone)--(Liplusonelong);

\draw[black,fill=black] (0,0) circle (.5ex);



\end{tikzpicture}

\end{document} 
  • 1
    You can use rotate, e.g. \coordinate [label={[below,yshift=.1cm,rotate=60]$\dots$}](Dots2) at ({\d*cos(150)},{\d*sin(150)});. – Schrödinger's cat Oct 16 at 13:07
  • If you write it as an answer I will accept it. Thank you a lot. – Evgeny Kuznetsov Oct 16 at 13:12
  • It means that in a moment of anver @Schrödinger's cat was alive :D – Evgeny Kuznetsov Oct 16 at 13:17
3

Repeating the comment: you can use the rotate key,

\coordinate [label={[below,yshift=.1cm,rotate=60]$\dots$}](Dots2) at ({\d*cos(150)},{\d*sin(150)});

However, I would like to suggest using loops and other simplifications.

\documentclass[tikz]{standalone}
\usetikzlibrary{patterns}
\begin{document}
\begin{tikzpicture}
 \path[pattern=north west lines,opacity=0.5, pattern color=blue]
  (0,0) coordinate (O) -- (-60:2) -- (0:2) -- (60:2) -- (120:2) 
  -- (O) -- (-120:2) -- (-180:2) -- cycle;
 \node[circle,fill,inner sep=2pt,label=below:$x$] at (O){};
 \foreach \X in {1,2,3}
 {\draw (60*\X-60+180:2) -- (60*\X-60:2) node[anchor={60*\X+180\ifnum\X<3
 -120\fi}]{$\ell_\X$};
 \draw[dashed] (60*\X-60:2) -- ++(60*\X-60:0.5)
 (60*\X-60+180:2) -- ++(60*\X-60+180:0.5);}
 \foreach \X [count=\Y] in {\ell_i,\ell_{i+1},\ell_n}
 {\path (\Y*60+120:2)  node[anchor={-60*\Y\ifnum\Y=2 +120\fi}]{$\X$};}
 \path foreach \X [count=\Y] in {O_1,O_2,{},O_i,{},O_n}
  {(-30+60*\Y:2.2) node{$\X$}};
 \path foreach \X in {150,270}  {(\X:1.7) node[rotate=\X-90]{$\dots$}};
\end{tikzpicture}
\end{document}

enter image description here

Note that this can be optimized further, and the different loops outside and inside paths are on purpose to illustrate different options.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.