.\" Automatically generated by Pod::Man 4.09 (Pod::Simple 3.35) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .if !\nF .nr F 0 .if \nF>0 \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} .\} .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "DEALER.DPP 6" .TH DEALER.DPP 6 "2018-09-25" "Dealer" "User Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" dealer.dpp \- preprocessor for dealer scripts .SH "SYNOPSIS" .IX Header "SYNOPSIS" \&\fBdealer.dpp\fR [\fIinputfile\fR] .SH "DESCRIPTION" .IX Header "DESCRIPTION" dealer.dpp stands for dealer-pre-processor. Its main purpose it to preprocess input files for Hans van Staveren's great dealer program. .SH "SYNTAX" .IX Header "SYNTAX" The program expands shape specifications of the form: .PP .Vb 1 \& shape{COMPASS, shp1 + shp2 + ... + shpM \- shm1 \- ... \- shmN} .Ve .SS "regular shapes" .IX Subsection "regular shapes" 7xxx, 4432, 4xx5 have the same meaning as in original dealer. .SS "the `at least' operator" .IX Subsection "the `at least' operator" whenever you put a `+' after a suit-length, it means `at least'. .PP .Vb 3 \& shape{north, 5+xx5+}: at least 5/5 in the blacks, \& \-\->shape(north,5xx5 + 5xx6 + 6xx5 + 5xx7 + 6xx6 + 7xx5 + 5008 + 6007 \& + 7006 + 8005) .Ve .SS "the `at most' operator:" .IX Subsection "the `at most' operator:" same as the `at least', just use a `\-': .PP .Vb 2 \& shape{north, 2\-xxx}: at most 2 spades, \& \-\->shape(north,0xxx + 1xxx + 2xxx) .Ve .SS "the `range' operator:" .IX Subsection "the `range' operator:" the range operator operates on a single suit. It comes with [], like in Perl. .PP .Vb 2 \& shape{north, x[3\-5]x[13]}: (3 to 5) hearts, and one or 3 clubs \& \-\->shape(north,x3x1 + x4x1 + x3x3 + x5x1 + x4x3 + x5x3) .Ve .PP Note that shape{north, 3\-xxx} is equivalent to shape{north,[0\-3]xxx} You can write compound ranges if you want: .PP .Vb 1 \& shape{north, [013\-68]xxx} means: 0,1,3,4,5,6 or 8 spades. .Ve .SS "the `permutation' operator:" .IX Subsection "the `permutation' operator:" the permutation operator will appears as () like in the \s-1WBF\s0 rules of specifying shapes. .PP .Vb 2 \& shape{north, (4432)}: any 4432 hand. \& \-\->shape(north,any 4432) .Ve .PP what's best is that the () operator can operate on restricted groups of cards: .PP .Vb 2 \& shape{north, 5s(431)}: 5 spades, the others suits being (431). \& \-\->shape(north,5134 + 5314 + 5143 + 5341 + 5413 + 5431) .Ve .PP What you have to do is: .IP "\(bu" 4 specify the suit names (s,h,d,c in english) in the left part of the shape, in any order, .IP "\(bu" 4 and enclose the rest of the permutation into () in the right part. .PP A (complicated) example: .PP .Vb 3 \& shape{north, 4+c3+d(2+2+)}: at least 5 clubs, at least 3 diamonds, \& and no short major. \& \-\->shape(north,3334 + 4234 + 2434 + 3244 + 2344 + 2254 + 3235 + 2335 + 2245 + 2236) .Ve .SS "the `Major' operator:" .IX Subsection "the `Major' operator:" has to be used together with the () operator. `M' stands for `a major' The `M' operator can only be used in the left part (never put a M inside the parens) .PP .Vb 2 \& shape{north, 5M(xxx)} \& \-\->shape(north,x5xx + 5xxx) \& \& shape{north, 5+M3+c(31)} \& \-\->shape(north,1534 + 3514 + 1633 + 3613 + 5134 + 5314 + 6133 + 6313) .Ve .SS "the `minor' operator:" .IX Subsection "the `minor' operator:" same as the `Major' operator, but in lowercase `m'. .PP .Vb 2 \& shape{north, 5M5m(xx)} \& \-\->shape(north,x5x5 + 5xx5 + x55x + 5x5x) .Ve .SS "the `conditional' operator:" .IX Subsection "the `conditional' operator:" you've got the possibility of specifying complex conditions to be verified that cannot be simply expressed by other operators. In order to do that, you use the `:' operator, just after the atomic-shape specification: .PP .Vb 1 \& shape{north, shp1:condition1,condition2,...} .Ve .PP The conditions use the letters (s,h,d,c) as variables for the suit lengths, and the usual C\-operators (*,+,\-,/,>,<,==,!,?, and so on). Note that the `,' stands for the `and\-logical' operator. You can use `or' for the `or\-logical' operator. .PP .Vb 2 \& shape{north, 4+s4+h(xx):d>c,h+s==10} \& \-\->shape(north,6421 + 6430 + 5521 + 5530 + 4621 + 4630) .Ve .SH "EXAMPLES" .IX Header "EXAMPLES" .IP "a balanced hand" 4 .IX Item "a balanced hand" .Vb 1 \& (3+3+3+2+) .Ve .IP "a french 1H opening" 4 .IX Item "a french 1H opening" .Vb 1 \& x5+xx:h>s,h>=d,h>=c .Ve .IP "my No_trump opening" 4 .IX Item "my No_trump opening" .Vb 5 \& hn = hcp(north) \& n1NT = (hn > 14 and hn < 18 and shape{north, 5m(332) + 5m2s(42)} ) \& or (hn > 13 and hn < 17 and shape{north, 6m(322)} ) \& or (hn > 15 and hn < 18 and shape{north, 5M(332)} ) \& or (hn > 15 and hn < 19 and shape{north, (4432) + (4333)} ) .Ve .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fIdealer\fR\|(6), \&\fI/usr/share/doc/dealer/Manual\fR. .SH "AUTHORS" .IX Header "AUTHORS" .IP "Francois Dellacherie" 4 .IX Item "Francois Dellacherie" .PD 0 .IP "Manpage: Christoph Berg " 4 .IX Item "Manpage: Christoph Berg " .PD .SH "LICENSE" .IX Header "LICENSE" This program is hereby put in the public domain. Do with it whatever you want, but I would like you not to redistribute it in modified form without mentioning the fact of modification. I will accept bug reports and modification requests, without any obligation of course, but fixing bugs someone else put in is beyond me.