我想将以下代码更改为使用 Venndiagrams,这样我就可以更轻松地为单元格着色,并在自然部分添加示例,例如 1、2、3。或者有更好的方法吗?
\documentclass[tikz,border=3.14mm]{book}
\usepackage{tikz}
\usepackage{amsfonts}
\usepackage{amssymb}
\begin{document}
\begin{tikzpicture}[font=\sffamily, scale=0.8]
\foreach \X [count=\Y starting from 2] in {Natural $\mathbb{N}$ ,Whole numbers $\mathbb{Z}$ ,Rational $\mathbb{Q}$, Real algebraic $\mathbb{A}$, Real $\mathbb{R}$}
{\draw (-\Y,-\Y/2) circle ({1.5*\Y} and \Y);
\node at (1-2*\Y,-1.1*\Y) {\X}; }
\draw ([xshift=-0.5cm,yshift=-0.5cm]current bounding box.south west)
rectangle ([xshift=0.5cm,yshift=0.5cm]current bounding box.north east);
\node[anchor=south] at (current bounding box.north) {Types of numbers};
\end{tikzpicture}
\end{document}
任何提示或指导都会令人惊奇,我的解决方案太混乱了,很愚蠢。