[Lemon-commits] Peter Kovacs: Add two more images for adaptors

Lemon HG hg at lemon.cs.elte.hu
Mon Feb 22 19:46:52 CET 2010


details:   http://lemon.cs.elte.hu/hg/lemon-tutorial/rev/73fdafd843d9
changeset: 41:73fdafd843d9
user:      Peter Kovacs <kpeter [at] inf.elte.hu>
date:      Sun Feb 21 19:02:08 2010 +0100
description:
	Add two more images for adaptors

diffstat:

 Makefile.in          |   13 +-
 adaptors.dox         |   14 +-
 images/adaptors1.eps |  303 +++++++++++++++++++++++++++++++++++++++++++
 images/adaptors2.eps |  349 +++++++++++++++++++++++++++++++++++++++++++++++++
 4 files changed, 676 insertions(+), 3 deletions(-)

diffs (truncated from 735 to 300 lines):

diff --git a/Makefile.in b/Makefile.in
--- a/Makefile.in
+++ b/Makefile.in
@@ -2,13 +2,18 @@
 
 EPS_IMAGES18 =
 
-EPS_IMAGES27 = \
+EPS_IMAGES27 =
+
+EPS_IMAGES36 = \
+	adaptors1.eps \
+	adaptors2.eps \
 	splitnodes1.eps \
 	splitnodes2.eps
 
 EPS_IMAGES = \
 	$(EPS_IMAGES18) \
-	$(EPS_IMAGES27)
+	$(EPS_IMAGES27) \
+	$(EPS_IMAGES36)
 
 PNG_IMAGES = \
 	$(EPS_IMAGES:%.eps=gen-images/%.png)
@@ -27,6 +32,10 @@
 	-mkdir -p gen-images
 	$(GS_COMMAND) -sDEVICE=pngalpha -r27 -sOutputFile=$@ $<
 
+$(EPS_IMAGES36:%.eps=gen-images/%.png): gen-images/%.png: images/%.eps
+	-mkdir -p gen-images
+	$(GS_COMMAND) -sDEVICE=pngalpha -r36 -sOutputFile=$@ $<
+
 html: Doxyfile-gen $(PNG_IMAGES)
 	-mkdir -p gen-dox
 	./scripts/titlegen.py
diff --git a/adaptors.dox b/adaptors.dox
--- a/adaptors.dox
+++ b/adaptors.dox
@@ -31,7 +31,6 @@
 operations that should be performed on the altered graph.
 In such cases, the LEMON \e graph \e adaptor \e classes could be used.
 
-
 [SEC]sec_reverse_digraph[SEC] Reverse Oriented Digraph
 
 Let us suppose that we have an instance \c g of a directed graph type, say
@@ -178,6 +177,11 @@
 Another typical requirement is the use of certain subgraphs of a graph,
 or in other words, hiding nodes and/or arcs from a graph.
 LEMON provides several convenient adaptors for these purposes.
+In the following picture, a \ref SubDigraph adaptor is applied to an
+underlying digraph structure to obtain a suitable subgraph.
+
+\image html adaptors1.png
+\image latex adaptors1.eps "SubDigraph adaptor" width=\textwidth
 
 \ref FilterArcs can be used when some arcs have to be hidden from a digraph.
 A \e filter \e map has to be given to the constructor, which assign \c bool
@@ -325,6 +329,14 @@
   Orienter<ListGraph> directed_graph(graph, dir_map);
 \endcode
 
+Sine the adaptor classes conform to the \ref graph_concepts "graph concepts",
+we can even apply an adaptor to another one.
+The following image illustrates a situation when a \ref SubDigraph and an
+\ref Undirector adaptor is applied on a digraph.
+
+\image html adaptors2.png
+\image latex adaptors2.eps "Arc disjoint paths" width=\textwidth
+
 LEMON also provides some more complex adaptors, for
 instance, \ref SplitNodes, which can be used for splitting each node of a
 directed graph into an in-node and an out-node.
diff --git a/images/adaptors1.eps b/images/adaptors1.eps
new file mode 100644
--- /dev/null
+++ b/images/adaptors1.eps
@@ -0,0 +1,303 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: adaptors1.fig
+%%Creator: fig2dev Version 3.2 Patchlevel 5
+%%CreationDate: Sun Feb 21 18:51:21 2010
+%%For: Peter at KOVACSPETER (Péter,U-KOVACSPETER\Peter,S-1-5-21-1774138250-1299389707-1938712334-1001)
+%%BoundingBox: 0 0 787 372
+%Magnification: 1.0000
+%%EndComments
+/$F2psDict 200 dict def
+$F2psDict begin
+$F2psDict /mtrx matrix put
+/col-1 {0 setgray} bind def
+/col0 {0.000 0.000 0.000 srgb} bind def
+/col1 {0.000 0.000 1.000 srgb} bind def
+/col2 {0.000 1.000 0.000 srgb} bind def
+/col3 {0.000 1.000 1.000 srgb} bind def
+/col4 {1.000 0.000 0.000 srgb} bind def
+/col5 {1.000 0.000 1.000 srgb} bind def
+/col6 {1.000 1.000 0.000 srgb} bind def
+/col7 {1.000 1.000 1.000 srgb} bind def
+/col8 {0.000 0.000 0.560 srgb} bind def
+/col9 {0.000 0.000 0.690 srgb} bind def
+/col10 {0.000 0.000 0.820 srgb} bind def
+/col11 {0.530 0.810 1.000 srgb} bind def
+/col12 {0.000 0.560 0.000 srgb} bind def
+/col13 {0.000 0.690 0.000 srgb} bind def
+/col14 {0.000 0.820 0.000 srgb} bind def
+/col15 {0.000 0.560 0.560 srgb} bind def
+/col16 {0.000 0.690 0.690 srgb} bind def
+/col17 {0.000 0.820 0.820 srgb} bind def
+/col18 {0.560 0.000 0.000 srgb} bind def
+/col19 {0.690 0.000 0.000 srgb} bind def
+/col20 {0.820 0.000 0.000 srgb} bind def
+/col21 {0.560 0.000 0.560 srgb} bind def
+/col22 {0.690 0.000 0.690 srgb} bind def
+/col23 {0.820 0.000 0.820 srgb} bind def
+/col24 {0.500 0.190 0.000 srgb} bind def
+/col25 {0.630 0.250 0.000 srgb} bind def
+/col26 {0.750 0.380 0.000 srgb} bind def
+/col27 {1.000 0.500 0.500 srgb} bind def
+/col28 {1.000 0.630 0.630 srgb} bind def
+/col29 {1.000 0.750 0.750 srgb} bind def
+/col30 {1.000 0.880 0.880 srgb} bind def
+/col31 {1.000 0.840 0.000 srgb} bind def
+
+end
+save
+newpath 0 372 moveto 0 0 lineto 787 0 lineto 787 372 lineto closepath clip newpath
+-14.2 385.4 translate
+1 -1 scale
+
+/cp {closepath} bind def
+/ef {eofill} bind def
+/gr {grestore} bind def
+/gs {gsave} bind def
+/sa {save} bind def
+/rs {restore} bind def
+/l {lineto} bind def
+/m {moveto} bind def
+/rm {rmoveto} bind def
+/n {newpath} bind def
+/s {stroke} bind def
+/sh {show} bind def
+/slc {setlinecap} bind def
+/slj {setlinejoin} bind def
+/slw {setlinewidth} bind def
+/srgb {setrgbcolor} bind def
+/rot {rotate} bind def
+/sc {scale} bind def
+/sd {setdash} bind def
+/ff {findfont} bind def
+/sf {setfont} bind def
+/scf {scalefont} bind def
+/sw {stringwidth} bind def
+/tr {translate} bind def
+/tnt {dup dup currentrgbcolor
+  4 -2 roll dup 1 exch sub 3 -1 roll mul add
+  4 -2 roll dup 1 exch sub 3 -1 roll mul add
+  4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}
+  bind def
+/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul
+  4 -2 roll mul srgb} bind def
+ /DrawEllipse {
+	/endangle exch def
+	/startangle exch def
+	/yrad exch def
+	/xrad exch def
+	/y exch def
+	/x exch def
+	/savematrix mtrx currentmatrix def
+	x y tr xrad yrad sc 0 0 1 startangle endangle arc
+	closepath
+	savematrix setmatrix
+	} def
+
+/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def
+/$F2psEnd {$F2psEnteredState restore end} def
+
+$F2psBegin
+10 setmiterlimit
+0 slj 0 slc
+ 0.06299 0.06299 sc
+%
+% Fig objects follow
+%
+% 
+% here starts figure with depth 60
+% Polyline
+0 slj
+0 slc
+15.000 slw
+gs  clippath
+6319 5229 m 6442 5564 l 6527 5533 l 6403 5198 l 6403 5198 l 6424 5383 l 6319 5229 l cp
+eoclip
+n 5850 3825 m
+ 6480 5535 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 6319 5229 m 6424 5383 l 6403 5198 l 6319 5229 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+5417 4044 m 5746 3905 l 5711 3822 l 5382 3961 l 5382 3961 l 5566 3933 l 5417 4044 l cp
+eoclip
+n 1575 5625 m
+ 5715 3870 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 5417 4044 m 5566 3933 l 5382 3961 l 5417 4044 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+3897 3780 m 3540 3780 l 3540 3870 l 3897 3870 l 3897 3870 l 3717 3825 l 3897 3780 l cp
+eoclip
+n 5625 3825 m
+ 3555 3825 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 3897 3780 m 3717 3825 l 3897 3870 l 3897 3780 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+3075 4188 m 3327 3936 l 3263 3872 l 3011 4124 l 3011 4124 l 3171 4029 l 3075 4188 l cp
+eoclip
+n 1575 5625 m
+ 3285 3915 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 3075 4188 m 3171 4029 l 3011 4124 l 3075 4188 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+3528 2520 m 3885 2520 l 3885 2430 l 3528 2430 l 3528 2430 l 3708 2475 l 3528 2520 l cp
+eoclip
+n 1800 2475 m
+ 3870 2475 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 3528 2520 m 3708 2475 l 3528 2430 l 3528 2520 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+4304 2156 m 4052 2408 l 4116 2472 l 4368 2220 l 4368 2220 l 4209 2316 l 4304 2156 l cp
+eoclip
+n 5850 675 m
+ 4095 2430 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 4304 2156 m 4209 2316 l 4368 2220 l 4304 2156 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+6319 2079 m 6442 2414 l 6527 2383 l 6403 2048 l 6403 2048 l 6424 2233 l 6319 2079 l cp
+eoclip
+n 5850 675 m
+ 6480 2385 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 6319 2079 m 6424 2233 l 6403 2048 l 6319 2079 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+5417 894 m 5746 755 l 5711 672 l 5382 811 l 5382 811 l 5566 783 l 5417 894 l cp
+eoclip
+n 1575 2475 m
+ 5715 720 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 5417 894 m 5566 783 l 5382 811 l 5417 894 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+3528 5670 m 3885 5670 l 3885 5580 l 3528 5580 l 3528 5580 l 3708 5625 l 3528 5670 l cp
+eoclip
+n 1800 5625 m
+ 3870 5625 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 3528 5670 m 3708 5625 l 3528 5580 l 3528 5670 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath
+4572 5580 m 4215 5580 l 4215 5670 l 4572 5670 l 4572 5670 l 4392 5625 l 4572 5580 l cp
+eoclip
+n 6300 5625 m
+ 4230 5625 l gs col0 s gr gr
+
+% arrowhead
+75.000 slw
+n 4572 5580 m 4392 5625 l 4572 5670 l 4572 5580 l  cp gs 0.00 setgray ef gr  col0 s
+% Polyline
+15.000 slw
+gs  clippath



More information about the Lemon-commits mailing list