1 CSCD 326 Data Structures I Software Design. 2 The Software Life Cycle 1. Specification 2. Design 3. Risk Analysis 4. Verification 5. Coding 6. Testing.

Slides:



Advertisements
Similar presentations
Configuration management
Advertisements

COMPSCI 105 S Principles of Computer Science 12 Abstract Data Type.
Software Design. The Software Challenge In industry, a software product is expected to be used for an extended period of time by someone who did not write.
Software Engineering and Design Principles Chapter 1.
Fall 2007CS 225 Introduction to Software Design Chapter 1.
Design The goal is to design a modular solution, using the techniques of: Decomposition Abstraction Encapsulation In Object Oriented Programming this is.
Overview. Why data structures is a key course Main points from syllabus Survey Warmup program And now to get started...
© 2006 Pearson Addison-Wesley. All rights reserved4-1 Chapter 4 Data Abstraction: The Walls.
Introduction to Software Design Chapter 1. Chapter 1: Introduction to Software Design2 Chapter Objectives To become familiar with the software challenge.
Computers: Tools for an Information Age
Department of Computer Science University of Maryland, College Park
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
1 CMSC 132: Object-Oriented Programming II Nelson Padua-Perez William Pugh Department of Computer Science University of Maryland, College Park.
Chapter 1 Principles of Programming and Software Engineering.
© 2006 Pearson Addison-Wesley. All rights reserved4-1 Chapter 4 Data Abstraction: The Walls.
Chapter 1 Program Design
Data Abstraction: The Walls
1 ES 314 Advanced Programming Lec 2 Sept 3 Goals: Complete the discussion of problem Review of C++ Object-oriented design Arrays and pointers.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
Introduction to Software Design Chapter 1. Chapter 1: Introduction to Software Design2 Chapter Objectives To become familiar with the software challenge.
Copyright © 2009 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Java Software Solutions Foundations of Program Design Sixth Edition by Lewis.
Data Structures and Programming.  John Edgar2.
Introduction To System Analysis and design
Testing. Definition From the dictionary- the means by which the presence, quality, or genuineness of anything is determined; a means of trial. For software.
1 Shawlands Academy Higher Computing Software Development Unit.
Comp 245 Data Structures Software Engineering. What is Software Engineering? Most students obtain the problem and immediately start coding the solution.
Introduction to Object-oriented programming and software development Lecture 1.
Simple Program Design Third Edition A Step-by-Step Approach
Chapter 3 Introduction to Collections – Stacks Modified
Introduction Ellen Walker CPSC 201 Data Structures Hiram College.
Introduction CS 3358 Data Structures. What is Computer Science? Computer Science is the study of algorithms, including their  Formal and mathematical.
Introduction to Software Design Chapter 1. Chapter Objectives  To become familiar with the software challenge and the software life cycle  To understand.
1 The Software Development Process  Systems analysis  Systems design  Implementation  Testing  Documentation  Evaluation  Maintenance.
Chapter 9 Moving to Design
BY Lecturer: Aisha Dawood.  an algorithm is any well-defined computational procedure that takes some value, or set of values, as input and produces.
SE: CHAPTER 7 Writing The Program
1 Systems Analysis and Design in a Changing World, Thursday, January 18, 2007.
1 Life Cycle of Software Specification Design –Risk Analysis –Verification Coding Testing –Refining –Production Maintenance.
Introduction CS 3358 Data Structures. What is Computer Science? Computer Science is the study of algorithms, including their  Formal and mathematical.
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.
Chapter 7 Software Engineering Introduction to CS 1 st Semester, 2015 Sanghyun Park.
Software Engineering Chapter 3 CPSC Pascal Brent M. Dingle Texas A&M University.
An Object-Oriented Approach to Programming Logic and Design Fourth Edition Chapter 6 Using Methods.
Chapter 1 Program design Objectives To describe the steps in the program development process To introduce the current program design methodology To introduce.
The Programming Process Define the problem* Make or buy software? Design the program * Code (write) the program Test (debug) the program Document the.
CS Data Structures I Chapter 2 Principles of Programming & Software Engineering.
Dale Roberts Object Oriented Programming using Java - Introduction Dale Roberts, Lecturer Computer Science, IUPUI Department.
The basics of the programming process The development of programming languages to improve software development Programming languages that the average user.
The Software Development Process
ECSE Software Engineering 1I HO 4 © HY 2012 Lecture 4 Formal Methods A Library System Specification (Continued) From Specification to Design.
Chapter 3 Top-Down Design with Functions Part II J. H. Wang ( 王正豪 ), Ph. D. Assistant Professor Dept. Computer Science and Information Engineering National.
Data Structures Using C++ 2E
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
Chapter 3 Collections. Objectives  Define the concepts and terminology related to collections  Explore the basic structures of the Java Collections.
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
CSI 1340 Introduction to Computer Science II Chapter 1 Software Engineering Principles.
Data Design and Implementation. Definitions Atomic or primitive type A data type whose elements are single, non-decomposable data items Composite type.
(1) ICS 313: Programming Language Theory Chapter 11: Abstract Data Types (Data Abstraction)
Chapter 1 Data Abstraction: The Walls CS Data Structures Mehmet H Gunes Modified from authors’ slides.
CS Data Structures I Chapter 2 Principles of Programming & Software Engineering.
1 The Software Development Process ► Systems analysis ► Systems design ► Implementation ► Testing ► Documentation ► Evaluation ► Maintenance.
Chapter 2 Principles of Programming and Software Engineering.
Principles of Programming. Achieving an Object-Oriented Design  Abstraction and Information Hiding  Object-Oriented Design  Functional Decomposition.
Program Design. Simple Program Design, Fourth Edition Chapter 1 2 Objectives In this chapter you will be able to: Describe the steps in the program development.
PROGRAMMING FUNDAMENTALS INTRODUCTION TO PROGRAMMING. Computer Programming Concepts. Flowchart. Structured Programming Design. Implementation Documentation.
Principles of Programming & Software Engineering
Data Abstraction: The Walls
Data Abstraction: The Walls
Principles of Programming and Software Engineering
About the Presentations
Presentation transcript:

1 CSCD 326 Data Structures I Software Design

2 The Software Life Cycle 1. Specification 2. Design 3. Risk Analysis 4. Verification 5. Coding 6. Testing 7. Refining 8. Production 9. Maintainence

3 1. Specification Determine needs of program users. Involves communication with non-programmers to determine needs in detail. Must explain all necessary aspects of the program to programmers. May involve construction of a prototype program to get more details from users.

4 2. Design Generate an outline of the problem solution. Requires breaking the entire problem down into small manageable parts - modules. Modules are self-contained units of code. Modules should be loosely coupled except for the inter-module communication mechanism -the module interface. Must include specification of not only module purpose and interface but also of how data flow will happen between modules.

5 2. Design (con't) One or more program modules may already have been implemented. The Java Application Programmer's Interface (API) contains many class libraries of already implemented modules. Programmers do not have access to the source code for these modules but documentation explains the interface for each module.

6 3. Risk Analysis Risks are primarily business related but can be personal as well. Example: If a piece of software is not ready in time the company may lose the market to a competitor. Not an important issue for this course.

7 4. Verification Formal theoretical methods for proving algorithm correctness. Assertions - a statement about conditions at a particular point of a algorithm. Invariants - a condition that is always true at a particular point in an algorithm. Loop Invariant - a condition that is always true before and after each iteration of a loop. Algorithm proving techniques are very similar to inductive proofs.

8 5. Coding Translation of the design specification into a particular programming language. A minor and sometimes automated part of the entire cycle in industry. Programming language knowledge is taken for granted at upper levels of computer science.

9 6. Testing Often involves testing individual methods of the solution using dummy programs that call the methods with appropriate data. Eventually involves testing of the entire program.

10 7. Refining the Solution Usually involves increasing the "robustness" of a solution. Often simplifying assumptions are made in the design process that must be removed from final versions. Example: assume that the input will be be integers between 0 and During this step code would be inserted to actually test the input values.

11 8. Production Distribution of the software to user's and installation on their machines.

12 9. Maintainence Two components: Users detect errors not discovered during testing - very common in complex programs. These errors must be fixed for subsequent releases. Enhancing software by adding new features.

13 Documentation All levels of the software life cycle depend on good documentation. Especially important when software is developed in a group environment.

14 Modular Design Concepts Key techniques for use in achieving a modular design are: Abstraction and Information Hiding Object-Oriented Design Top Down Design

15 Abstraction Abstraction separates the purpose of a module from its implementation.

16 Procedural Abstraction Procedural Abstraction is the process of separating the purpose of a method from its implementation. Once written the method can be used without any knowledge of how it is implemented - only need to know the parameters. Example: nearly all methods in the entire Java API. Essential in team projects.

17 Data Abstraction Given a collection of data and a set of operations that can be performed on the data. Data Abstraction focuses on what the operations do rather than how they are implemented.

18 Abstract Data Types ADT - a collection of data along with a set of operations that can be performed on that data. No details about how the data is stored or how the operations on the data are implemented. An ADT is a general description of the design of a module with no details. The interface of a module can be a part of an ADT.

19 Abstract Data Types Data Structure - the implementation of an ADT in a programming language. The details of data storage and how operations are performed are crucial parts of a data structure.

20 ADT List Any List in general will allow the following operations: Create an empty list Destroy a list Determine whether a list is empty Determine the number of items in a list Insert an item at a given position in the list Delete the item at a given position in the list Look at (retrieve or get) the item at a given position in the list

21 Information Hiding Information hiding After a module is implemented, a user of the module does not need to know how the module stores data or performs operations. Module's interface The means by which the user gets the module to perform its operation(s). The only information that is not hidden from the module user. Referred to the by the textbook as a "wall".

22 Information Hiding Implementation Accessibility modifiers: Public view of a module - consists of all public data elements and methods -defines the module's interface. Private or protected data elements and methods - define the parts of the module's data storage or operations that users will not be allowed to see.

23 Object-Oriented Design Three elements to OOD: Encapsulation - combining data and operations within one object. Inheritance - objects can inherit data and/or methods from other objects. Polymorphism - objects can determine operations at execution time. Every object knows its "true" type regardless of type casting

24 Top-Down Design Focused on algorithm design. A method for designing the way object operations will be performed. Provides a tool for moving from ADT's which generally use procedural abstraction to an implementation in a programming language. Goal is to break a large problem into a set of smaller problems that are more easily solved.

25 Top-Down Design Structure Charts:

26 Pseudocode A tool for moving from a structure chart to a specific implementation. Pseudocode can vary from written descriptions to compilable code. It is usually code-like but ignores many code details needed by compilers. Successive Refinement: Start with a very general description of what the algorithm will do Work toward more code-like details.

27 Successive Refinement Example (1) Early pseudocode for the get operation from ADT List: get (index) // returns the item at position index of a list // if 0 <= index < size the list is left unchanged // Throws an exception if index is out of range Assuming that the implementation of List will store data in an array - more specific get pseudocode.

28 Successive Refinement Example (2) Assuming that the implementation of List will store data in an array - more specific get pseudocode. get (index) { if( index > alist.size ) throw out of range exception return alist.array[index] } The final refinement involves writing a Java class to implement the list ADT