[Inquiry] Re: Theme One Program -- Commentary Notes
Jon Awbrey
jawbrey at oakland.edu
Wed Mar 19 08:22:09 CST 2003
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
TOP. Commentary Note 17
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
Bud.
Bud is a function from characters to ideas.
It generates a Cog-type structure with the
argument character as the sign of its form.
For example, if mark = "a", then bud (mark)
is an initialized idea-form structure with
the letter "a" in the sign field and whose
'by' pointer points to its containing form:
o-------------o
| o-----o |
o-->| a 0 |---o
o-----o
^
bud |
@
function bud (mark: char): idea;
begin
bud := cog (tag (mark))
end;
(5251)(7591)
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
Nub.
Nub is a function from ideas to ideas.
It initiates a Cog-structure that has
a given idea in the 'as' field of its
component form.
For example, if 'this' is given as the argument idea, whether
nil or otherwise, then nub (this) is an initialized idea-form
structure with the 'as' field of the form made equal to 'this'
and the 'by' field of the form set to contain its own address:
^ this
o--\----------o
| o-----o |
o-->| 0 |---o
o-----o
^
nub |
@
function nub (this: idea): idea;
begin
nub := cog (tog (this))
end;
(5252)(7592)
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
Cue.
Cue is a function from ideas to ideas.
It initiates a Cog-structure that has
a given idea in the 'up' field of its
component form.
For example, if 'this' is given as the argument idea, whether
nil or otherwise, then cue (this) is an initialized idea-form
structure with the 'up' field of the form made equal to 'this'
and the 'by' field of the form set to contain its own address:
^ this
o---|---------o
| o-----o |
o-->| ø 0 |---o
o-----o
^
cue |
@
function cue (this: idea): idea;
begin
cue := upset (nib, this)
end;
(5253)(7593)
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
Key.
Key is a function from ideas to ideas.
It initiates a Cog-structure that has
a given idea in the 'up' field of its
component form.
For example, if 'this' is given as the argument idea, whether
nil or otherwise, then key (this) is an initialized idea-form
structure with the 'up' field of the form made equal to 'this'
and the 'by' field of the form set to contain its own address:
^ this
o---|---------o
| o-----o |
o-->| 0 |---o
o-----o
^
key |
@
function key (this: idea): idea;
begin
key := upset (nob, this)
end;
(5254)(7594)
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
Jog.
Jog is a transformation of ideas that acts as the identity on
the argument idea, nil or otherwise, but if the argument idea
is non-nil and therefore addresses an existing form, then Jog
increments the integer value in the 'code' field of this form
by a step of size one.
function jog (this: idea): idea;
begin
jog := inset (this, anon (reck (this)))
end;
(5255)(7595)
o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o~~~~~~~~~o
More information about the Inquiry
mailing list