Modelling with definitive scripts “a methodology for ... · automated as possible: set up an...

42
Modelling with definitive scripts “a methodology for modelling with dependency”

Transcript of Modelling with definitive scripts “a methodology for ... · automated as possible: set up an...

Page 1: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Modelling with definit ive scripts

“a methodology

for

modelling with dependency”

Page 2: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 3: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 4: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 5: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 6: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 7: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Semantic orientat ion …

towards exploratory state- as-experienced

NOT circumscribed reliable process as conceived

Page 8: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Semantic Relat ions (I)

p rogram p rocessα

β

Page 9: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Semantic Relat ions (II)

Artefact = scrip t +

com p uter +d isp lay

Page 10: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Developing educat ional software

Student

Developer

Teacher

uses

implements specif ies

Page 11: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Empirical Modelling (EM)

• Offers a set of principles for model building in any of the student, teacher and developer roles:

Student

Developer

Teacher

interacts

model

interacts interacts

Page 12: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 13: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Commonsense agency and concurrency

Page 14: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 15: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

The stationmaster – an LSD account (oracles and states)

agent sm() {

oracle (t ime) Limit, Time, / / knows of t ime to elapse before departure due

(bool) guard_raised_flag, / / knows whether the guard has raised his f lag

(bool) driver_ready, / / knows whether the driver is ready

(bool) around[d], / / knows whether there's anybody around doorway

(bool) door_open[d];

/ / the open/ close status of door d (for d = 1 .. number_of_doors)#

state (t ime) tarrive = | t ime| , / / the S- M registers t ime of arrival

(bool) can_move, / / the signal observed by driver for start ing engine

(bool) whistle = false, / / the whist le is not being blown

(bool) whistled = false, / / the whist le has not been blown

(bool) sm_flag = false, / / S- M lowers f lag

(bool) sm_raised_flag = false; / / S- M has not raised flag…….

Page 16: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

The stationmaster – an LSD account (handles and derivates)

…..

handle (bool) can_move,

(bool) whistle,

(bool) whistled,

(bool) sm_flag,

(bool) sm_raised_flag;

(bool) door_open[d];

/ / the open/ close status of door d (for d = 1 .. number_of_doors)

derivate

number_of_doors

(bool) ready = / \ (!door_open[d]); / / are all doors shut?

d = 1

(bool) t imeout = (Time - tarrive) > Limit; / / departure due

…..

Page 17: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

The stationmaster – an LSD account (protocol / privileges)

…..

protocol

door_open[d] ^ !around[d] - > door_open[d] = false; (d = 1 .. number_of_doors)

ready ^ t imeout ^ !whist led - > whist le = true; whist led = true; guard(); whist le = false;

ready ^ whist led ^ !sm_raised_flag - > sm_flag = true; sm_raised_flag = true;

sm_flag ^ guard_raised_flag - > sm_flag = false;

ready ^ guard_raised_flag ^ driver_ready ^ engaged ^ !can_move - > can_move = true;

}

Page 18: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 19: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Animation

Page 20: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 21: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 22: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 23: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 24: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Some example models

Page 25: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 26: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 27: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 28: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 29: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 30: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 31: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 32: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Figure 6-1: An extended version of heapsort with its formal specification

Formal annotation

Shuffle

Page 33: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 34: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 35: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Requirements

I Initially blank timetable

Final timetable

R020

RO11R017EvolvingRequirements

?Rooms

HCI

SYSTEMS

WWW

?Subjects

External activities!!!

REALIST IDEALIST

Figure 1: Rea lis t and Id ealis t p ersp ect ives on t im etab ling

Page 36: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

supervisor moderator assessor

staff (x 30)

students (x 120) with projects

timeslots (5 days) and rooms (x 2)

Figure 2: The case-study context

Page 37: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Tim etab le d ata

TTSAM

com p letenes s

cons is tencysu itab ility

feas ib ility

In terface elem en ts

… etc.

Mod eller

Figure 3: Outline structure of the Temposcope

Page 38: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Figure 4: Screenshot of the Temposcope

History window

Commentary window

Interface window

Input window

Page 39: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

The Realist (conventional) perspective The Idealist (ISM-based) perspective

uses abstract state and data representations. uses personal and situated personal state and data representations.

follows a hidden algorithm. supports timetabling activity under the complete control (andideally within the comprehension) of the timetabler, with as muchautomation as desired.

offers a system for a specified intended use. offers an open-ended model, "environment" or "instrument" thatthe modeller can shape in ways that are not predetermined, and canuse for ad hoc experimentation.

is difficult to adapt to unforeseen uses. is highly flexible (albeit only in the hands of an experiencedmodeller).

is efficient and optimised. aims at quality rather than efficiency, although some optimisationis possible through run-time analysis of the dependency tree.

is scalable to large problems. offers limited scope for large-scale situated evaluation, unlessperhaps the evaluation is performed in parallel by many peopleusing a distributed ISM.

uses batch-style interaction and is as fullyautomated as possible: set up an input, run thealgorithm, examine the results.

uses spreadsheet-style interaction that gives rich support formodelling functional dependencies. The level of support forprocedural activity ranges from purely manual to fully automatic atthe timetabler's discretion.

is easy to use via an "accessible" user interface. uses an interface that is (ideally) built and adapted interactively tothe modeller's own personal and situated requirements. (Aninterface which admits any possible change to the model is difficultto conceive – by definition, interfaces restrict possibilities.)

accepts only perfect, clean (or very high quality)input.

accepts "arbitrary" input and assumes that all knowledge in themodel is subject to future revision.

involves computer activity that is interpreted bythe user according to preconceived conventions.

involves computer activity that is freely and dynamicallyinterpreted by the modeller according to the current situation.

treats the computer as an abstract computationaldevice with formally defined mathematicalsemantics

treats the computer as an artefact, with a semantics that is mediatedinteractively and experientially

Table 1: Two perspectives on computer-assisted timetabling

Page 40: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that
Page 41: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Sudoku in tkeden

Page 42: Modelling with definitive scripts “a methodology for ... · automated as possible: set up an input, run the algorithm, examine the results. uses spreadsheet-style interaction that

Sudoku in tkeden