このような複雑な図形をどうやって描くのでしょうか?

このような複雑な図形をどうやって描くのでしょうか?

このような複雑な図を LaTeX で描くにはどうすればよいでしょうか? ソースを教えていただけますか? ここに画像の説明を入力してください

答え1

これが図です。点にラベルを付けていません。後でそれについて触れるかもしれません。しかし、それ以外はすべて難しい物事は完了しました。

\documentclass[border=10pt]{standalone}
\usepackage{tikz}
\begin{document}

\begin{tikzpicture}

  \coordinate (Q) at (0,0);

  %% we start drawing from the inside and work our way out      
  %% There are two parameters to control                        
  %% the number of major arcs drawn                             
  %% the length of the initial segment                          
  %% from Q to A1 (which is the inner most point here)          
  \def\maxMajorArcCount{4}
  \def\initialLength{1in}
  \foreach \myn in {1,2,...,\maxMajorArcCount}
  {
    %% set lengths for each iternation            
    %% the use of `\xdef` is to help remember     
    %% the length of `\majorRadius` to draw the   
    %% final major arc.                           
    \pgfmathparse{\initialLength*sqrt(3)^(\myn-1)}
    \xdef\majorRadius{\pgfmathresult pt}%%
    \pgfmathparse{\majorRadius*sqrt(3)/3}
    \xdef\minorRadius{\pgfmathresult pt}%%

    \coordinate (A\myn) at (\majorRadius,0);

    %% fill the region with gray
    \ifnum\myn<\maxMajorArcCount\relax
      \draw[fill=gray,opacity=.60]
          (A\myn) arc (0:60:\majorRadius)
                  --  ++(0:\majorRadius);
    \fi

    %% draw the major Radius
    \draw (A\myn) arc (0:60:\majorRadius);

    %% draw the triangle and circumscribing circle.
    \ifnum\myn<\maxMajorArcCount\relax
      \draw (A\myn) -- ++ (60:\majorRadius)
                    -- ++ (180:\majorRadius)
                    -- cycle;
      \draw (A\myn) arc (-90:270:\minorRadius);
    \fi
  }

  %% draw outside angle
  \draw (Q) -- ++ (0:\majorRadius);
  \draw (Q) -- ++ (60:\majorRadius);

\end{tikzpicture}

\end{document}

ここに画像の説明を入力してください

答え2

そして、これがキャンペーンの取り組みですメタポスト...

ここに画像の説明を入力してください

prologues := 3;
outputtemplate := "%j%c.eps";
beginfig(1);
pair A[], B[], C[];
A0 = 200 right; 
for i=1 upto 4:
    B[i-1] = A[i-1] rotated 60;
    C[i]   = A[i-1] rotated 30;
    ypart B[i] = ypart C[i]; 
    B[i] = whatever[origin,B0];
endfor
draw origin -- A0 .. C1 .. B0 -- cycle;
for i=1 upto 3: 
  fill A[i]--C[i]--B[i]..C[i+1]..cycle withcolor .8[blue,white];
  draw A[i]--C[i]--B[i]..C[i+1]..cycle;
endfor
for i=1 upto 3: 
  draw A[i]--B[i];
  draw A[i]..B[i]..C[i]..cycle;
endfor 
label.bot(btex $A$ etex, A0);
label.bot(btex $A_1$ etex, A1);
label.bot(btex $A_2$ etex, A2);
label.lft(btex $B$ etex, B0);
label.lft(btex $B_1$ etex, B1);
label.lft(btex $B_2$ etex, B2);
label.rt(btex $C_1$ etex, C1);
label.rt(btex $C_2$ etex, C2);
label.llft(btex $O$ etex, origin);
label(btex $\ldots$ etex rotated 30, 12 right rotated 30);
endfig;
end

関連情報