14
Introduction to Introduction to Program Design Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Embed Size (px)

Citation preview

Page 1: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Introduction to Program DesignIntroduction to Program Design

Using Jackson Structured Programming (JSP) and Jackson

Workbench

Page 2: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Why good design is importantWhy good design is important

“There is a difference between getting a program to work and getting it right!”

• A poorly designed program may be difficult to read, may not model the problem to be solved, may be difficult to maintain

• A program that corresponds to the problem’s structure is easier to read, test and maintain

Multiplication Table Example• Output requirement• Bad Multiplication Table• To make simple changes, we need to rewrite the program!• Good Multiplication Table designed using JSP• Modifications to Good Multiplication Table are easy to make

and test.

Page 3: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

JSP: Basic Design MethodJSP: Basic Design Method

1. Draw system diagram2. Draw data structure(s) for input(s) and

output(s), showing correspondences, if any

3. Form basic program structure from data structures

4. List operations needed, and allocate to form elaborated program structure

5. Produce structure text or program text

Page 4: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Basic JSP MethodBasic JSP Method

1. Draw system diagram2. Draw data structure(s) for input(s) and

output(s), showing correspondences3. Form basic program structure from data

structures4. List operations needed, and allocate to

form elaborated program structure5. Produce structure text or program text

Page 5: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Using Jackson WorkbenchUsing Jackson Workbench

Web publishing– Structure & text – Structure diagram only

Hands-on

Page 6: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Jackson Workbench ExercisesJackson Workbench ExercisesConstructing Data StructuresConstructing Data Structures

“A simple book consists of pages; a page consists of lines of text; a line consists of words.”

Model a simple book with a structure diagram

Demonstration of Jackson Workbench

Page 7: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Jackson Workbench ExercisesJackson Workbench ExercisesConstructing Data StructuresConstructing Data Structures(cont.)(cont.)

“A regular book consists of a front and back cover with pages in between. Each page consists of lines of text; each line consists of words. At the bottom of each page is a page number.”

Model a regular book with a structure diagram

Demonstration of Jackson Workbench

Page 8: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Jackson Workbench Exercises Jackson Workbench Exercises Modifying basic multiplication tableModifying basic multiplication tableUse JSP to design the multiplication

tableUse JSP to design the three

modifications of the multiplication table

Page 9: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

A Short BibliographyA Short Bibliography

On-line Resources:Michael Jackson Home Page (articles)The Jackson Software Development Methods (Steve Ferg)My Home Page

[1] Cameron, J. JSP&JSD: The Jackson Approach to Software Development. IEEE Computer Society Press. 1983, 1989.

[2] Jackson, M.A. Principles of Program Design. Academic Press, New York, 1975.[3] Jackson, M.A. Constructive Methods of Program Design. In Proc 1st ECI Conference 1976, pp 236-262,

Springer Verlag LNCS 44, Heidelberg 1976. (Reprinted in Cameron 1983/89)[4] Jackson, M.A. A System Development Method. Tools and notions for program construction: An advanced

course; Nice 1981; pages 1-25; Cambridge University Press, 1982.[5] Jackson, M.A. System Development. Prentice-Hall International, Chichester, U.K., 1983.[6] Jackson, M.A. Software Requirements and Specification. Addison-Wesley, 1996.[7] Jackson, M.A. The Origins of JSP and JSD: a Personal Recollection. IEEE Annals of Software Engineering

Volume 22 Number 2, pages 61-63, 66, April-June 2000.[8] Jackson, M.A . JSP in Perspective. sd&m Pioneers’ Conference, Bonn, June 2001.[9] Jackson, M.A. Problem Frames. Addison-Wesley Longman Publishing Co., Inc. , 2001.[10] Ourusoff, Nicholas. Using Jackson Structured Programming (JSP) and Jackson Workbench to Teach

Program Design. (Proceedings of 2003 Informing Science and Information Technology Education, Pori, Finland, June 24-27, 2003. (Accessible at http://ecommerce.lebow.drexel.edu/eli/2003Proceedings/PaperPage106.html)

[11] Ourusoff, Nicholas. Reinvigorating the Software Engineering Curriculum with Jackson’s Methods and Ideas - ACM SIGCSE Quarterly Bulletin, June 2004.

[12]  Ourusoff, Nicholas. Towards a CASE Tool for Jackson's JSP, JSD an Problem Frames - 1st International Workshop on Applications and Advances in  Problem Frames, ICSE May 24, 2004.

Page 10: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Appendix 1: About Michael JacksonAppendix 1: About Michael Jackson

(an English computer scientist, not the pop star!)

Design Methods:

1. JSP (program design method)

2. JSD (systems development method)

3. Problem Frames (problem analysis and decomposition)

Page 11: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Appendix 1: About Michael Jackson Appendix 1: About Michael Jackson (continued)(continued)

Original ideas:1. Design reflects problem structure2. Begin with model of the real-world

structure diagrams patterns (anticipated later work on patterns

in OOAD)3. Constructive (not top-down)

Composition of models4. Object-based (not functional)

Note: See Appendix 1 & 2 for remarks on design method and methodology and for critical appraisal of JSP

Page 12: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Appendix 2: About JSPAppendix 2: About JSP JSP was arguably the best program design method during

the 1970’s and 1980’s. – The UK Government chose JSP as the national program

design standard in 1974.[1] – A 1978 survey of methods concluded that JSP “is closer to a

true methodology than any of the other design methodologies currently available…it is repeatable, teachable, reliable, and results in a program structure which is an excellent model of reality.”[2]

– In 1987, ACM’s Literate Programmer column concluded that JSP leads “apparently automatically to the best structure for the program.”[3]

JSP remains a sound method for designing the class of simple programs that read and produce serial data streams.

Page 13: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Appendix 3: Method versus Appendix 3: Method versus methodologymethodology

1. The distinction between method and methodology is often blurred. According to Jackson, a method is a way of doing something, whereas a methodology discusses the principles of one or more methods.

2. Underlying Jackson’s methods are the following methodological principles:[1] Easier decisions should be made before difficult decisions. Error-prone decisions should be deferred. Implicit decisions should be avoided. Error-prone decisions should be subjected at the earliest

possible moment to confirmation or refutation. Whenever possible, decisions should be independent of each

other (orthogonal).

Page 14: Introduction to Program Design Introduction to Program Design Using Jackson Structured Programming (JSP) and Jackson Workbench

Appendix 4: Jackson WorkbenchAppendix 4: Jackson Workbench

Jackson Workbench is a CASE tool for JSP and JSD– Keyword Computer Services Limited. 2002. Version 2.04.

Contact: [email protected] or [email protected] or +44 1494 870427

Structure Editor– intuitive editing via “hot spot” images that appear at

different locations on a tree structure diagram indicating an operation that can be performed at that point simply by left-clicking

Generates code (C++, Java, Visual BASIC, COBOL) and documentation

Under development: – JSP works well; JSD not complete