旋转导致顶点周围出现间隙?

旋转导致顶点周围出现间隙?

上一个问题用户 mickep 很好地解决了这个问题,但我发现rotate导致许多节点周围出现间隙。节点和线没有紧密对齐。

\documentclass[12pt]{article}
\usepackage{graphicx,booktabs,multirow}
\usepackage{tikz}
\usepackage{rotating}
\begin{document}
\begin{figure}[htbp]
\centering

\begin{tikzpicture}[scale=0.06,rotate=-135]
    \definecolor{marked}{rgb}{0.1,0,0.1}
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (29) 
    at 
    (42.567181,41.152087) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (28) 
    at 
    (27.572899,41.538022) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (27) 
    at 
    (34.919955,48.656375) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (26) 
    at 
    (43.524872,58.905088) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (25) 
    at 
    (50.014294,49.957119) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (24) 
    at 
    (50.586049,30.803317) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (23) 
    at 
    (38.607777,28.902230) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (22) 
    at 
    (14.923386,46.981133) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (21) 
    at 
    (23.883934,56.703831) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (20) 
    at 
    (33.919382,62.335620) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (19) 
    at 
    (49.428245,69.168096) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (18) 
    at 
    (57.432819,58.805032) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (17) 
    at 
    (56.518011,41.037736) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (16) 
    at 
    (57.132647,22.355633) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (15) 
    at 
    (45.452831,12.880504) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (14) 
    at 
    (0.000000,50.000000) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (13) 
    at 
    (27.787308,71.898228) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (12) 
    at 
    (42.924529,75.687249) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (11) 
    at 
    (61.406518,71.054888) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (10) 
    at 
    (65.122928,51.400801) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (9) at 
    (66.137793,37.750144) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (8) at 
    (72.269869,28.201830) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (7) at 
    (50.000000,0.000000) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (6) at 
    (50.000000,99.999999) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (5) at 
    (57.647227,84.048028) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (4) at 
    (72.427100,58.533448) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (3) at 
    (76.173242,45.410520) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (2) at 
    (99.999999,50.000000) {};
    \node [circle,draw,fill=marked,minimum size=0.18 cm,inner sep=1.5pt] (1) at 
    (84.005146,58.190395) {};
    \draw [black, line width=0.5mm] (29) to (23);
    \draw [black, line width=0.5mm] (29) to (27);
    \draw [black, line width=0.5mm] (29) to (25);
    \draw [black, line width=0.5mm] (29) to (24);
    \draw [black, line width=0.5mm] (28) to (21);
    \draw [black, line width=0.5mm] (28) to (27);
    \draw [black, line width=0.5mm] (28) to (23);
    \draw [black, line width=0.5mm] (28) to (22);
    \draw [black, line width=0.5mm] (27) to (20);
    \draw [black, line width=0.5mm] (27) to (26);
    \draw [black, line width=0.5mm] (26) to (19);
    \draw [black, line width=0.5mm] (26) to (25);
    \draw [black, line width=0.5mm] (26) to (20);
    \draw [black, line width=0.5mm] (25) to (17);
    \draw [black, line width=0.5mm] (25) to (18);
    \draw [black, line width=0.5mm] (24) to (16);
    \draw [black, line width=0.5mm] (24) to (23);
    \draw [black, line width=0.5mm] (24) to (17);
    \draw [black, line width=0.5mm] (23) to (15);
    \draw [black, line width=0.5mm] (22) to (14);
    \draw [black, line width=0.5mm] (22) to (21);
    \draw [black, line width=0.5mm] (22) to (15);
    \draw [black, line width=0.5mm] (21) to (13);
    \draw [black, line width=0.5mm] (21) to (20);
    \draw [black, line width=0.5mm] (20) to (12);
    \draw [black, line width=0.5mm] (19) to (11);
    \draw [black, line width=0.5mm] (19) to (18);
    \draw [black, line width=0.5mm] (19) to (12);
    \draw [black, line width=0.5mm] (18) to (10);
    \draw [black, line width=0.5mm] (18) to (11);
    \draw [black, line width=0.5mm] (17) to (9);
    \draw [black, line width=0.5mm] (17) to (10);
    \draw [black, line width=0.5mm] (16) to (8);
    \draw [black, line width=0.5mm] (16) to (15);
    \draw [black, line width=0.5mm] (16) to (9);
    \draw [black, line width=0.5mm] (15) to (7);
    \draw [black, line width=0.5mm] (14) to (6);
    \draw [black, line width=0.5mm] (14) to (13);
    \draw [black, line width=0.5mm] (14) to (7);
    \draw [black, line width=0.5mm] (13) to (6);
    \draw [black, line width=0.5mm] (13) to (12);
    \draw [black, line width=0.5mm] (12) to (5);
    \draw [black, line width=0.5mm] (11) to (4);
    \draw [black, line width=0.5mm] (11) to (5);
    \draw [black, line width=0.5mm] (10) to (4);
    \draw [black, line width=0.5mm] (10) to (9);
    \draw [black, line width=0.5mm] (9) to (3);
    \draw [black, line width=0.5mm] (8) to (2);
    \draw [black, line width=0.5mm] (8) to (7);
    \draw [black, line width=0.5mm] (8) to (3);
    \draw [black, line width=0.5mm] (7) to (2);
    \draw [black, line width=0.5mm] (6) to (2);
    \draw [black, line width=0.5mm] (6) to (5);
    \draw [black, line width=0.5mm] (5) to (1);
    \draw [black, line width=0.5mm] (4) to (1);
    \draw [black, line width=0.5mm] (4) to (3);
    \draw [black, line width=0.5mm] (3) to (1);
    \draw [black, line width=0.5mm] (2) to (1);
    \draw [black, line width=0.5mm] (3) to (1);
    \draw [black, line width=0.5mm] (2) to (1);
     \draw [blue, line width=0.25mm] (5) to (13); \draw [blue, line 
     width=0.25mm] (6) to (12);
     \draw [blue, line width=0.25mm] (1) to (6); \draw [blue, line 
     width=0.25mm] (2) to (5);
     \draw [blue, line width=0.25mm] (4) to (5); \draw [blue, line 
     width=0.25mm] (1) to (11);
     \draw [blue, line width=0.25mm] (5) to (19);  \draw [blue, line 
     width=0.25mm] (11) to (12);
     \draw [blue, line width=0.25mm] (12) to (26);  \draw [blue, line 
     width=0.25mm] (19) to (20);
     \draw [blue, line width=0.25mm] (12) to (21);  \draw [blue, line 
     width=0.25mm] (13) to (20);
     \draw [blue, line width=0.25mm] (13) to (22);  \draw [blue, line 
     width=0.25mm] (14) to (21);
     \draw [blue, line width=0.25mm] (21) to (27);  \draw [blue, line 
     width=0.25mm] (20) to (28);
     \draw [blue, line width=0.25mm] (27) to (23);  \draw [blue, line 
     width=0.25mm] (28) to (29);
     \draw [blue, line width=0.25mm] (28) to (15);  \draw [blue, line 
     width=0.25mm] (22) to (23);
     \draw [blue, line width=0.25mm] (22) to (7);  \draw [blue, line 
     width=0.25mm] (15) to (14);
     \draw [blue, line width=0.25mm] (27) to (25);  \draw [blue, line 
     width=0.25mm] (26) to (29);
     \draw [blue, line width=0.25mm] (26) to (18);  \draw [blue, line 
     width=0.25mm] (19) to (25);
     \draw [blue, line width=0.25mm] (17) to (18);  \draw [blue, line 
     width=0.25mm] (10) to (25);
     \draw [blue, line width=0.25mm] (4) to (18);  \draw [blue, line 
     width=0.25mm] (10) to (11);
     \draw [blue, line width=0.25mm] (9) to (4);  \draw [blue, line 
     width=0.25mm] (3) to (10);
     \draw [blue, line width=0.25mm] (17) to (29);  \draw [blue, line 
     width=0.25mm] (24) to (25);
     \draw [blue, line width=0.25mm] (24) to (15);  \draw [blue, line 
     width=0.25mm] (23) to (16);
     \draw [blue, line width=0.25mm] (24) to (9);  \draw [blue, line 
     width=0.25mm] (16) to (17);
     \draw [blue, line width=0.25mm] (8) to (9);  \draw [blue, line 
     width=0.25mm] (3) to (16);
     \draw [blue, line width=0.25mm] (16) to (7);  \draw [blue, line 
     width=0.25mm] (8) to (15);
     \draw [blue, line width=0.25mm] (1) to (8);  \draw [blue, line 
     width=0.25mm] (3) to (2);
        \draw[blue] (7) .. controls (-30,50) .. 
        (6);
    \draw[blue] (14) .. controls (50,-30) .. 
            (2);
\end{tikzpicture}
\caption{$G$}
\end{figure}
\end{document}

在此处输入图片描述

在旋转之前不存在这种现象(我们删除了rotate=-135)。

在此处输入图片描述

答案1

缩放和旋转之间似乎存在一些冲突。

由于您不使用画布坐标系统我建议只是缩放和旋转坐标坐标系通过设置

x=(-135:.6mm), y=(90-135:.6mm)

我也应用了我的评论曲线及其边界框通过加载bbox库并bezier bounding box在最后两条路径上使用。

代码

\documentclass[tikz]{standalone}
\usetikzlibrary{bbox}
\begin{document}
\begin{tikzpicture}[x=(-135:.6mm), y=(90-135:.6mm)]
\definecolor{marked}{rgb}{0.1,0,0.1}
\node foreach[count=\i] \p in {(84.005146,58.190395), (99.999999,50.000000),
        (76.173242,45.410520), (72.427100,58.533448), (57.647227,84.048028),
        (50.000000,99.999999), (50.000000, 0.000000), (72.269869,28.201830),
        (66.137793,37.750144), (65.122928,51.400801), (61.406518,71.054888),
        (42.924529,75.687249), (27.787308,71.898228), ( 0.000000,50.000000),
        (45.452831,12.880504), (57.132647,22.355633), (56.518011,41.037736),
        (57.432819,58.805032), (49.428245,69.168096), (33.919382,62.335620),
        (23.883934,56.703831), (14.923386,46.981133), (38.607777,28.902230),
        (50.586049,30.803317), (50.014294,49.957119), (43.524872,58.905088),
        (34.919955,48.656375), (27.572899,41.538022), (42.567181,41.152087)}[
  circle, draw, fill=marked, minimum size=.18cm, inner sep=1.5pt] (\i) at \p {};
\draw [black, line width=0.5mm] (29) to (23); \draw [black, line width=0.5mm] (29) to (27);
\draw [black, line width=0.5mm] (29) to (25); \draw [black, line width=0.5mm] (29) to (24);
\draw [black, line width=0.5mm] (28) to (21); \draw [black, line width=0.5mm] (28) to (27);
\draw [black, line width=0.5mm] (28) to (23); \draw [black, line width=0.5mm] (28) to (22);
\draw [black, line width=0.5mm] (27) to (20); \draw [black, line width=0.5mm] (27) to (26);
\draw [black, line width=0.5mm] (26) to (19); \draw [black, line width=0.5mm] (26) to (25);
\draw [black, line width=0.5mm] (26) to (20); \draw [black, line width=0.5mm] (25) to (17);
\draw [black, line width=0.5mm] (25) to (18); \draw [black, line width=0.5mm] (24) to (16);
\draw [black, line width=0.5mm] (24) to (23); \draw [black, line width=0.5mm] (24) to (17);
\draw [black, line width=0.5mm] (23) to (15); \draw [black, line width=0.5mm] (22) to (14);
\draw [black, line width=0.5mm] (22) to (21); \draw [black, line width=0.5mm] (22) to (15);
\draw [black, line width=0.5mm] (21) to (13); \draw [black, line width=0.5mm] (21) to (20);
\draw [black, line width=0.5mm] (20) to (12); \draw [black, line width=0.5mm] (19) to (11);
\draw [black, line width=0.5mm] (19) to (18); \draw [black, line width=0.5mm] (19) to (12);
\draw [black, line width=0.5mm] (18) to (10); \draw [black, line width=0.5mm] (18) to (11);
\draw [black, line width=0.5mm] (17) to  (9); \draw [black, line width=0.5mm] (17) to (10);
\draw [black, line width=0.5mm] (16) to  (8); \draw [black, line width=0.5mm] (16) to (15);
\draw [black, line width=0.5mm] (16) to  (9); \draw [black, line width=0.5mm] (15) to  (7);
\draw [black, line width=0.5mm] (14) to  (6); \draw [black, line width=0.5mm] (14) to (13);
\draw [black, line width=0.5mm] (14) to  (7); \draw [black, line width=0.5mm] (13) to  (6);
\draw [black, line width=0.5mm] (13) to (12); \draw [black, line width=0.5mm] (12) to  (5);
\draw [black, line width=0.5mm] (11) to  (4); \draw [black, line width=0.5mm] (11) to  (5);
\draw [black, line width=0.5mm] (10) to  (4); \draw [black, line width=0.5mm] (10) to  (9);
\draw [black, line width=0.5mm]  (9) to  (3); \draw [black, line width=0.5mm]  (8) to  (2);
\draw [black, line width=0.5mm]  (8) to  (7); \draw [black, line width=0.5mm]  (8) to  (3);
\draw [black, line width=0.5mm]  (7) to  (2); \draw [black, line width=0.5mm]  (6) to  (2);
\draw [black, line width=0.5mm]  (6) to  (5); \draw [black, line width=0.5mm]  (5) to  (1);
\draw [black, line width=0.5mm]  (4) to  (1); \draw [black, line width=0.5mm]  (4) to  (3);
\draw [black, line width=0.5mm]  (3) to  (1); \draw [black, line width=0.5mm]  (2) to  (1);
\draw [black, line width=0.5mm]  (3) to  (1); \draw [black, line width=0.5mm]  (2) to  (1);
\draw [blue, line width=0.25mm]  (5) to (13); \draw [blue, line width=0.25mm]  (6) to (12);
\draw [blue, line width=0.25mm]  (1) to  (6); \draw [blue, line width=0.25mm]  (2) to  (5);
\draw [blue, line width=0.25mm]  (4) to  (5); \draw [blue, line width=0.25mm]  (1) to (11);
\draw [blue, line width=0.25mm]  (5) to (19); \draw [blue, line width=0.25mm] (11) to (12);
\draw [blue, line width=0.25mm] (12) to (26); \draw [blue, line width=0.25mm] (19) to (20);
\draw [blue, line width=0.25mm] (12) to (21); \draw [blue, line width=0.25mm] (13) to (20);
\draw [blue, line width=0.25mm] (13) to (22); \draw [blue, line width=0.25mm] (14) to (21);
\draw [blue, line width=0.25mm] (21) to (27); \draw [blue, line width=0.25mm] (20) to (28);
\draw [blue, line width=0.25mm] (27) to (23); \draw [blue, line width=0.25mm] (28) to (29);
\draw [blue, line width=0.25mm] (28) to (15); \draw [blue, line width=0.25mm] (22) to (23);
\draw [blue, line width=0.25mm] (22) to  (7); \draw [blue, line width=0.25mm] (15) to (14);
\draw [blue, line width=0.25mm] (27) to (25); \draw [blue, line width=0.25mm] (26) to (29);
\draw [blue, line width=0.25mm] (26) to (18); \draw [blue, line width=0.25mm] (19) to (25);
\draw [blue, line width=0.25mm] (17) to (18); \draw [blue, line width=0.25mm] (10) to (25);
\draw [blue, line width=0.25mm]  (4) to (18); \draw [blue, line width=0.25mm] (10) to (11);
\draw [blue, line width=0.25mm]  (9) to  (4); \draw [blue, line width=0.25mm]  (3) to (10);
\draw [blue, line width=0.25mm] (17) to (29); \draw [blue, line width=0.25mm] (24) to (25);
\draw [blue, line width=0.25mm] (24) to (15); \draw [blue, line width=0.25mm] (23) to (16);
\draw [blue, line width=0.25mm] (24) to  (9); \draw [blue, line width=0.25mm] (16) to (17);
\draw [blue, line width=0.25mm]  (8) to  (9); \draw [blue, line width=0.25mm]  (3) to (16);
\draw [blue, line width=0.25mm] (16) to  (7); \draw [blue, line width=0.25mm]  (8) to (15);
\draw [blue, line width=0.25mm]  (1) to  (8); \draw [blue, line width=0.25mm]  (3) to  (2);
\draw [blue, bezier bounding box]  (7) .. controls (-30,  50) .. (6);
\draw [blue, bezier bounding box] (14) .. controls ( 50, -30) .. (2);
\end{tikzpicture}
\end{document}

输出

在此处输入图片描述

相关内容