0

I'd like some help creating some simple lattices, say to represent 3 or 4 sets and inclusion relations. I've searched, but only found very detailed results, which do interest me but I don't have the time to go that far into the matter. This may sound strange but the fact is I don't actually write latex documents at this point in my career, I just need a primitive grasp of latex to interact on Math SE.

If someone could respond with a lattice representing $C,B\subset A$, and $C,B$ not comparable with each other, it'd probably be the best way for me to learn the basics for what I need as I'd be able to look up the commands myself and go from there. Thanks.

Edit: I'm not really sure how to show my "attempt". I've basically gone through a bunch of TeX SE questions and LaTeX documentation, but I'm quite unable to discern what will even work on Math SE, and the ensuing discussions are above my level of comprehension. The best help would just be an example like I've said above.

8
  • If someone could also add the appropriate tags too that'd be fantastic as I have no idea.
    – GPerez
    Commented Dec 21, 2014 at 21:31
  • 2
    Hi and welcome to TeX.SX. In its current form, your question might not receive many answers. Please take a look at the How to Ask-page and try to improve your question according to the guidance found there. This may require you to show some effort on your part in terms of attempting a solution. If you have questions about what to do or if you don't quite understand what this means, please ask for clarification using the add comment function. Commented Dec 21, 2014 at 21:36
  • @MartinSchröder Thank you for the formatting, I've edited to answer your comment. Is the work shown the issue though? Or is it just not clear what I'm asking?
    – GPerez
    Commented Dec 21, 2014 at 21:48
  • If I've understood correctly, this question is off-topic because it is about maths mark-up on Maths SE. (I can't remember what this is called - Math Jax?) @MartinSchröder is asking your for a minimal working example (MWE). (Almost) all questions here need an MWE - at least to include the basic document framework i.e. \documentclass... \begin{document}... \end{document}. But I don't think it is relevant here because I don't think you are trying to create this with TeX or friends...
    – cfr
    Commented Dec 21, 2014 at 23:48
  • 1
    @cfr That makes sense, it probably is off-topic. I've accepted and saved a .txt of the answer anyway because it will probably be useful in the case I need to write an actual document.
    – GPerez
    Commented Dec 22, 2014 at 0:36

1 Answer 1

2

Here is an example of what can be done with pstricks , and more specifically with the psmatrix environment from pst-node. The basic idea is quite simple: putting the elements of the lattice as elements of a matrix which are nodes, then connect these nodes with invisible lines. The inclusion relations are labels placed in the middle of these lines:

\documentclass[a4paper,11pt, pdf]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}%
\usepackage{lmodern, amssymb}
\usepackage{mathtools}
\usepackage{graphicx}
\usepackage{pst-node}


\newpsobject{ncemptyline}{ncline}{linestyle=none}
\newcommand*\ncsubset[2]{\ncemptyline{#1}{#2}\ncput[nrot=:U]{ \subset}}
\newcommand*\ncsubsetneq[2]{\ncemptyline{#1}{#2}\ncput[nrot=:U]{\varsubsetneq}}
\newcommand*\ncvarsubsetneq[2]{\ncemptyline{#1}{#2}\ncput[nrot=:U]{\scalebox{1}[-1]{$ \varsubsetneq $}}}

\pagestyle{empty}

\begin{document}
\psset{npos = 0.45}
\[ \begin{psmatrix}[rowsep = 0.3, colsep = 0.4]
 & [name = C] C \\
[name = B] B & & [name = D] D \\
 & [name = A] A \\
   \ncvarsubsetneq{A}{B}\ncsubsetneq{A}{D}

\ncsubset{B}{C}\ncsubset{D}{C}
\end{psmatrix} \]

\end{document} 

enter image description here

4
  • Will this work as mark-up on Math SE?
    – cfr
    Commented Dec 22, 2014 at 0:29
  • @cfr: What's mark up on Math SE? I never really used Math SE.
    – Bernard
    Commented Dec 22, 2014 at 0:44
  • That's what the OP actually wants the code for. It is off-topic, I think. Doesn't Math SE use Math Jax or something? (I forget what it is called.)
    – cfr
    Commented Dec 22, 2014 at 0:48
  • 1
    @cfr It is called Math Jax, yes.
    – GPerez
    Commented Dec 22, 2014 at 1:00

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