0

I've managed to include both of the Venn Diagrams that I needed, but now I can't add a "X" letter inside the "B" set, while maintaining its label of "B"

This is what I need to do:

And this is what I've managed to do:

enter image description here

And this is the coding:

\begin{venndiagram2sets}[labelNotAB={A c B}]
\fillANotB
\end{venndiagram2sets}

1 Answer 1

3

If you give us a full Minimum Working Exampleenter image description here
then we can test what may go wrong, however using your code labelling B as X works for me.

\documentclass{article}
\usepackage{venndiagram}
\begin{document}
\begin{venndiagram2sets}[labelNotAB={A c B},labelOnlyB={X}]
\fillANotB
\end{venndiagram2sets}
\end{document}

A comment was made that perhaps contrary to your statement the desired answer is more elaborate, with A & B outside so in order to get this.

enter image description here

We need more elaborate positioning code for A B and possibly X, see if you can spot the differences, adjust and compile to suit with this code

\documentclass{article}
\usepackage{venndiagram}
\begin{document}
    \begin{venndiagram2sets}[labelNotAB={A c B},labelA={},labelB={},shade=gray]
    \fillOnlyA
    \draw (0.7,3.14) node {A};
    \draw (4.3,3.14) node {B};
    \draw (3.7,1.65) node {X};
\end{venndiagram2sets}
\end{document}
3
  • That was what I was trying, but look the the OPs scan, A and B are outside.
    – daleif
    May 8, 2019 at 15:58
  • My comment on the original post applies here, too, i.e. you do not need calc here (and personally I feel you could acknowledge the corresponding answer if you copy parts of it).
    – user121799
    May 8, 2019 at 23:03
  • @marmot your comment on that post did not work for me since compilation failed without calc for let however you made me revise the code to drop all such dependencies on others and use my own co-ordinate skills to improve the emulation of do it for me
    – user170109
    May 8, 2019 at 23:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .