xref: /dragonfly/games/ching/ching/ching.6 (revision 631c21f2)
1.\"	$NetBSD: ching.6,v 1.5 2005/07/05 08:48:47 wiz Exp $
2.\"
3.\" Copyright (c) Caldera International Inc. 2001-2002. All rights reserved.
4.\"
5.\" Redistribution and use in source and binary forms, with or without
6.\" modification, are permitted provided that the following conditions
7.\" are met:
8.\"
9.\" 1. Redistributions of source code and documentation must retain the
10.\"    above copyright notice, this list of conditions and the following
11.\"    disclaimer.
12.\" 2. Redistributions in binary form must reproduce the above copyright
13.\"    notice, this list of conditions and the following disclaimer in the
14.\"    documentation and/or other materials provided with the distribution.
15.\" 3. All advertising materials mentioning features or use of this software
16.\"    must display the following acknowledgement:
17.\" 	This product includes software developed or owned by Caldera
18.\" 	International, Inc.
19.\" 4. Neither the name of Caldera International, Inc. nor the names of
20.\"    other contributors may be used to endorse or promote products
21.\"    derived from this software without specific prior written permission.
22.\"
23.\" USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA
24.\" INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR
25.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
26.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
27.\" DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE LIABLE
28.\" FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR
29.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
30.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
31.\" BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
32.\" WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
33.\" OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
34.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35.\"
36.\"
37.\" Copyright (c) 1993
38.\"	The Regents of the University of California.  All rights reserved.
39.\"
40.\" Redistribution and use in source and binary forms, with or without
41.\" modification, are permitted provided that the following conditions
42.\" are met:
43.\" 1. Redistributions of source code must retain the above copyright
44.\"    notice, this list of conditions and the following disclaimer.
45.\" 2. Redistributions in binary form must reproduce the above copyright
46.\"    notice, this list of conditions and the following disclaimer in the
47.\"    documentation and/or other materials provided with the distribution.
48.\" 3. Neither the name of the University nor the names of its contributors
49.\"    may be used to endorse or promote products derived from this software
50.\"    without specific prior written permission.
51.\"
52.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
53.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
54.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
55.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
56.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
57.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
58.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
59.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
60.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
61.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
62.\" SUCH DAMAGE.
63.\"
64.\"
65.\"	@(#)ching.6	8.1 (Berkeley) 5/31/93
66.\"
67.Dd February 20, 2021
68.Dt CHING 6
69.Os
70.Sh NAME
71.Nm ching
72.Nd the book of changes and other cookies
73.Sh SYNOPSIS
74.Nm
75.Op hexagram
76.Sh DESCRIPTION
77The
78.Em I Ching
79or
80.Em Book of Changes
81is an ancient Chinese oracle that has been in use for centuries
82as a source of wisdom and advice.
83.Pp
84The text of the
85.Em oracle
86(as it is sometimes known) consists of sixty-four
87.Em hexagrams ,
88each symbolized by a particular arrangement of six straight (\-\-\-)
89and broken (\-\ \-) lines.  These lines have values ranging
90from six through nine, with the even values indicating the broken lines.
91.Pp
92Each hexagram consists of two major sections.  The
93.Sy Judgement
94relates specifically to the matter at hand
95.Po e.g. ,
96.Dq \&It furthers one to have somewhere to go.
97.Pc
98while the
99.Sy Image
100describes the general attributes of the hexagram and how they apply
101to one's own life
102.Pq Dq Thus the superior man makes himself strong and untiring.
103.Pp
104When any of the lines have the values six or nine, they are moving
105lines; for each there is an appended judgement which becomes
106significant.
107Furthermore, the moving lines are inherently unstable
108and change into their opposites; a second hexagram (and thus an
109additional judgement) is formed.
110.Pp
111Normally, one consults the oracle by fixing the desired question
112firmly in mind and then casting a set of changes (lines)
113using yarrow\-stalks or tossed coins.  The resulting hexagram
114will be the answer to the question.
115.Pp
116Using an algorithm suggested by S. C. Johnson, the
117.Ux
118.Em oracle
119simply reads a question from the standard input (up to an EOF) and
120hashes the individual characters in combination with the time of
121day, process id and any other magic numbers which happen to be
122lying around the system.
123The resulting value is used as the seed of a random
124number generator which drives a simulated coin\-toss divination.
125The answer is then piped through
126.Xr nroff 1
127or
128.Xr mandoc 1
129for formatting and will appear on the standard output.
130.Pp
131For those who wish to remain steadfast in the old traditions, the
132oracle will also accept the results of a personal divination using,
133for example, coins.
134To do this, cast the change and then type the
135resulting line values as an argument.
136.Pp
137The impatient modern may prefer to settle for Chinese cookies; try
138.Xr fortune 6 .
139.Sh DIAGNOSTICS
140The great prince issues commands,
141.Pp
142Founds states, vests families with fiefs.
143.Pp
144Inferior people should not be employed.
145.Sh SEE ALSO
146It furthers one to see the great man.
147.Sh BUGS
148Waiting in the mud
149.Pp
150Brings about the arrival of the enemy.
151.Pp
152If one is not extremely careful,
153.Pp
154Somebody may come up from behind and strike him.
155.Pp
156Misfortune.
157