Operate in the public/projects/misc/HEAPSORT/HEAPSORT directory [Preface this demonstration with a look at the Run.e file, and the automated version of heapsort - use the dmt model to show how the dependency is modelled - this gives an idea of the richness of the dependency structure involved.] 1. Introduce stage2.s, stage2.d, stage2.e Note the qualities of the artefact as an analogue representation rather than a traditional ADT Note how observables that are represented visually are meaningful in the comprehension of the heap e.g. ixgtch1 (index of greater child), hc1 (heap condition at node 1) 2. Consider its educational role as an animated whiteboard ... first = 3; last = 5; etc See how the index of the greatest child is 'known to the system' No real behaviour for the model - open to free interaction cf val[1] = 23; etc Capacity for restoring / entering state at will (without 'invoking a procedure') val0 = [2,4,3,6,5,7,1]; val = val0; 3. Demonstrate how you can take the development 'backwards' to a simpler version of the heap model, where first and last are not changeable, and the definitions of ixgtch1,hc1 include("change21"); 4. Definition of hc1 and ixgtch1 are now easier to understand - a conceptual stage preparatory to grasping the general notion of a heap as a segment of an array with a first and last index. 5. Can start to explore effect of actions, such as changing / exchanging values has on the heap condition at nodes etc. - introducing exc.e to give requisite procedure. 6. Can turn this into a GUI style environment for interaction with the heap by introducing the file change23 (with Model 1 in place). Now the user can experiment by clicking at nodes. Learning issues: is the user simply responding to the colours of nodes? c3col is (hc3)?"blue": "red"; --> c3col is (hc3)? BLUE: RED; BLUE = "blue"; RED is BLUE; etc reset via RED = "red"; accuracy of clicking (near = 10) near = 4 ---> test of skill in use of the mouse near = 100 near = 1000 7. Moving to a more constrained behaviour ... include("change12"); include("change13.2"); include("animate.e"); include("add.e"); Can now click to get animation of heapsort where in principle have observables such as the phase of heapsort ... [demonstrate this] Is this heapsort issue? The pattern of exchanges is precisely as prescribed in heapsort, but there is no oblivious behaviour as specified by a procedure (consider how the next index at which to make an exchange if necessary is determined in trad procedural heapsort). Proof of this ... first = 4; last = 7; next = 0; Start heapsorting, then intervene to put val[7] = 8; say - then continue the 'heapsort' procedure. Finally: display Jaratsri's extension with the WP precondition spec alongside. Morals of the exercise - controversial! About EM It is possible through modelling with artefacts to make highly sensitive and discriminating semantic distinctions - cf promiscuous modelling [Cantwell-Smith] using abstract mathematical models It is possible to construct computer models without predetermined goals, formal IO behaviours and use-cases: uncertain interaction in the world is conceptually prior to formalisation We are just at the beginning of understanding how to organise and manage EM model development: need better tools, but also need unorthodox strategies for dealing with issues such as versioning and documenting. About classical computing Much of classical computer science is motivated by optimisation to specific goals (as was historically expedient); clearly specification of function is a prerequisite for optimisation, but it is a mistake to imagine that such specification is an essential prerequisite for constructing computer models. Functional specification is not very prescriptive where program development is concerned Abstract data types do not really capture the analogue characteristics of data types as pseudo-physical artefacts that embody understanding, and underpin mental models to aid the imagination About 'computers for learning' How we construct models is highy relevant to how useful they can be in supporting learning cf. Logo as a vision for constructionism Interaction that is creative in character has to accommodate situation, ignorance and nonsense (the SIN principle) - essence of learning is the capacity not to know, to be suspicious of perfect knowledge, and to be able to make mistakes; these require support from modelling approaches that negotiate meaning through interactive development rather than prescribe the interpretation of interaction in advance About the relationship between EM and classical programming / software development The distinction between EM and rapid prototyping and iterative development as in XP is ontological rather than being simply a matter of degree: the basis for EM is in the notion of construal, and continuity in EM development is in the 'stream of thought' (cf car maintenance analogy in the discussion of the sqleddi environment) The 'experimental paradox' is central to the distinction between EM and the classical theory of computation It is more appropriate to seek a foundation for specification and logic in EM than to seek a foundation for EM in specification and logic