1 Muhammed Al-MulhemVisual Languages - 2 Visual Programming Languages ICS 539 Diagrams ICS Department KFUPM Sept. 1, 2007.

Slides:



Advertisements
Similar presentations
Steps of a Design Brief V Design Brief  Problem, identification, and definition Establish a clear idea of what is to be accomplished. Identify.
Advertisements

Systems Analysis and Design in a Changing World, Fifth Edition
Chapter 6 Path Testing Software Testing
Chapter 3: Modularization
Chapter 2: Modularization
Describing Process Specifications and Structured Decisions Systems Analysis and Design, 7e Kendall & Kendall 9 © 2008 Pearson Prentice Hall.
Repetition Control Structures School of Business Eastern Illinois University © Abdou Illia, Spring 2003 (Week 9, Friday 3/07/2003)
SWT - Diagrammatics Lecture 2/4 - Diagramming in Computer Science 27-April-2000.
Traditional Approach to Design
UNIT 2. Introduction to Computer Programming
Chapter 10 The Traditional Approach to Design
Introduction to Programming
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
زبانهای برنامه سازی برنامه سازی پیشرفته ارائه دهنده دکتر سيد امين حسيني E.mail: Home page:
Computer Programming Rattapoom Waranusast Department of Electrical and Computer Engineering Faculty of Engineering, Naresuan University.
Fundamentals of Algorithms MCS - 2 Lecture # 4
Chapter 9: The Traditional Approach to Design Chapter 10 Systems Analysis and Design in a Changing World, 3 rd Edition.
Chapter 2- Visual Basic Schneider
LECTURER: DR MASRI AYOB Dr. Masri Ayob: TK2633 TK2633: MICROPROCESSOR & INTERFACING Structured Assembly Language Programming.
Chapter 2: Developing a Program Extended and Concise Prelude to Programming Concepts and Design Copyright © 2003 Scott/Jones, Inc.. All rights reserved.
COBOL for the 21 st Century Stern, Stern, Ley Chapter 1 INTRODUCTION TO STRUCTURED PROGRAM DESIGN IN COBOL.
Chapter 1 Program Design
Developing logic (Examples on algorithm and flowchart)
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
The Program Design Phases
PRE-PROGRAMMING PHASE
Introduction to Programming Lecture Number:. What is Programming Programming is to instruct the computer on what it has to do in a language that the computer.
Structured COBOL Programming, Stern & Stern, 9th edition
Extended Prelude to Programming Concepts & Design, 3/e by Stewart Venit and Elizabeth Drake Chapter 2: Developing a Program.
Flow Charting. Goals Create Algorithms using Flow Charting procedures. Distinguish between Flow Charting and Pseudocode. Top-Down Design Bottom-up Design.
Design the program Create a detailed description of program –Use charts or ordinary language (pseudocode) Identify algorithms needed –Algorithm: a step-by-step.
First Steps in Modularization Simple Program Design Third Edition A Step-by-Step Approach 8.
1 Introduction to Flowcharting. 2 Writing a program Defining the problem –Write down what the program will do Planning –Write down the steps, draw a flowchart.
10 ITK261 The traditional approach to design Reading: Chapter 10 Oct 9, 11.
10 The traditional approach to design Hisham Alkhawar.
Describe the Program Development Cycle. Program Development Cycle The program development cycle is a series of steps programmers use to build computer.
Extended Prelude to Programming Concepts & Design, 3/e by Stewart Venit and Elizabeth Drake Chapter 2: Flowcharts.
© 2011 Pearson Addison-Wesley. All rights reserved. Addison Wesley is an imprint of Stewart Venit ~ Elizabeth Drake Developing a Program.
Problem Solving Techniques. Compiler n Is a computer program whose purpose is to take a description of a desired program coded in a programming language.
INTRODUCTION TO COMPUTING CHAPTER NO. 04. Programming Languages Program Algorithms and Pseudo Code Properties and Advantages of Algorithms Flowchart (Symbols.
Flowcharts.
Activity diagrams. Introduction ● Activity diagrams are a behavioural model that represent the dynamics of the system. ● An activity diagram is essentially.
Flowcharting A Quality Improvement Tool. Quality = Inspection Statistical methods assisted in prevention of defects – The need for inspection declined.
Copyright © 2013 Curt Hill UML Unified Modeling Language.
First Steps in Modularization. Simple Program Design, Fourth Edition Chapter 8 2 Objectives In this chapter you will be able to: Introduce modularization.
CCSB223/SAD/CHAPTER131 Chapter 13 Designing the System Internals.
First Steps in Modularization. Simple Program Design, Fourth Edition Chapter 8 2 Objectives In this chapter you will be able to: Introduce modularization.
PROGRAM DEVELOPMENT CYCLE. Problem Statement: Problem Statement help diagnose the situation so that your focus is on the problem, helpful tools at this.
`. Lecture Overview Structure Programming Basic Control of Structure Programming Selection Logical Operations Iteration Flowchart.
Fundamentals of Algorithms MCS - 2 Lecture # 5. Representation of Algorithms (continued) Flowcharts.
Structured Programming (4 Credits)
Sahar Mosleh California State University San MarcosPage 1 Finite State Machine.
Systems Design.  Application Design  User Interface Design  Database Design.
Problem-solving with Computers. 2Outline  Computer System  5 Steps for producing a computer program  Structured program and programming  3 types of.
Lecture 3: Developing Procedural Thinking (How to think like a programmer) B Burlingame 16 Feb 2016.
Alexandria University Faculty of Science Computer Science Department Introduction to Programming C++
Evolution of C and C++ n C was developed by Dennis Ritchie at Bell Labs (early 1970s) as a systems programming language n C later evolved into a general-purpose.
FLOW CHARTS IN PROCESS DESCRIPTION FRANK CHINGARANDE.
Systems Analysis and Design in a Changing World, Fourth Edition
Introduction To Flowcharting
Numbering System TODAY AND TOMORROW 11th Edition
2.0 Problem Solving PROGRAM DESIGN
Unit# 9: Computer Program Development
Chapter 9 Structuring System Requirements: Logic Modeling
Structure Charts Agenda: What are Structure Charts
Chapter 2- Visual Basic Schneider
Data and Flowcharts Session
Chapter 9 Structuring System Requirements: Logic Modeling
Basic Concepts of Algorithm
Structure Charts.
Presentation transcript:

1 Muhammed Al-MulhemVisual Languages - 2 Visual Programming Languages ICS 539 Diagrams ICS Department KFUPM Sept. 1, 2007

2 Muhammed Al-MulhemVisual Languages - 2 Diagrams There are many forms of diagrams to represent programs. Flowcharts are the first and best known diagrams of software. In 1969, researchers at Rand created a language based on Flowcharts [Ellis, 1996] In the early 1970s, researchers at Xerox Parc created the first visual programming environment; namely the Smalltalk environment [Goldberg, 1983]

3 Muhammed Al-MulhemVisual Languages - 2 Flowchart Flowcharts are topological, graph-based constructions that often are filled in with program text. The control logic of the program is shown through simple branches and loops. Consider the following example:

4 Muhammed Al-MulhemVisual Languages - 2 Start X > 0 Print “yes” Print “no” Stop N N Y Y

5 Muhammed Al-MulhemVisual Languages - 2 In some software methodologies, flowcharts are generated by analysts as specification to programmers, who then converts charts into source code. In other cases, flowcharts are generated after the fact, either by hand or automatically. The usefulness of flowcharts has been debated.

6 Muhammed Al-MulhemVisual Languages - 2 Flowcharts for large systems tend to get large and messy. In order to work around this problem, extensions to flow charts allow charts to be terminated and resumed on different pages. Still a program with many loops requires return arrows that may span many pages.

7 Muhammed Al-MulhemVisual Languages - 2

8 Structure Diagrams A structure diagram is a hierarchical, modular breakdown of a program. Between levels on the tree there are links, with symbols to indicate the sort of information that is being passed back and forth. These structures are represented either as trees or as directed acyclic graphs (DAGs). For example look at the next figure.

9 Muhammed Al-MulhemVisual Languages - 2 Calculate Payroll Get Employee Record Calculate Net Pay Print Pay Check Calculate Deduction Calculate Gross Pay Employee Record Pay and Date Employee Record Net Pay

10 Muhammed Al-MulhemVisual Languages - 2 The structure chart is usually the end result of the activity known as structured analysis, in which the functions of a system are partitioned in a top-down manner. Note the diagrams are purely topological, with labeled edges and nodes. Note also the difficulty apparent in labeling the edges of such a DAG, even on a small example such as the one shown.

11 Muhammed Al-MulhemVisual Languages - 2 Nassi-Shneiderman Diagrams In this sort of diagram, hierarchy is shown using the conventions of enclosure and adjacency. Like the others, there is a limit on what they can represent. The figure below shows an example.

12 Muhammed Al-MulhemVisual Languages - 2 TRUE FALSE WHILE L1 WHILE L2 IF L1 IF L2 TRUE FALSE S1 S2 S3 S7 S8 S4S5 S6

13 Muhammed Al-MulhemVisual Languages - 2

14 Muhammed Al-MulhemVisual Languages - 2 Recursion Portrayal Recursion is not an easy concept to teach or understand. Recursion is represented graphically using containment. Look at the next figure.

15 Muhammed Al-MulhemVisual Languages - 2 FAC(5) 1 5*FAC(4) 4*FAC(3) 3*FAC(2) 2*FAC(1) 1*FAC(0)

16 Muhammed Al-MulhemVisual Languages - 2 Data Flow Graphs A data flow graph is a directed graph consisting of edges, which represent data flow, and nodes, which represent operations. Tokens flow through the graph- when a node has tokens ready on all its incoming edges it will execute. When the node has executed, it puts tokens on its output edges.

17 Muhammed Al-MulhemVisual Languages - 2 There is no predetermined sequence to the execution of data flow graph - the data derives the order of execution. Dataflow graphs are often used in conjunction with dataflow machines, computers built to process tokens in parallel. An example is shown next.

18 Muhammed Al-MulhemVisual Languages - 2

19 Muhammed Al-MulhemVisual Languages - 2 Software Level Charts At a higher level, the functions of a system can be represented in layer diagram. For example the next diagram represents a system where an application can access Motif, X-Lib, a DB API, and a Unix API. Like the others, this only work for simple systems.

20 Muhammed Al-MulhemVisual Languages - 2

21 Muhammed Al-MulhemVisual Languages - 2 State Transition Diagrams Originated from the study of finite automata. They are used for modeling a variety of event-based computer science domains, including: –Parsing –User Interface –Circuit Design Edges represent transitions from state to state that occur as a result of an input symbol being read. Start and terminating nodes look different.

22 Muhammed Al-MulhemVisual Languages - 2 A A A A A B A B B B B B

23 Muhammed Al-MulhemVisual Languages - 2 Cell and Arrow Diagrams Cell and arrow diagrams are used to represent data structures. Most often these diagrams are used for teaching programming or for program documentation. The diagrams themselves do not contain enough information to execute from. An example is shown next.

24 Muhammed Al-MulhemVisual Languages - 2 ((1 2) 3 4) 12 34