II. Notes on Data Structuring * - Cornell University
II. Notes on Data Structuring * - Cornell University
II. Notes on Data Structuring * - Cornell University
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
86 c.A.R. HOARE<br />
is what is c<strong>on</strong>sidered relevant; its colour, shape, and producti<strong>on</strong> technique<br />
are c<strong>on</strong>sidered to be irrelevant except in so far as they have c<strong>on</strong>tributed to its<br />
elasticity. To take a commercial example, the employees working for a<br />
Company have many characteristics, both physical and mental, which will<br />
be ignored when devising a payroll program for the Company.<br />
The next stage in program design is the decisi<strong>on</strong> of the manner in which<br />
the abstracted informati<strong>on</strong> is to be represented in the computer. An elasticity<br />
functi<strong>on</strong> may be represented by its values at a suitable number of discrete<br />
points; and these may be represented in a variety of ways as a two-dimensi<strong>on</strong>al<br />
array. Alternatively, the elasticity might be given by a computed functi<strong>on</strong>,<br />
and the data be held as a vector of polynomial or chebyshev coefficient for<br />
the functi<strong>on</strong>. A payroll file <strong>on</strong> a computer c<strong>on</strong>sists of a number of records,<br />
<strong>on</strong>e relating to each employee. The choice of representati<strong>on</strong> within the<br />
record of each relevant attribute must be made as part of the design of the<br />
program.<br />
The stage of axiomatisati<strong>on</strong> is not usually regarded as a separate stage in<br />
programming; and is often left implicit. In the case of aircraft flutter, the<br />
axiomatisati<strong>on</strong> is the formulati<strong>on</strong> of the differential equati<strong>on</strong>s which are<br />
presumed to describe the reacti<strong>on</strong> of the real wing to certain kinds of stresses,<br />
and which (it is hoped) also describe the process of approximate soluti<strong>on</strong><br />
<strong>on</strong> the computer. In the case of a payroll, the axioms corresp<strong>on</strong>d to the des-<br />
cripti<strong>on</strong>s of various aspects of the real world which need to be embodied in<br />
the programmfor example, the fact that net pay equals gross pay minus<br />
deducti<strong>on</strong>s.<br />
Finally there comes the task of programming the computer to get it to<br />
carry out those manipulati<strong>on</strong>s <strong>on</strong> the representati<strong>on</strong> of the data that corre-<br />
sp<strong>on</strong>d to the manipulati<strong>on</strong>s in the real world in which we are interested.<br />
The success of a program is dependent <strong>on</strong> three basic c<strong>on</strong>diti<strong>on</strong>s:<br />
(1) The axiomatisati<strong>on</strong> is a correct descripti<strong>on</strong> of those aspects of the real<br />
world with which it is c<strong>on</strong>cerned.<br />
(2) The axiomatisati<strong>on</strong> is a correct descripti<strong>on</strong> of the behaviour of the<br />
program, i.e., that the program c<strong>on</strong>tains no errors.<br />
(3) The choice of representati<strong>on</strong> and the method of manipulati<strong>on</strong> are such<br />
that the cost of running the program <strong>on</strong> the computer is acceptable.<br />
In order to simplify the task of designing and developing a computer<br />
program, it is very helpful to be able to keep these three stages reas<strong>on</strong>ably<br />
separate and to carry them out in the appropriate sequence. Thus the first<br />
stage (axiomatisati<strong>on</strong>) would culminate in a rigorous logical statement of<br />
presuppositi<strong>on</strong>s about the real world, and a formulati<strong>on</strong> of the desired<br />
objectives which are to be achieved by the program. The sec<strong>on</strong>d stage would<br />
culminate in an algorithm, or abstract program, which is dem<strong>on</strong>strably