Documente Academic
Documente Profesional
Documente Cultură
S. Ramanathan
What is a System?
Set of interrelated elements with a common goal (e.g) business system, political system
A system is defined by
Goals Inputs and outputs Conversion process Feedback and control Communication with other subsystems Environment Boundaries
ENVIRONMENT
BOUNDARY
INPUT
PROCESS
OUTPUT
Control / Feedback
Classification of Systems
Natural (rivers, lakes) or manmade (Computer) Closed (does not interact with outside world) or Open (interacts with external environment)
System Analysis
For proper understanding of the existing system and designing new system Helps in understanding interrelationships between the subsystems
What is Software?
1. Instructions (programs) that when executed produce desired features, functions and performance 2. Data structures that enable the programs to adequately manipulate information 3. Documents that describe the operation and use of the programs
Definition
Development
Support
System Definition
Focus on what
What problem is proposed to be solved? What functions are desired in the solution? What data to be processed for this? What level of performance is desired? What system behaviour can be expected? What interfaces to be established? What are the design constraints? What validation criteria are required? Addressed in Feasibility study and Analysis phases
System Development
Focus on how
How to structure data How to implement the desired functions How to implement procedural details How to establish interfaces How to translate the design into a program How to perform testing Addressed in design, program construction and testing phases
System Support
Focus on change Error correction Adaptation for new environments Enhancements
SDLC
Identifies all the activities required for Software development Establishes a precedence ordering among the different activities Divides life cycle into phases
Umbrella activities
Project tracking and control
Budgeting Reporting Review signoffs
Quality assurance Configuration management Documentation Change Management Reusability management Measurement Risk management
Roles in a Project
Steering Committee Project Manager Project Leader Systems Analyst Module Leader Programmers Data Base Administrator Quality Assurance Testers Domain Specialist Technology Specialist Documentation Specialist
Feasibility Study
Software Scope
functional requirements data to be processed control requirements performance requirements constraints interfaces reliability requirements
Feasibility
Technology: Is the project technically feasible? Is it within the state of the art? Finance: Can the software be developed at a cost that the client or market can afford? Economic: Do the benefits exceed cost? Time: Will the project / product be delivered in time to meet the customer needs / competition? Resources: Does the organization have the resources to complete the project? Operational: Can the input data be collected? Are the outputs usable? Behavioural: What impact will the system have on the quality of working life of users? Legal: Does the project comply with the local legal requirements?
Business Case
Detailed definition of problem Analysis of potential solutions Potential cost, risk, benefits and issues for each option Recommended solution and generic plan Justification based on cost-benefit analysis Time impact on cost, benefit
Terms of Reference
Vision Objectives Scope Deliverables Organization structure roles and responsibilities Summarized plan of activities Resource requirements Fund requirements Risks issues Assumptions constraints
Requirements Elicitation
Ask the user
What are the objectives of the system What needs to be accomplished How does the system fit into the needs of the business How is the system proposed to be used
Requirements Negotiation
Recognize that you are not in competition with the user Decide on what you want to achieve and chalk out a strategy towards it. Listen: Dont cut short the user on the basis of some assumptions Focus on other partys interest Dont take positions Dont let it go personal: Focus on the problem Be creative: Think out of the box, particularly at stalemate situations Be ready to commit, once a decision is reached
Requirements Analysis
Categorize the requirements identified in the elicitation into related subsets Explore each requirement in relation to others Examine requirements for consistency, omissions and ambiguity Rank requirements based on user needs
Requirements Specification
Introduction
Goals and objectives of the software Context of the computer-based system.
Information Description:
Problem description Information content, flow and structure Hardware,software, human interfaces for external system elements and internal software functions.
Functional Description:
Diagrammatic representation of functions Processing narrative for each function. Interplay among functions Design constraints
Requirements Validation
by both the software developer and the customer. First review for
completeness consistency accuracy.
Detailed review of
Informational functional and behavioural domains
Requirements Management
Activities that help the project team to identify, control and track requirements and changes to requirements Create traceability tables:
Features traceability table:how requirements relate to user observable features Source traceability table: source of each requirement Dependency traceability table: relationship between requirements Subsystem traceability table: categorization of requirements Interface traceability table: relationship of requirements to internal and external interfaces
What is modeling?
A model is a simplification of reality. It provides a blue print of a system. A good model includes elements that have broad effects and omit elements that are not relevant to system.
Principles of Modeling
1. Every model may be expressed in different levels of precision 2. The best models are connected to reality 3. No single model is sufficient
Domain Analysis
Understand the domain
Literature survey Existing applications Customer surveys Expert advice
Dont go by just current requirements; anticipate future requirements Identify recurring patterns reusable components
Actors
An actor represents a coherent set of roles that users of use case play when interacting with the use cases.
Actors are not part of the system though they are used in a system. They lie outside the system.
Cellular network
User
User scheduler
Cellular telephone
Customer
retail institution
Reconcile transactions
Establish the context of the system by identifying the actors that surroun For each actor consider the behavior that each expects or requires the system to provide
Name these common behaviors as use cases Factor common behavior into new use case that are used by others;
Factor variant behavior into new use cases that extend more main line
Model these use cases, actor, and their relationships in a use case dia
Adorn these use cases with notes that assert nonfunctional requireme
When it
Is focused on communication one aspect of a systems static use case Contains only those use cases and actors that are essential to understand that aspect Provides details consistent with its level of abstraction; you should expose only those adornments that are essential to understanding. Is not so minimalist (simple) as to misinform the reader about semantics that are important.
Give it a name that communicates its purpose Lay out its elements to minimize lines that cross Organize elements spatially so that behaviors and roles that are semantically close are laid out physically close
Use notes and color as visual cues to draw attention to important featu of your diagram Try not to show too many kinds of relationships. If you have any complicated relationships, take these elements to another diagram.
Behavioral
State diagrams Sequence diagrams
Static
E-R Diagrams Class diagrams
Flow-oriented
Data flow diagrams Process specifications
Data Store
Process
Data Store
DFDs - Rules
Naming and Numbering of
Entities Processes Data Stores
Direction and Naming of Flows Process explosion numbering of sub-processes Process specification
Flow Chart
Repetition Selection
Sequence
Decision Tree
6 or more Book Store Less than 6 Discount Policy 50 or more Libraries / individuals 20 - 49 6 - 19 Less than 6 15% 10% 5% Nil 25% Nil
Structured English:
If transaction is 'BILL' then update bill in the Accounts master file update total bill amount in the Control file If transaction is 'PAYMENT' then update receipt in the Accounts master file update total receipt amount in the Control file
Static Modelling
Description of applications in terms of
Entities / objects Attributes Relationships
Cardinality
One-to-One One-to-Many Many-to-many
Modality
Modality of a relationship is 0, if there is no explicit need for the relationship to occur 1, if the occurrence of relationship is mandatory
Object-Oriented Concepts
Class: encapsulates the data and procedures required to describe the content and behavior of some real world entity; Object: instance of a class Attribute: data value(s) of a class Operation: behavior of a class Subclass: specialization of a superclass Superclass / Base class: generalization of a set of classes
Identification of Classes
External entities Things Events Roles Organizational units Places Structures
Specifying Attributes
What data items fully define the class? May be elementary or composite Composite data items are represented in terms of elementary data items:
item code = source code+group code+subgroup code+serial no.
Defining Operations
Operations define the behavior of an object Broad categories
That manipulate data in some way That perform a computation That inquire about the state of an object That monitor an object for the occurrence of a controlling event
Scenario-based Modeling
Writing use-cases
Scenario
Outcome: Insurance company pays claim
1. Claimant submits claim with substantiating data. 2. Insurance company verifies claimant owns a valid policy (failure here probably means goal failure) 3. Insurance company assigns agent to examine case. 4. Agent verifies all details are within policy guidelines. (an interaction between the agent and secondary actors) 5. Insurance company pays claimant (implies all preceding goals managed to pass)
Extensions
1a. Submitted data is incomplete:
1a1. Insurance company requests missing information 1a2. Claimant supplies missing information
Variations
1. Claimant is
a. a person b. another insurance company c. the government
5. Payment is
a. by check b. by interbank transfer c. by automatic prepayment of next installment d. by creation and payment of another policy
Activity Diagram
Graphical representation of the interaction within a specified scenario
Conduct interviews
Make list of classes, functions Make list of constraints Elicit requirements Formal prioritization? Y Y Use QFD N Informal method
Create use-cases
Create scenarios
Create template
L ge r d ta o rro e ils
S a E p y eD ta c n m lo e e ils
s c e try uh n
[D ta a eF ilu a b s a re
S n E p y eD ta e d m lo e e ils
[D ta a eF tc S c e s a b s e h uc s
V rifyE p y eD ta e m lo e e ils
[V lidE p y e a m lo e
S v A n a c In rm tio a e tte d n e fo a n
[S o g e s n l h w re n ig a
E it B e m ep
So s n l h w ig a
Swimlane Diagrams
Variation of Activity Diagram Additional information on which actor is involved in which function
Behavioral Model
For applications driven by events Time and performance are critical
State Diagram
Emphasizes the event ordered behaviour of an object
STAT ES
Key press
Idle
finished name
Sequence Diagram
Emphasizes the time ordering of message Shows a set of objects and message sent by and received by those objects These objects may be instances of classes, collaborations, components and nodes
Object Lifeline
1: PerformResponsibility
Reflexive Message
Message
Focus of Control
Design Engineering
Design Model
Encapsulation
Abstraction
Modularity
Hierarchy
What is Abstraction?
Any model that includes the most important, essential, or distinguishing aspects of something while suppressing or ignoring less important, immaterial, or diversionary details. The result of removing distinctions so as to emphasize commonalties The essential characteristics of an entity that distinguish it from all other kinds of entities. Defines a boundary relative to the perspective of the viewer Is not a concrete manifestation, denotes the ideal essence of something
ABSTRACTION
An Abstraction is a simplification or mental model that helps a person understand something at a appropriate level. This implies that different people would build radically different abstractions for the same concept.
What is Encapsulation?
Hide implementation from clients
Clients depend on interface
What is Modularity?
The breaking up of something complex into manageable pieces
Order Entry
Order Fulfillment
Billing
What is Hierarchy?
Levels of abstraction
Increasing abstraction
Asset
BankAccount
Security
RealEstate
Savings
Checking
Stock
Bond
Decreasing abstraction
Classes at the same level of the hierarchy should be at the same level of abstraction
Conceptual Modelling
Description of applications in terms of
Entities / objects Attributes Relationships
Cardinality
One-to-One One-to-Many Many-to-many
Data Modelling
Translate conceptual model into a data model (eg) deriving a relational data model from entity relationship model Tool: Normalization
Normalization
Record design technique to avoid some update anomalies First Normal Form: no repeating groups Second Normal Form: all non-key data items should depend on key only Third Normal Form: no non-key item should depend on another non-key item
Architectural Design
Major modules Function and Scope of each module Interface features of each module Modules that each module can call directly or indirectly Data received from / sent to / modified in other modules Tool: Functional Decomposition
Functional Decomposition
Module Couple
Design Principles
Do not confine to a single pre-judged solution; consider alternatives Traceability to analysis Suitability to the structure of the problem Easily identifiable relationship of software functions to user function Uniformity in style and format Modularity
Modularity
Module is a manageable unit performing a well-defined task Modules contain instructions and data for performing a particular task. Modules have well-defined interfaces. Advantages: Maintainability, Reusability
Measures of Modularity
Cohesion: how well the elements fit together in a module Coupling: strength of interconnection between modules Desired: High Cohesion and Low Coupling
Design Issues
System response time length and variability User help facilities
Availability for all / selected functions Request for help menu, function key Representation of help separate window Return to normal interaction
Command labeling
Command options control sequence, function key Ease of remembering commands Facility of customization by the user Self-explanatory labels Consistency of submenus with main menu
Internationalization
Software Testing
Testing Strategy
Program Design
Unit Testing
Process of testing individual units of software in isolation of other parts of the program. This test is conducted to test
Functionality: should produce expected result for a given input value Performance: response time, execution time, throughput, memory utilization, traffic in communication channels Stress: Checking the limits Structure: processing logic
Antibugging
Integration Testing
If they all work individually, they will work, when we put them together and the whole product will also work False; Interfacing can create problems Hence overall product is checked
Integration Testing
Systematic technique for assembling software while at the same time conducting tests to uncover errors associated with interfacing Tests for
Interface integrity Functional validity Performance
Types
Bottom-Up Top-Down
Bottom-Up Integration
Assembly and testing with atomic modules Easier to implement, because at the time of each module testing, tested subordinate modules are available Testing of major decision / control points is deferred to a later period
Top-Down Integration
Integration starting with main control module and moving down the hierarchy, integrating subordinate modules Adv: major control / decision point are tested first and details are addressed later Disadv: Testing higher levels without the process outputs of lower levels poses difficulty
Regression Testing
The process of rerunning a portion of software to check that changes have not introduced new errors Obj: to ensure that all aspects of an application system remain functional after testing Should be conducted after a predetermined number of changes in the application system Significant during maintenance too
Smoke Testing
For time-critical projects Steps
Develop builds (integrated software engineering components) Design tests that will stop build from properly performing its function focus on show stopper errors Continuous integration of builds and daily test of the integrated build
Benefits
Integration risk is minimized by daily testing Quality of end product is improved Error diagnostics and correction simplified Progress easier to access
Validation Testing
Step at the end of Integration Testing Testing software functions in a manner that can be reasonably expected by the custome As specified in the Validation criteria in Software Requirements Specifications
Stress Testing
Designed to determine if the system can function when subjected to large volumes Areas stressed: input transactions, internal tables, disk space, output, communications, computer capacity Obj: to simulate production environment Useful in situations, where volume of transactions is unpredictable such as in on-line systems Time and resource consuming
Execution Testing
Designed to determine whether the system achieves the desired level of proficiency in production status Verifies response time, turn around time, design performance Can be tested in whole or part Can be performed early in the developmental process
Recovery Testing
Ability to restart operations after the loss of application integrity Ability to return to a point of known system integrity and reprocess transactions till the point of failure Obj: to test
Adequacy of back-up data Security of back-up storage Documentation of recovery procedures Staff knowledge of recovery procedures
Security Testing
Designed to determine the adequacy of protective procedures Tests for both physical and logical security Obj: To determine
adequacy of identification of risks Enforcement of access control In-house expertise in security testing The functioning of security measures
Debugging
Occurs as a consequence of testing
Challenges in Debugging
Cause may be in a remote location Temporary symptoms Caused by human error Non-synchronization of time Reproducibility may not be possible always Cause distributed across tasks
Debugging Tactics
Brute Force: Let the computer decide Memory Dumps Backtracking Cause elimination Automated Debugging
Debugging compilers Tracers Automatic test case generators Cross-reference mapping tools
Parameters of Quality
Correctness Integrity Functionality:
- Suitability - Accuracy - Interoperability - Compliance - Security
Usability
Understandability Learnability Operability
Maintainability
Traceability Changeability Stability Testability
Portability
Disadv: possibility of missing Does not ensure testing of all errors functional requirements Possibility of redundant testing Does not mimic real world situations
Equivalence Partitioning
Black Box Testing Method Process of methodically reducing the huge set of possible test cases into a much smaller, but equally effective, set
Always consider creating an equivalence partition that handles the default, empty, blank, null, zero o none conditions
Boundary Conditions
Situations at the edge of the planned operational limits of the software
Scenario-Based Testing
Concentrates on what the user does and not what the product Derived from use-cases
Formal Methods
Formal Methods
Formal methods allow a software engineer to create a specification that is more complete, consistent and unambiguous than those produced by conventional methods Uses tools such as symbol tables, sets etc.
Design Verification
The procedural design in each clear box is refined stepwise into programming constructs At each level of refinement, formal correctness verification is performed Advantages: Reduces verification to a finite process Verification through group analysis based on correctness theorem: more rigorous than program testing in conventional process: useful in mission-critical applications Results in near zero defect level by eliciting unanimous agreement from all team members on correctness Scalability: process of stepwise refinement and reduction to basic programming constructs the procedure valid irrespective of size More efficient than unit testing: testing functionality than paths
Certification
Specification of reliability (measured by meantime-to-failure MTTF) for each component Steps
Creation of usage scenarios Specification of usage profile Generation of test cases Execution of test cases; record and analysis of failure data Computation of reliability and certification
Component-Based Development
What is a Component?
A non-trivial near-independent and replaceable part of the system that fulfils a clear function
Questions to be Addressed
Is it possible to construct complex system using a catalog of reusable components? Will it be cost-efficient and time-effective? Are the additional costs involved in creating a generalized software worth the returns due to reuse? How do we store these components and make them available when necessary?
Steps in Component-Based Software Engineering Domain Analysis to be investigated Define the domain
Identify requirements Define analysis classes Identify candidate components:
Look for repeating patterns (of functions, data and behaviour) within the application Duplication of the component within the domain Possibility of parameterization Reusability with minor changes Decompose to achieve reusability
Y
Component available?
N
COTS available?
Y Y
Use Buy N
N Build
Remove
Component Adaptation
Component wrapping
Component Composition
Assembly of components Services for communication with other components Object Request Brokers (ORB) CORBA, COM, JavaBeans
Productivity
25% - 40% productivity improvement reported
Cost
component development costlier than porgram specific to application because additional requirements of cost of generality and repository maintenance Payoffs realized through reuse
Reengineering
What is Reengineering?
With time, the ability of software to support the business processes wanes Solution: Reengineer the software to add functionality, improve performance, reliability and maintainability
A BPR Model
Evolutionary process no start or end Activities
Business definition: goal identification within the context of four key drivers cost reduction, quality improvement, personnel development and empowerment Process identification: Identification of processes that are critical to achieving the business goals; ranking of these processes by importance or need for change Process evaluation: on the basis of cost, time, quality and performance Process specification and design: use-case preparation and redesign Prototyping: for the redesigned process for testing and refinement Refinement and instantiation: Refinement based on the feedback from the prototype and instantiation within the business system
Code restructure
Document restructure
Reverse Engineering
Categories of CASE
Upper CASE: Requirement definitions
Middle CASE: Design Screens and Reports Lower CASE: Code generation
Benefits of CASE
Integration of the activities of SDLC Automatic standardization Guaranteed consistency and quality Removal of monotony Self documentation Reduced cost Reduced time of development
Disadvantages of CASE
Training need High cost of tools
CASE Repository
Enterprise Information
Organizational structure Business analysis Information architecture
CASE database or repository is an integrated CASE environment containing the following data:
Application Design
Model diagrams Naming standards Integrity rules Entity / object definitions Data structures Process definitions Menu trees Performance criteria Screen definitions Report definitions Processing logic
CASE Repository
Construction
Source code Object code Change information
Testing
Test plan Test results Quality Metrics
Project Management
Project plan Work breakdown structure Estimation, schedules Problem reports Change requests, status reports Audit information
Documentation
System requirement specifications Design document User manuals