Hass 图中两个相交的阴影区域

Hass 图中两个相交的阴影区域

我可以为我的半群绘制 Hass 图,但我无法制作附件中所示的两个阴影区域。有人能帮我解决这个问题吗?

我的尝试

   \tikzset{
mynode/.style={draw,circle,inner sep=1.5pt,outer sep=1.5pt,fill=white}
}
     \begin{figure}[ht]
    \centering
   {\scalefont{0.7}

    \begin{tikzpicture}

    \node [mynode] (u) at (0,0) {};
    \node [mynode,below left  = of u,label=above:$\scriptsize{J}$] (e)  {};
    \node [mynode,below right = of u] (f) {};
    \node [mynode,below right = of e] (d) {};
    \node [mynode,above right = of u] (r) {};
    \node [mynode,above left = of e] (m) {};
    \node [mynode,above right = of m] (s) {};
    \node [mynode,above right = of s] (w) {};
    \node [mynode,above right = of f] (k) {};

    \draw (u) -- (e) 
        (u) -- (f) 
        (e) -- (d) 
        (f) -- (d)
        (r) -- (u)
        (m) -- (e)
        (m) -- (s)
        (w) -- (s)
        (w) -- (r)
        (k) -- (f)
        (r) -- (k)
        (s) -- (u);

    \end{tikzpicture}}
    \caption{Generic picture of $\mathscr{J}$-classes of a finite regular monoid $S.$}
    \label{fig:Jclasses for reg mnonid}
     \end{figure} 

在此处输入图片描述

答案1

这是一项建议。请注意,您可以大大简化您的绘图,至少如果您不需要这些精确的节点名称的话。还请注意,如果边界框对于您的目的来说太大,则可以轻松修复。

\documentclass[tikz,border=3.14pt]{standalone}
\usetikzlibrary{positioning,backgrounds}
\begin{document}
\tikzset{
mynode/.style={draw,circle,inner sep=1.5pt,outer sep=1.5pt,fill=white}
}
\begin{tikzpicture}

    \node [mynode,label={[font=\scriptsize]right:$J$}] (u) at (0,0) {};
    \node [mynode,below left  = of u] (e)  {};
    \node [mynode,below right = of u] (f) {};
    \node [mynode,below right = of e] (d) {};
    \node [mynode,above right = of u] (r) {};
    \node [mynode,above left = of e] (m) {};
    \node [mynode,above right = of m] (s) {};
    \node [mynode,above right = of s] (w) {};
    \node [mynode,above right = of f] (k) {};

    \draw (u) -- (e) 
        (u) -- (f) 
        (e) -- (d) 
        (f) -- (d)
        (r) -- (u)
        (m) -- (e)
        (m) -- (s)
        (w) -- (s)
        (w) -- (r)
        (k) -- (f)
        (r) -- (k)
        (s) -- (u);
    \begin{scope}[on background layer]
    \draw[fill=blue,opacity=0.2] ([yshift=5pt]m.north) to[out=0,in=180] ([yshift=-5pt]u)
    to[out=0,in=180] ([yshift=5pt]k.north) to[out=0,in=0] 
    coordinate[pos=0.2] (aux2)  ([yshift=-15pt]d)
    to[out=180,in=180] cycle;
    \path (u) -- (d) coordinate[midway] (aux);
    \draw[ultra thick,green!60!black,
    fill=yellow,fill opacity=0.2] (aux) circle (1.5);
    \draw[-latex] (aux2) to ++ (1,0)
    node[right,font=\scriptsize]{$J'$};
    \coordinate (aux3) at (-135:1.5);
    \draw[-latex] (aux3) to[bend left] ++ (-1.5,-0.5)
    node[left,font=\scriptsize]{$J''$};
    \end{scope}
\end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容