1: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2: % %
3: % This is file `fca.sty' : LaTeX macros for Formal Concept Analysis %
4: % %
5: % Copyright Bernhard Ganter 5/03 %
6: % Version of 3/05 %
7: % %
8: % This program is provided under the terms of the %
9: % LaTeX Project Public License distributed from CTAN %
10: % archives in directory macros/latex/base/lppl.txt. %
11: % %
12: % This package contains two environments, called cxt and diagram, %
13: % for typesetting formal contexts and order diagrams, %
14: % and a few short macros for frequently used symbols in FCA. %
15: % %
16: % Short descriptions are given below. A recent version of this file %
17: % should be available at www.math.tu-dresden.de/~ganter %
18: % %
19: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
20: % %
21: \NeedsTeXFormat{LaTeX2e}% %
22: \ProvidesPackage{fca}[2004/03/10 v1.3 Formal Concept Analysis macros]% %
23: \RequirePackage{amssymb,epic,ifthen,rotating,xspace}% %
24: % PDF things %
25: \newboolean{pdf} %
26: % \newif\ifpdf %
27: \ifx\pdfoutput\undefined %
28: \pdffalse % no pdfLaTeX %
29: \setboolean{pdf}{false} %
30: \else %
31: \pdfoutput=1 % pdfLaTeX available %
32: \pdftrue %
33: \setboolean{pdf}{true} %
34: \fi %
35: % %
36: \ifthenelse{\boolean{pdf}}{\RequirePackage{eepicemu}}{\RequirePackage{eepic}} %
37: % %
38: % %
39: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
40: % %
41: % environment cxt for making small cross-tables for Formal Concept Analysis %
42: % %
43: % The environment is useful for typesetting cross-tables %
44: % of small formal contexts ( max. 20 attributes ). %
45: % %
46: % To typeset a formal context with attributes 1., 2., disqualified %
47: % and objects Schumacher, Barichello, Montoya, try %
48: % %
49: % \begin{cxt}% %
50: % \cxtname{Formula 1}% %
51: % \att{1.}% %
52: % \att{2.}% %
53: % \atr{disqualified}% %
54: % \obj{x..}{Schumacher} %
55: % \obj{.x.}{Barichello} %
56: % \obj{.xx}{Montoya} %
57: % \end{cxt} %
58: % %
59: % Attribute definitions must precede object definitions ! %
60: % %
61: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
62: %
63: \newcommand{\cxt@Kreuz}{$\times$}%
64: \newcommand{\cxt@Punkt}{}%
65: \newcommand{\cxtArrowStyle}{\footnotesize}
66: \newcommand{\cxt@down}{\cxtArrowStyle$\Runterpfeil$}%
67: \newcommand{\cxt@up}{\cxtArrowStyle$\Hochpfeil$}
68: \newcommand{\cxt@both}{\cxtArrowStyle$\Doppelpfeil$}
69: \newcounter{cxt@mAnz}%
70: \newboolean{@ttributes}%
71: \newlength{\cxt@nameraise}%
72: \newlength{\@ttnameheight}%
73: %
74: \newcommand{\adjcxt@name}{%
75: \ifthenelse{\cxt@nameraise<\@ttnameheight}%
76: {\setlength{\cxt@nameraise}{\@ttnameheight}}{}}%
77: %
78: \newcommand{\cxtName}[1]{%
79: \def\cxtn@me{\multicolumn{1}{|c||}{\settoheight{\@ttnameheight}{#1}%
80: \addtolength{\cxt@nameraise}{-1.5\@ttnameheight}%
81: \raisebox{.5\cxt@nameraise}{#1}}}}%
82: %
83: \newcommand{\obj}[2]{\ifthenelse{\boolean{@ttributes}}%
84: {\setboolean{@ttributes}{false}\cxt@tabdef\cxtn@me&%
85: \cxt@tabtop\\\hline\hline}{}#2\cxt@Zeile{#1}\\\hline}%
86: %
87: \newcommand{\att}[1]{\ifthenelse{\boolean{@ttributes}}{%
88: \settoheight{\@ttnameheight}{#1}\adjcxt@name%
89: \ifcase\value{cxt@mAnz}%
90: \def\cxt@maName{#1}\def\cxt@tabtop{\cxt@maName}\or%
91: \def\cxt@mbName{\cxt@maName}\def\cxt@tabtop{\cxt@mbName}\or%
92: \def\cxt@mcName{\cxt@mbName}\def\cxt@tabtop{\cxt@mcName}\or%
93: \def\cxt@mdName{\cxt@mcName}\def\cxt@tabtop{\cxt@mdName}\or%
94: \def\cxt@meName{\cxt@mdName}\def\cxt@tabtop{\cxt@meName}\or%
95: \def\cxt@mfName{\cxt@meName}\def\cxt@tabtop{\cxt@mfName}\or%
96: \def\cxt@mgName{\cxt@mfName}\def\cxt@tabtop{\cxt@mgName}\or%
97: \def\cxt@mhName{\cxt@mgName}\def\cxt@tabtop{\cxt@mhName}\or%
98: \def\cxt@miName{\cxt@mhName}\def\cxt@tabtop{\cxt@miName}\or%
99: \def\cxt@mjName{\cxt@miName}\def\cxt@tabtop{\cxt@mjName}\or%
100: \def\cxt@mkName{\cxt@mjName}\def\cxt@tabtop{\cxt@mkName}\or%
101: \def\cxt@mlName{\cxt@mkName}\def\cxt@tabtop{\cxt@mlName}\or%
102: \def\cxt@mmName{\cxt@mlName}\def\cxt@tabtop{\cxt@mmName}\or%
103: \def\cxt@mnName{\cxt@mmName}\def\cxt@tabtop{\cxt@mnName}\or%
104: \def\cxt@moName{\cxt@mnName}\def\cxt@tabtop{\cxt@moName}\or%
105: \def\cxt@mpName{\cxt@moName}\def\cxt@tabtop{\cxt@mpName}\or%
106: \def\cxt@mqName{\cxt@mpName}\def\cxt@tabtop{\cxt@mqName}\or%
107: \def\cxt@mrName{\cxt@mqName}\def\cxt@tabtop{\cxt@mrName}\or%
108: \def\cxt@msName{\cxt@mrName}\def\cxt@tabtop{\cxt@msName}\or%
109: \def\cxt@mtName{\cxt@msName}\def\cxt@tabtop{\cxt@mtName}\fi%
110: \stepcounter{cxt@mAnz}}%
111: {\PackageWarning{fca}{Attribute following object in cxt-environment%
112: has been ignored}{}}}%
113: \newcommand{\atr}[1]{\att{\begin{turn}{90}#1~~\end{turn}}}%
114: %
115: \def\cxt@tabdef{\begin{tabular}{|l||*{\value{cxt@mAnz}}{c|}}\hline}
116: %
117: \def\cxt@aPunkt{&\phantom{\cxt@Kreuz}}%
118: \def\cxt@aKreuz{&\cxt@Kreuz}%
119: \def\cxt@adown{&\rlap{\cxt@down}\phantom{\cxt@Kreuz}}%
120: \def\cxt@aup{&\rlap{\cxt@up}\phantom{\cxt@Kreuz}}%
121: \def\cxt@aboth{&\rlap{\cxt@both}\phantom{\cxt@Kreuz}}%
122: %
123: \def\cxt@stop{}%
124: \def\readcxt@zeile#1{\ifx#1\cxt@stop\let\next=\relax\else%
125: \ifx#1x\cxt@aKreuz%
126: \else\ifx#1X\cxt@aKreuz%
127: \else\ifx#1b\cxt@aboth%
128: \else\ifx#1u\cxt@aup%
129: \else\ifx#1d\cxt@adown%
130: \else\cxt@aPunkt\fi\fi\fi\fi\fi%
131: \let\next=\readcxt@zeile\fi\next}%
132: \def\cxt@Zeile#1{\readcxt@zeile#1\cxt@stop}%
133: %
134: \newcommand{\Reset@cxtDefaults}{%
135: \setlength{\cxt@nameraise}{0pt}%
136: \setlength{\@ttnameheight}{0pt}%
137: \setcounter{cxt@mAnz}{0}%
138: \setboolean{@ttributes}{true}%
139: \newcommand{\cxtn@me}{}}%
140: %
141: \newenvironment{cxt}{\Reset@cxtDefaults}{\hline\end{tabular}}%
142: %
143: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
144: % %
145: % end of cxt environment definition %
146: % %
147: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
148: % %
149: % environment diagram for making diagrams of ordered sets and graphs %
150: % %
151: % To obtain a diagram for the concept lattice of the formal context %
152: % above, try %
153: % %
154: %{\unitlength 1.2mm %
155: %\begin{diagram}{40}{55} %
156: % \Node{1}{20}{10} %
157: % \Node{2}{35}{20} %
158: % \Node{3}{5}{30} %
159: % \Node{4}{35}{40} %
160: % \Node{5}{20}{50} %
161: % \Edge{1}{2} %
162: % \Edge{1}{3} %
163: % \Edge{2}{4} %
164: % \Edge{3}{5} %
165: % \Edge{4}{5} %
166: % \leftAttbox{3}{2}{2}{1.} %
167: % \rightAttbox{2}{2}{2}{disqualified} %
168: % \rightAttbox{4}{2}{2}{2.} %
169: % \leftObjbox{3}{2}{2}{Schumacher} %
170: % \rightObjbox{2}{2}{2}{Montoya} %
171: % \rightObjbox{4}{2}{2}{Barichello} %
172: %\end{diagram}} %
173: % %
174: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
175: % %
176: % The syntax of the commands is %
177: % %
178: % \begin{diagram}{width}{height} %
179: % %
180: % \Node{number}{xcoordinate}{ycoordinate} % (nodenumbers from 0 to 50) %
181: % %
182: % \Edge{nodenumber1}{Nodenumber2} %
183: % %
184: % \leftAttbox{nodenumber}{xoffset}{yoffset}{text1 \\ text2 \\ ... } %
185: % %
186: % similarly: \rightAttbox, \centerAttbox, %
187: % \leftObjbox, \centerObjbox, \rightObjbox. %
188: % %
189: % \end{diagram} %
190: % %
191: % The circle size can be changed with the \CircleSize command. Default is %
192: % %
193: % \CircleSize{4mm} %
194: % %
195: % A helpful command when fine tuning a diagram is %
196: % %
197: % \Numbers %
198: % %
199: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
200: % %
201: % You may wish to permanently adjust the following values to your %
202: % personal preferences. They can also be changed inside each diagram %
203: % environment using \renewcommand. %
204: % %
205: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
206: \newcommand{\fca@Defaults}{% Do not change this line! %
207: \newcommand{\ObjectLabelStyle}{\small\baselineskip6pt\rm}% %
208: \newcommand{\AttributeLabelStyle}{\small\baselineskip6pt\it}% %
209: \newcommand{\LabelBoxWidth}{40mm}}% %
210: \newboolean{fca@dots}\setboolean{fca@dots}{true}% %
211: \newcommand{\diagramXoffset}{0}% %
212: \newcommand{\diagramYoffset}{0}% %
213: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
214: %
215: \newcounter{fca@minNode}
216: \newcounter{fca@maxNode}
217: \newcounter{fca@runNode}
218: \newboolean{fca@CircledNumbers}
219: \newcounter{fca@CircleDiameter}
220: \newcounter{fca@AuxCounter}
221: \newcounter{fca@BuxCounter}
222: \def\fca@adjNode#1{%
223: \ifthenelse{#1<\value{fca@minNode}}{\setcounter{fca@minNode}{#1}}{}%
224: \ifthenelse{\value{fca@maxNode}<#1}{\setcounter{fca@maxNode}{#1}}{}}%
225: \def\Node#1#2#3{\fca@adjNode{#1}\ifcase#1%
226: \def\fca@xaa{#2}\def\fca@yaa{#3}\or%
227: \def\fca@xab{#2}\def\fca@yab{#3}\or%
228: \def\fca@xac{#2}\def\fca@yac{#3}\or%
229: \def\fca@xad{#2}\def\fca@yad{#3}\or%
230: \def\fca@xae{#2}\def\fca@yae{#3}\or%
231: \def\fca@xaf{#2}\def\fca@yaf{#3}\or%
232: \def\fca@xag{#2}\def\fca@yag{#3}\or%
233: \def\fca@xah{#2}\def\fca@yah{#3}\or%
234: \def\fca@xai{#2}\def\fca@yai{#3}\or%
235: \def\fca@xaj{#2}\def\fca@yaj{#3}\or%
236: \def\fca@xak{#2}\def\fca@yak{#3}\or%
237: \def\fca@xal{#2}\def\fca@yal{#3}\or%
238: \def\fca@xam{#2}\def\fca@yam{#3}\or%
239: \def\fca@xan{#2}\def\fca@yan{#3}\or%
240: \def\fca@xao{#2}\def\fca@yao{#3}\or%
241: \def\fca@xap{#2}\def\fca@yap{#3}\or%
242: \def\fca@xaq{#2}\def\fca@yaq{#3}\or%
243: \def\fca@xar{#2}\def\fca@yar{#3}\or%
244: \def\fca@xas{#2}\def\fca@yas{#3}\or%
245: \def\fca@xat{#2}\def\fca@yat{#3}\or%
246: \def\fca@xau{#2}\def\fca@yau{#3}\or%
247: \def\fca@xav{#2}\def\fca@yav{#3}\or%
248: \def\fca@xaw{#2}\def\fca@yaw{#3}\or%
249: \def\fca@xax{#2}\def\fca@yax{#3}\or%
250: \def\fca@xay{#2}\def\fca@yay{#3}\or%
251: \def\fca@xaz{#2}\def\fca@yaz{#3}\or%
252: \def\fca@xba{#2}\def\fca@yba{#3}\or%
253: \def\fca@xbb{#2}\def\fca@ybb{#3}\or%
254: \def\fca@xbc{#2}\def\fca@ybc{#3}\or%
255: \def\fca@xbd{#2}\def\fca@ybd{#3}\or%
256: \def\fca@xbe{#2}\def\fca@ybe{#3}\or%
257: \def\fca@xbf{#2}\def\fca@ybf{#3}\or%
258: \def\fca@xbg{#2}\def\fca@ybg{#3}\or%
259: \def\fca@xbh{#2}\def\fca@ybh{#3}\or%
260: \def\fca@xbi{#2}\def\fca@ybi{#3}\or%
261: \def\fca@xbj{#2}\def\fca@ybj{#3}\or%
262: \def\fca@xbk{#2}\def\fca@ybk{#3}\or%
263: \def\fca@xbl{#2}\def\fca@ybl{#3}\or%
264: \def\fca@xbm{#2}\def\fca@ybm{#3}\or%
265: \def\fca@xbn{#2}\def\fca@ybn{#3}\or%
266: \def\fca@xbo{#2}\def\fca@ybo{#3}\or%
267: \def\fca@xbp{#2}\def\fca@ybp{#3}\or%
268: \def\fca@xbq{#2}\def\fca@ybq{#3}\or%
269: \def\fca@xbr{#2}\def\fca@ybr{#3}\or%
270: \def\fca@xbs{#2}\def\fca@ybs{#3}\or%
271: \def\fca@xbt{#2}\def\fca@ybt{#3}\or%
272: \def\fca@xbu{#2}\def\fca@ybu{#3}\or%
273: \def\fca@xbv{#2}\def\fca@ybv{#3}\or%
274: \def\fca@xbw{#2}\def\fca@ybw{#3}\or%
275: \def\fca@xbx{#2}\def\fca@ybx{#3}\or%
276: \def\fca@xby{#2}\def\fca@yby{#3}\or%
277: \def\fca@xbz{#2}\def\fca@ybz{#3}\fi}%
278: \def\fca@getNode#1{%
279: \ifcase#1%
280: \def\fca@x{\fca@xaa}\or\def\fca@x{\fca@xab}\or\def\fca@x{\fca@xac}\or%
281: \def\fca@x{\fca@xad}\or\def\fca@x{\fca@xae}\or\def\fca@x{\fca@xaf}\or%
282: \def\fca@x{\fca@xag}\or\def\fca@x{\fca@xah}\or\def\fca@x{\fca@xai}\or%
283: \def\fca@x{\fca@xaj}\or\def\fca@x{\fca@xak}\or\def\fca@x{\fca@xal}\or%
284: \def\fca@x{\fca@xam}\or\def\fca@x{\fca@xan}\or\def\fca@x{\fca@xao}\or%
285: \def\fca@x{\fca@xap}\or\def\fca@x{\fca@xaq}\or\def\fca@x{\fca@xar}\or%
286: \def\fca@x{\fca@xas}\or\def\fca@x{\fca@xat}\or\def\fca@x{\fca@xau}\or%
287: \def\fca@x{\fca@xav}\or\def\fca@x{\fca@xaw}\or\def\fca@x{\fca@xax}\or%
288: \def\fca@x{\fca@xay}\or\def\fca@x{\fca@xaz}\or%
289: \def\fca@x{\fca@xba}\or\def\fca@x{\fca@xbb}\or\def\fca@x{\fca@xbc}\or%
290: \def\fca@x{\fca@xbd}\or\def\fca@x{\fca@xbe}\or\def\fca@x{\fca@xbf}\or%
291: \def\fca@x{\fca@xbg}\or\def\fca@x{\fca@xbh}\or\def\fca@x{\fca@xbi}\or%
292: \def\fca@x{\fca@xbj}\or\def\fca@x{\fca@xbk}\or\def\fca@x{\fca@xbl}\or%
293: \def\fca@x{\fca@xbm}\or\def\fca@x{\fca@xbn}\or\def\fca@x{\fca@xbo}\or%
294: \def\fca@x{\fca@xbp}\or\def\fca@x{\fca@xbq}\or\def\fca@x{\fca@xbr}\or%
295: \def\fca@x{\fca@xbs}\or\def\fca@x{\fca@xbt}\or\def\fca@x{\fca@xbu}\or%
296: \def\fca@x{\fca@xbv}\or\def\fca@x{\fca@xbw}\or\def\fca@x{\fca@xbx}\or%
297: \def\fca@x{\fca@xby}\or\def\fca@x{\fca@xbz}\fi%
298: \ifcase#1%
299: \def\fca@y{\fca@yaa}\or\def\fca@y{\fca@yab}\or\def\fca@y{\fca@yac}\or%
300: \def\fca@y{\fca@yad}\or\def\fca@y{\fca@yae}\or\def\fca@y{\fca@yaf}\or%
301: \def\fca@y{\fca@yag}\or\def\fca@y{\fca@yah}\or\def\fca@y{\fca@yai}\or%
302: \def\fca@y{\fca@yaj}\or\def\fca@y{\fca@yak}\or\def\fca@y{\fca@yal}\or%
303: \def\fca@y{\fca@yam}\or\def\fca@y{\fca@yan}\or\def\fca@y{\fca@yao}\or%
304: \def\fca@y{\fca@yap}\or\def\fca@y{\fca@yaq}\or\def\fca@y{\fca@yar}\or%
305: \def\fca@y{\fca@yas}\or\def\fca@y{\fca@yat}\or\def\fca@y{\fca@yau}\or%
306: \def\fca@y{\fca@yav}\or\def\fca@y{\fca@yaw}\or\def\fca@y{\fca@yax}\or%
307: \def\fca@y{\fca@yay}\or\def\fca@y{\fca@yaz}\or%
308: \def\fca@y{\fca@yba}\or\def\fca@y{\fca@ybb}\or\def\fca@y{\fca@ybc}\or%
309: \def\fca@y{\fca@ybd}\or\def\fca@y{\fca@ybe}\or\def\fca@y{\fca@ybf}\or%
310: \def\fca@y{\fca@ybg}\or\def\fca@y{\fca@ybh}\or\def\fca@y{\fca@ybi}\or%
311: \def\fca@y{\fca@ybj}\or\def\fca@y{\fca@ybk}\or\def\fca@y{\fca@ybl}\or%
312: \def\fca@y{\fca@ybm}\or\def\fca@y{\fca@ybn}\or\def\fca@y{\fca@ybo}\or%
313: \def\fca@y{\fca@ybp}\or\def\fca@y{\fca@ybq}\or\def\fca@y{\fca@ybr}\or%
314: \def\fca@y{\fca@ybs}\or\def\fca@y{\fca@ybt}\or\def\fca@y{\fca@ybu}\or%
315: \def\fca@y{\fca@ybv}\or\def\fca@y{\fca@ybw}\or\def\fca@y{\fca@ybx}\or%
316: \def\fca@y{\fca@yby}\or\def\fca@y{\fca@ybz}\fi}%
317: \def\fca@getNodeb#1{\ifcase#1%
318: \def\fca@u{\fca@xaa}\or\def\fca@u{\fca@xab}\or\def\fca@u{\fca@xac}\or%
319: \def\fca@u{\fca@xad}\or\def\fca@u{\fca@xae}\or\def\fca@u{\fca@xaf}\or%
320: \def\fca@u{\fca@xag}\or\def\fca@u{\fca@xah}\or\def\fca@u{\fca@xai}\or%
321: \def\fca@u{\fca@xaj}\or\def\fca@u{\fca@xak}\or\def\fca@u{\fca@xal}\or%
322: \def\fca@u{\fca@xam}\or\def\fca@u{\fca@xan}\or\def\fca@u{\fca@xao}\or%
323: \def\fca@u{\fca@xap}\or\def\fca@u{\fca@xaq}\or\def\fca@u{\fca@xar}\or%
324: \def\fca@u{\fca@xas}\or\def\fca@u{\fca@xat}\or\def\fca@u{\fca@xau}\or%
325: \def\fca@u{\fca@xav}\or\def\fca@u{\fca@xaw}\or\def\fca@u{\fca@xax}\or%
326: \def\fca@u{\fca@xay}\or\def\fca@u{\fca@xaz}\or%
327: \def\fca@u{\fca@xba}\or\def\fca@u{\fca@xbb}\or\def\fca@u{\fca@xbc}\or%
328: \def\fca@u{\fca@xbd}\or\def\fca@u{\fca@xbe}\or\def\fca@u{\fca@xbf}\or%
329: \def\fca@u{\fca@xbg}\or\def\fca@u{\fca@xbh}\or\def\fca@u{\fca@xbi}\or%
330: \def\fca@u{\fca@xbj}\or\def\fca@u{\fca@xbk}\or\def\fca@u{\fca@xbl}\or%
331: \def\fca@u{\fca@xbm}\or\def\fca@u{\fca@xbn}\or\def\fca@u{\fca@xbo}\or%
332: \def\fca@u{\fca@xbp}\or\def\fca@u{\fca@xbq}\or\def\fca@u{\fca@xbr}\or%
333: \def\fca@u{\fca@xbs}\or\def\fca@u{\fca@xbt}\or\def\fca@u{\fca@xbu}\or%
334: \def\fca@u{\fca@xbv}\or\def\fca@u{\fca@xbw}\or\def\fca@u{\fca@xbx}\or%
335: \def\fca@u{\fca@xby}\or\def\fca@u{\fca@xbz}\fi%
336: \ifcase#1%
337: \def\fca@v{\fca@yaa}\or\def\fca@v{\fca@yab}\or\def\fca@v{\fca@yac}\or%
338: \def\fca@v{\fca@yad}\or\def\fca@v{\fca@yae}\or\def\fca@v{\fca@yaf}\or%
339: \def\fca@v{\fca@yag}\or\def\fca@v{\fca@yah}\or\def\fca@v{\fca@yai}\or%
340: \def\fca@v{\fca@yaj}\or\def\fca@v{\fca@yak}\or\def\fca@v{\fca@yal}\or%
341: \def\fca@v{\fca@yam}\or\def\fca@v{\fca@yan}\or\def\fca@v{\fca@yao}\or%
342: \def\fca@v{\fca@yap}\or\def\fca@v{\fca@yaq}\or\def\fca@v{\fca@yar}\or%
343: \def\fca@v{\fca@yas}\or\def\fca@v{\fca@yat}\or\def\fca@v{\fca@yau}\or%
344: \def\fca@v{\fca@yav}\or\def\fca@v{\fca@yaw}\or\def\fca@v{\fca@yax}\or%
345: \def\fca@v{\fca@yay}\or\def\fca@v{\fca@yaz}\or%
346: \def\fca@v{\fca@yba}\or\def\fca@v{\fca@ybb}\or\def\fca@v{\fca@ybc}\or%
347: \def\fca@v{\fca@ybd}\or\def\fca@v{\fca@ybe}\or\def\fca@v{\fca@ybf}\or%
348: \def\fca@v{\fca@ybg}\or\def\fca@v{\fca@ybh}\or\def\fca@v{\fca@ybi}\or%
349: \def\fca@v{\fca@ybj}\or\def\fca@v{\fca@ybk}\or\def\fca@v{\fca@ybl}\or%
350: \def\fca@v{\fca@ybm}\or\def\fca@v{\fca@ybn}\or\def\fca@v{\fca@ybo}\or%
351: \def\fca@v{\fca@ybp}\or\def\fca@v{\fca@ybq}\or\def\fca@v{\fca@ybr}\or%
352: \def\fca@v{\fca@ybs}\or\def\fca@v{\fca@ybt}\or\def\fca@v{\fca@ybu}\or%
353: \def\fca@v{\fca@ybv}\or\def\fca@v{\fca@ybw}\or\def\fca@v{\fca@ybx}\or%
354: \def\fca@v{\fca@yby}\or\def\fca@v{\fca@ybz}\fi}%
355: %
356: \newcommand{\Edge}[2]{\fca@getNode{#1}\fca@getNodeb{#2}%
357: \drawline(\fca@x,\fca@y)(\fca@u,\fca@v)}%
358: %
359: \def\fca@changeaValue#1#2#3{\setcounter{fca@AuxCounter}{#1}%
360: \addtocounter{fca@AuxCounter}{#2}\def#3{\value{fca@AuxCounter}}}%
361: \def\fca@changebValue#1#2#3{\setcounter{fca@BuxCounter}{#1}%
362: \addtocounter{fca@BuxCounter}{#2}\def#3{\value{fca@BuxCounter}}}%
363: \newcommand{\Nodots}{\setboolean{fca@dots}{false}}
364: %
365: \def\leftAttbox#1#2#3#4{\fca@getNode{#1}\put(\fca@x,\fca@y){%
366: \begin{picture}(#2,#3)(#2,0)%
367: \put(0,#3){\makebox(0,0)[rb]{\begin{minipage}{\LabelBoxWidth}%
368: \raggedleft\AttributeLabelStyle#4\end{minipage}}}%
369: \fca@changebValue{#3}{-1}{\fca@u}%
370: \ifthenelse{\boolean{fca@dots}}{{\thinlines\dottedline(1,\fca@u)(#2,0)}}{}%
371: \end{picture}}}%
372: %
373: \def\centerAttbox#1#2#3#4{\fca@getNode{#1}\put(\fca@x,\fca@y){%
374: \begin{picture}(#2,#3)(0,0)%
375: \put(#2,#3){\makebox(0,0)[cb]{\begin{minipage}{\LabelBoxWidth}%
376: \centering\AttributeLabelStyle#4\end{minipage}}}%
377: \fca@changeaValue{#2}{0}{\fca@u}\fca@changebValue{#3}{-1}{\fca@v}%
378: \ifthenelse{\boolean{fca@dots}}{{\thinlines\dottedline(\fca@u,\fca@v)(0,0)}}{}%
379: \end{picture}}}%
380: %
381: \def\rightAttbox#1#2#3#4{\fca@getNode{#1}\put(\fca@x,\fca@y){%
382: \begin{picture}(#2,#3)(0,0)%
383: \put(#2,#3){\makebox(0,0)[lb]{\begin{minipage}{\LabelBoxWidth}%
384: \raggedright\AttributeLabelStyle#4\end{minipage}}}%
385: \fca@changeaValue{#2}{-1}{\fca@u}\fca@changebValue{#3}{-1}{\fca@v}%
386: \ifthenelse{\boolean{fca@dots}}{{\thinlines\dottedline(0,0)(\fca@u,\fca@v)}}{}%
387: \end{picture}}}%
388: %
389: \def\leftObjbox#1#2#3#4{\fca@getNode{#1}\put(\fca@x,\fca@y){%
390: \begin{picture}(#2,#3)(#2,#3)%
391: \put(0,0){\makebox(0,0)[rt]{\begin{minipage}{\LabelBoxWidth}%
392: \raggedleft\ObjectLabelStyle#4\end{minipage}}}%
393: \ifthenelse{\boolean{fca@dots}}{{\thinlines\dottedline(1,1)(#2,#3)}}{}%
394: \end{picture}}}%
395: %
396: \def\centerObjbox#1#2#3#4{\fca@getNode{#1}\put(\fca@x,\fca@y){%
397: \begin{picture}(#2,#3)(0,#3)%
398: \put(#2,0){\makebox(0,0)[ct]{\begin{minipage}{\LabelBoxWidth}%
399: \centering\ObjectLabelStyle#4\end{minipage}}}%
400: \ifthenelse{\boolean{fca@dots}}{{\thinlines\dottedline(0,#3)(#2,1)}}{}%
401: \end{picture}}}%
402: %
403: \def\rightObjbox#1#2#3#4{\fca@getNode{#1}\put(\fca@x,\fca@y){%
404: \begin{picture}(#2,#3)(0,#3)%
405: \put(#2,0){\makebox(0,0)[lt]{\begin{minipage}{\LabelBoxWidth}%
406: \raggedright\ObjectLabelStyle#4\end{minipage}}}%
407: \fca@changeaValue{#2}{-1}{\fca@u}%
408: \ifthenelse{\boolean{fca@dots}}{{\thinlines\dottedline(0,#3)(\fca@u,1)}}{}%
409: \end{picture}}}%
410: %
411: \def\fca@ResetDefaults{\setcounter{fca@minNode}{60}%
412: \setcounter{fca@maxNode}{0}%
413: \setcounter{fca@CircleDiameter}{4}%
414: \setboolean{fca@CircledNumbers}{false}%
415: \fca@Defaults}%
416: %
417: \newcommand{\Numbers}{\setboolean{fca@CircledNumbers}{true}%
418: \addtocounter{fca@CircleDiameter}{2}}%
419: %
420: \newcommand{\CircleSize}[1]{\setcounter{fca@CircleDiameter}{#1}}%
421: %
422: \def\fca@circle{\ifthenelse{\boolean{pdf}}{%
423: \ifthenelse{\boolean{fca@CircledNumbers}}{%
424: \circle{\value{fca@CircleDiameter}}}{\circle*{\value{fca@CircleDiameter}}}}%
425: {\whiten\circle{\value{fca@CircleDiameter}}}}%
426: %
427: \def\fca@DrawCircles{\setcounter{fca@runNode}{\value{fca@minNode}}%
428: \stepcounter{fca@maxNode}%
429: \whiledo{\value{fca@runNode}<\value{fca@maxNode}}%
430: {\fca@getNode{\value{fca@runNode}}%
431: \put(\fca@x,\fca@y){\fca@circle}%
432: \ifthenelse{\boolean{fca@CircledNumbers}}%
433: {\put(\fca@x,\fca@y){\makebox(0,0){\tiny\arabic{fca@runNode}}}}{}%
434: \stepcounter{fca@runNode}}}%
435: %
436: \newenvironment{diagram}[2]%
437: {\fca@ResetDefaults%
438: \noindent\begin{picture}(#1,#2)(\diagramXoffset,\diagramYoffset)}%
439: {\fca@DrawCircles\end{picture}}%
440: %
441: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
442: % %
443: % End of diagram environment definition. %
444: % %
445: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
446: % %
447: % Some simple macros for FCA-text. %
448: % %
449: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
450: %
451: \providecommand{\GMI}{(G,M,\relI)}
452: \newcommand{\context}[1][K]{\ensuremath{\mathbb{#1}}}
453: \providecommand{\'}{\ensuremath{\sp\prime}}% derivation operator
454: \providecommand{\extent}[1]{\textrm{ext}(#1)}
455: \providecommand{\intent}[1]{\textrm{int}(#1)}
456: \providecommand{\extents}[1]{\textrm{Ext}(#1)}
457: \providecommand{\intents}[1]{\textrm{Int}(#1)}
458: \providecommand{\BV}{\underline{{\mathfrak B}}}
459: \providecommand{\CL}{\BV}
460: \providecommand{\BGMI}{{\mathfrak B} (G,M,\relI)}
461: \providecommand{\CGMI}{\BGMI}
462: \providecommand{\BVGMI}{\BV (G,M,\relI)}
463: \providecommand{\CLGMI}{\BVGMI}
464: \providecommand{\HNI}{(H,N,\relI \cap\; H{\times}N)}
465: \providecommand{\relI}{\mathrel{I}}
466: \providecommand{\notI}{\mathrel{\mbox{\rlap{\char'40}%
467: {\it I}\hspace*{-0.09em}\raisebox{.27ex}{\char'40}}}}%
468: %
469: \providecommand{\bigtimes}{\mathop{%
470: \mathchoice{\raisebox{-2pt}{\huge$\times$}}{\mbox{\LARGE$\times$}}%
471: {\raisebox{0pt}{\Large$\times$}}{\times}}\displaylimits}%
472: %
473: \providecommand{\Runterpfeil}{\mathrel{\swarrow}}
474: \providecommand{\DownArrow}{\Runterpfeil}
475: \providecommand{\Hochpfeil}{\mathrel{\nearrow}}
476: \providecommand{\UpArrow}{\Hochpfeil}
477: \providecommand{\IRunterpfeil}{\mathrel{\searrow}}
478: \providecommand{\IDownArrow}{\IRunterpfeil}
479: \providecommand{\IHochpfeil}{\mathrel{\nwarrow}}
480: \providecommand{\IUpArrow}{\IHochpfeil}
481: \providecommand{\Doppelpfeil}{\mathrel{\!\!\rlap{$\;\nearrow$}\swarrow}}
482: \providecommand{\DoubleArrow}{\Doppelpfeil}
483: %
484: \newcommand{\DDPfeil}{\mathrel{\mathchoice%
485: {\mbox{$\displaystyle\swarrow\hspace{-.7em}\swarrow$}}
486: {\mbox{$\textstyle\swarrow\hspace{-.7em}\swarrow$}}
487: {\mbox{$\scriptstyle\swarrow\hspace{-.5em}\swarrow$}}
488: {\mbox{$\scriptscriptstyle\swarrow\hspace{-.35em}\swarrow$}}}}
489: %
490: \newcommand{\NDDPfeil}{\mathrel{\mathchoice%
491: {\mbox{$\displaystyle\swarrow\hspace{-.7em}\swarrow%
492: \hspace{-1.2em}\backslash\hspace{.4em}$}}
493: {\mbox{$\textstyle\swarrow\hspace{-.7em}\swarrow
494: \hspace{-1.1em}\backslash\hspace{.4em}$}}
495: {\mbox{$\scriptstyle\swarrow\hspace{-.5em}\swarrow
496: \hspace{-.6em}\backslash\hspace{.2em}$}}
497: {\mbox{$\scriptscriptstyle\swarrow\hspace{-.35em}\swarrow
498: \hspace{-.5em}\backslash\hspace{.1em}$}}}}
499: %
500: \providecommand{\DPfeil}{\DDPfeil}
501: \providecommand{\NDPfeil}{\NDDPfeil}
502: \newcommand{\DDArrow}{\DDPfeil}
503: \newcommand{\NDDArrow}{\NDDPfeil}
504: \providecommand{\Semi}{\mathrel{\mbox{\tiny\rlap{\raisebox{2.0ex}%
505: {$\bigtriangledown$}}\raisebox{-0.0ex}{$\bigtriangleup$}}}}
506: \def\ovee{\mbox{\small$\mathrel{\hspace{.35em}\raisebox{-1pt}%
507: {$\smash{\vee}$}\hspace*{-.835em}\bigcirc\hspace{.2em}}$}}
508: \def\owedge{\mbox{\small$\mathrel{\hspace{.35em}\smash{\wedge}%
509: \hspace*{-.835em}\bigcirc\hspace{.2em}}$}}
510: %
511: \providecommand{\ptimes}[1]{\mathrel{\stackrel{#1}{\times}}}
512: %
513: \providecommand{\FCA}{Formal Concept Analysis\xspace}
514: \providecommand{\FBA}{Formale Begriffsanalyse\xspace}
515: \providecommand{\FnBA}{Formalen Begriffsanalyse\xspace}
516: %
517: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
518: % %
519: % End of fca.sty style file definitions %
520: % %
521: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
522:
523: