Formal Methods 1. Software Engineering and Formal Methods  Every software engineering methodology is based on a recommended development process  proceeding.

Slides:



Advertisements
Similar presentations
Introducing Formal Methods, Module 1, Version 1.1, Oct., Formal Specification and Analytical Verification L 5.
Advertisements

LIFE CYCLE MODELS FORMAL TRANSFORMATION
Software Processes Coherent sets of activities for specifying, designing, implementing and testing software systems.
Software system modeling
Requirement Analysis and Specification Mr. Manoj Kumar Kar.
CLEANROOM SOFTWARE ENGINEERING
©Ian Sommerville 2000Software Engineering. Chapter 22Slide 1 Chapter 22 Verification and Validation.
CS 355 – Programming Languages
Formal Methods in Software Engineering Credit Hours: 3+0 By: Qaisar Javaid Assistant Professor Formal Methods in Software Engineering1.
Lecture 12 Reengineering Computer-aided Software Engineering Cleanroom Software Engineering.
Copyright © 2006 Software Quality Research Laboratory DANSE Software Quality Assurance Tom Swain Software Quality Research Laboratory University of Tennessee.
Software Testing and Quality Assurance
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
Lecture 3: Requirements Modeling Intro Professor Aditya Ghose Director, Decision Systems Lab School of IT and Computer Science University of Wollongong.
©Ian Sommerville 2000Software Engineering, 6/e, Chapter 91 Formal Specification l Techniques for the unambiguous specification of software.
Verification and Validation
Describing Syntax and Semantics
School of Computer ScienceG53FSP Formal Specification1 Dr. Rong Qu Introduction to Formal Specification
Andy Moyer. Cleanroom Software Engineering  What is it?  Goals  Properties of Cleanroom  Cleanroom Technologies  Case Studies  Critiques.
Cleanroom Software Engineering Crystal Donald. Origins Developed by Dr. Harlan Mills in 1987 Developed by Dr. Harlan Mills in 1987 Name derived from hardware.
Software Verification and Validation (V&V) By Roger U. Fujii Presented by Donovan Faustino.
Software Integration and Documenting
Do we need theoretical computer science in software engineering curriculum: an experience from Uni Novi Sad Bansko, August 28, 2013.
Software Testing Verification and validation planning Software inspections Software Inspection vs. Testing Automated static analysis Cleanroom software.
CLEANROOM SOFTWARE ENGINEERING.
Requirements Expression and Modelling
Balancing Practices: Inspections, Testing, and Others JAXA scenario (formal method) Masa Katahira Japanese Space Agency.
Formal Methods CIS 376 Bruce R. Maxim UM-Dearborn.
Compositional IS Development Framework Application Domain Application Domain Pre-existing components, legacy systems Extended for CD (ontologies) OAD Methods.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 9 Slide 1 Formal Specification l Techniques for the unambiguous specification of software.
Verification and Validation Chapter 22 of Ian Sommerville’s Software Engineering.
Software Models (Cont.) 9/22/2015ICS 413 – Software Engineering1 -Component-based software engineering -Formal Development Model.
Mathematical Modeling and Formal Specification Languages CIS 376 Bruce R. Maxim UM-Dearborn.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
Introduction to Formal Methods Based on Jeannette M. Wing. A Specifier's Introduction to Formal Methods. IEEE Computer, 23(9):8-24, September,
Overview of Formal Methods. Topics Introduction and terminology FM and Software Engineering Applications of FM Propositional and Predicate Logic Program.
CS.436 Software Engineering By Ajarn..Sutapart Sappajak,METC,MSIT Chapter 13 Verification and validation Slide 1 1 Chapter 13 Verification and Validation.
WXGE6103 Software Engineering Process and Practice Formal Specification.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 22 Slide 1 Software Verification, Validation and Testing.
Requirements Engineering Methods for Requirements Engineering Lecture-30.
Formal Methods in Software Engineering
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Chapter 19 Verification and Validation.
Software Testing and Quality Assurance Software Quality Assurance 1.
Verification and Validation
Software Debugging, Testing, and Verification Presented by Chris Hundersmarck November 10, 2004 Dr. Bi’s SE516.
Anton Krbaťa Ján Budáč  Verification: "Are we building the product right ?„  Validation: "Are we building the right product ?"
3.2 Semantics. 2 Semantics Attribute Grammars The Meanings of Programs: Semantics Sebesta Chapter 3.
Programming Languages and Design Lecture 3 Semantic Specifications of Programming Languages Instructor: Li Ma Department of Computer Science Texas Southern.
Formal Methods.
Chapter 5: Software Re-Engineering Omar Meqdadi SE 3860 Lecture 5 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
Formal Methods in Software Engineering Credit Hours: 3+0 By: Qaisar Javaid Assistant Professor.
An Axiomatic Basis for Computer Programming Robert Stewart.
Formal Methods in SE Software Verification Using Formal Methods By: Qaisar Javaid, Assistant Professor Formal Methods1.
Version 02U-1 Computer Security: Art and Science1 Correctness by Construction: Developing a Commercial Secure System by Anthony Hall Roderick Chapman.
Static Techniques for V&V. Hierarchy of V&V techniques Static Analysis V&V Dynamic Techniques Model Checking Simulation Symbolic Execution Testing Informal.
Quality Assurance in the Presence of Variability Kim Lauenroth, Andreas Metzger, Klaus Pohl Institute for Computer Science and Business Information Systems.
Duminda WijesekeraSWSE 623: Introduction1 Introduction to Formal and Semi- formal Methods Based on A Specifier's Introduction to Formal Methods (J. Wing)
Requirements Engineering Methods for Requirements Engineering Lecture-31.
Lectures 2 & 3: Software Process Models Neelam Gupta.
Testing Overview Software Reliability Techniques Testing Concepts CEN 4010 Class 24 – 11/17.
Requirement Specification SRS document is a contract between the development team and the customer How do we communicate the Requirements to others? Firm.
 System Requirement Specification and System Planning.
©Ian Sommerville 2000Software Engineering, 6th edition. Chapter 19Slide 1 Verification and Validation l Assuring that a software system meets a user's.
An Overview of Requirements Engineering Tools and Methodologies*
Advantages of Formal Methods
CHAPTER 10 METHODOLOGIES FOR CUSTOM SOFTWARE DEVELOPMENT
Project Management: Inspections and Reviews Formal Specifications
Department of Computer Science Abdul Wali Khan University Mardan
Software system modeling
Presentation transcript:

Formal Methods 1

Software Engineering and Formal Methods  Every software engineering methodology is based on a recommended development process  proceeding through several phases:  Requirements, Specification, Design  Coding, Unit Testing  Integration and System Testing, Maintenance  Formal methods can  Be a foundation for designing safety critical systems  Be a foundation for describing complex systems  Provide support for program development 2

What are Formal Methods?  Techniques and tools based on mathematics and formal logic  Can assume various forms and levels of rigor  Informal  Low  Medium  High 3

Why Consider Formal Methods?  The development of a formal specification provides insights and an understanding of the software requirements and software design  Clarify customers’ requirements  Reveal and remove ambiguity, inconsistency and incompleteness  Facilitate communication of requirement or design  Provides a basis for an elegant software design  Traceability  System-level requirements should be traceable to subsystems or components 4

Formal Methods Concepts Formal Specification Methods Formal specification Formal Proofs Model checking Abstraction 5

Formal Specification  The translation of non-mathematical description (diagrams, table, natural language) into a formal specification language  It represents a concise description of high-level behavior and properties of a system  Well-defined language semantics support formal deduction about the specification 6

Type of Formal Specifications  Model Oriented: Construct a model of the system behavior using mathematical objects like sets, sequences etc.  Statecharts, SCR, VDM, Z  Petri Nets, CCS, CSP, Automata theoretic models  Property Oriented: Use a set of necessary properties to describe system behavior, such as axioms, rules etc.  Algebraic semantics  Temporal logic models. 7

Formal Proofs  Proof is an essential part of specification  Proofs are constructed as a series of small steps, each of which is justified using a small set of rules  Proofs can be done manually, but usually constructed with some automated assistance 8

Model Checking  A technique relies on building a finite model of a system and checking that a desired property holds in that model  Two general approaches  temporal model checking  automaton model checking  Use model checkers  SMV 9

Abstraction  Representation of the program using a smaller model  Allows you to focus on the most important central properties and characteristics  Getting the right level of abstraction is very important in a specification. 10

Mathematical Models  Abstract representations of a system using mathematical entities and concepts  Model should captures the essential characteristics of the system while ignoring irrelevant details  Model can be analyzed using mathematical reasoning to prove system properties or derive new behaviors.  Two types  Continuous models  Discrete models 11

Formal Specification Process Model  Clarify requirements and high level design  Articulate implicit assumptions  Identify undocumented or unexpected assumptions  Expose defects  Identify exceptions  Evaluate test coverage 12

Cleanroom software development  Spend a lot of effort "up-front" to prevent defects  Formal specification  Incremental development  Statistical methods to ensure reliability 13

Cleanroom Process  Formal specification using a state transition model  Structured programming - limited control and abstraction constructs are used  Program resembles state machine  Static verification using rigorous inspections  Mathematical arguments  Statistical testing of the system reliability 14

Cleanroom Process 15

Cleanroom Process  Incremental development  Allows freezing of requirements, so formal work can proceed  Work on critical functionality in early revisions, so it receives the most testing 16

Cleanroom Process  Specification team.  Develop and maintain system specification  Development team.  Develop and verify (mathematically) the software.  The software is not executed or even compiled during this process  Certification team.  Develop set of statistical tests to exercise the software after development.  Reliability growth models used to determine when reliability is acceptable 17

Test Results  Successful in the field  Few errors  Not more expensive than other processes  Generally workable  Higher quality code resulted 18

Benefits of Formal Specifications  Higher level of rigor leads to better problem understanding  Defects are uncovered that would be missed using traditional specification methods  Allows earlier defect identification  Formal specification language semantics allow checks for self- consistency  Enables the use of formal proofs to establish fundamental system properties and invariants 19

Limitations to Formal Methods  Requires a sound mathematical knowledge of the developer  Different aspects of a design may be represented by different formal specification methods  Useful for consistency checks, but formal methods cannot guarantee the completeness of a specifications  For the majority of systems Does not offer significant cost or quality advantages over others 20

Thanks 21