SlideShare a Scribd company logo
1 of 21
Download to read offline
An introduction to


             Uppaal
             Ulrik Hørlyk Hjort
    BestPractice Consulting & Advising 2010




                          
The Uppaal System
► UPPAAL     is a tool for modeling, validation and
    verification of real-time systems.
►    It is appropriate for systems that can be modeled as
    a collection of non-deterministic processes with finite
    control structure and real-valued clocks (i.e. timed
    automata), communicating through channels and (or)
    shared data structures.
►    Typical application areas include real-time
    controllers, communication protocols, and other
    systems in which timing aspects are critical.


                                
Uppaal System
► Integrated       tool environment for:
     ■ Modelling
     ■ Simulation
     ■ Verification




                              
The System Editor
► Thesystem editor is used to create and edit the
 system model to be analysed
►A system model describe a network of a finite
 number of non-deterministic finite state
 automata
► Transitions   between states may be labeled with:
     ■ Guards
     ■ Synchronizations
     ■ Assignment   statements

                                  
Uppaal Model

Initial Location

Location

Edge

Synchronization




                         
Uppaal Model

procedure Factorial is

  Result : Integer := 5;

begin
   for I in reverse 1 .. 4 loop
      Result := Result * I;
   end loop;

    Put_Line(Integer'Image(Result));

end Factorial;




                                        
Task Synchronization
task body TaskA is
begin
   TaskB.WriteTaskName;
end TaskA;



task body TaskB is
begin
      accept WriteTaskName  do
         Put_Line("Task B");
      end WriteTaskName;
end TaskB;




                                  
Subprogram Synchronization
procedure Main is

   procedure Hello is
   begin
      Put_Line("Hello, World!");
   end Hello;


begin
     Hello;
end Main;




                                    
Parametrised Synchronization
procedure Factorial is

   function Fac(N: Integer) Return Integer is
        Result : Integer := N;
   begin
       for I in reverse 1 .. N­1 loop
           Result := Result * I;
       end loop;
      return Result;
   end Fac;


begin
      Put_Line(Integer'Image(Fac(5)));
end Factorial;




                                                 
The Model Checker (Verifier)
► Themodel checker verify the model with respect to a
 requirement specification.
► Verifies
         safety, bounded-liveness and other user
 specified properties by reachability analysis.
► The     model checker support three Path formulae:
      ■ Reachability
      ■ Safety
      ■ Liveness




                               
E<>φ - “φ Reachable”
► E<>φ         – It is possible to reach a state in which
        φ is satisfied
►       φ is true in – at least – one reachable state




                                
The Simulator
► Lets
     users simulate the models to visually
 explore their dynamic behavior.




                       
Simple Phone Case
► Model     a phone that can:
     ■ Receive   a call
     ■ Make   a call
     ■ Receive   an sms
► Requirement:
     ■ Ifa call come while user write an sms, the user
       shall be able to answer or reject the call and then
       return to the sms editor.


                               
Declarations
bool INCOME_CALL = false;

chan letter, digit, send, cancel, accept, acceptCall, rejectCall;

broadcast chan incomeCall, incomeSms, callTone, smsTone, handleCall, handleSms;

chan enterSms, exitSms, enterCall, exitCall, exitReceiveCall;




                                                     
User and Mainscreen Models

User Model




Main Screen Model




                     
Make Call




         
Receive Call




          
Send Sms




        
Simple Phone Requirement
                Verification
► Requirement:
  ■ If  a call come while user write an sms, the user shall be able to
      answer or reject the call and then return to the sms editor.True
► Verify
       that there is a path to the location “Call” in the
 “ReceiveCall” automata and a path to the location
 “ExitReceivedCall” in the “SendSms” automata
► Therequirement can be verified with the reachability
 property as:
  ■   E<>SendSms.ExitReceivedCall and ReceiveCall.Call
► Which    evealuate to true in the verifier


                                    
Simulate the simple phone
               model
► Use the simulator to verify that it is possible
 to cover all edges in the model and that the
 model is deadlock free




                         
Questions?




    www.uppaal.com




           

More Related Content

What's hot

MATLAB programming tips 2 - Input and Output Commands
MATLAB programming tips 2 - Input and Output CommandsMATLAB programming tips 2 - Input and Output Commands
MATLAB programming tips 2 - Input and Output CommandsShameer Ahmed Koya
 
3. control statements
3. control statements3. control statements
3. control statementsamar kakde
 
Exception Handling in .NET F#
Exception Handling in .NET F#Exception Handling in .NET F#
Exception Handling in .NET F#DrRajeshreeKhande
 
Conditional Control in MATLAB Scripts
Conditional Control in MATLAB ScriptsConditional Control in MATLAB Scripts
Conditional Control in MATLAB ScriptsShameer Ahmed Koya
 
Unit ii chapter 1 operator and expressions in c
Unit ii chapter 1 operator and expressions in cUnit ii chapter 1 operator and expressions in c
Unit ii chapter 1 operator and expressions in cSowmya Jyothi
 

What's hot (8)

Looping Structures
Looping StructuresLooping Structures
Looping Structures
 
MATLAB programming tips 2 - Input and Output Commands
MATLAB programming tips 2 - Input and Output CommandsMATLAB programming tips 2 - Input and Output Commands
MATLAB programming tips 2 - Input and Output Commands
 
3. control statements
3. control statements3. control statements
3. control statements
 
Exception Handling in .NET F#
Exception Handling in .NET F#Exception Handling in .NET F#
Exception Handling in .NET F#
 
Conditional Control in MATLAB Scripts
Conditional Control in MATLAB ScriptsConditional Control in MATLAB Scripts
Conditional Control in MATLAB Scripts
 
keyword
keywordkeyword
keyword
 
Unit ii chapter 1 operator and expressions in c
Unit ii chapter 1 operator and expressions in cUnit ii chapter 1 operator and expressions in c
Unit ii chapter 1 operator and expressions in c
 
Decision making and branching
Decision making and branchingDecision making and branching
Decision making and branching
 

Similar to Uppaal Lite

JAN CARL BRIONES-Writing Programs Using Loops.pptx
JAN CARL BRIONES-Writing Programs Using Loops.pptxJAN CARL BRIONES-Writing Programs Using Loops.pptx
JAN CARL BRIONES-Writing Programs Using Loops.pptxJanCarlBriones2
 
control structure by shuja ahmad
control structure by shuja ahmadcontrol structure by shuja ahmad
control structure by shuja ahmadInocentshuja Ahmad
 
System Testing of Timing Requirements based on Use Cases and Timed Automata
System Testing of Timing Requirements based on Use Cases and Timed AutomataSystem Testing of Timing Requirements based on Use Cases and Timed Automata
System Testing of Timing Requirements based on Use Cases and Timed AutomataLionel Briand
 
Taming event-driven software via formal verification
Taming event-driven software via formal verificationTaming event-driven software via formal verification
Taming event-driven software via formal verificationAdaCore
 
Programming models for event controlled programs
Programming models for event controlled programsProgramming models for event controlled programs
Programming models for event controlled programsPriya Kaushal
 
TLA+ and PlusCal / An engineer's perspective
TLA+ and PlusCal / An engineer's perspectiveTLA+ and PlusCal / An engineer's perspective
TLA+ and PlusCal / An engineer's perspectiveTorao Takami
 
Microservices Resiliency with BallerinaLang
Microservices Resiliency with BallerinaLangMicroservices Resiliency with BallerinaLang
Microservices Resiliency with BallerinaLangAfkham Azeez
 
Parallel Complex Event Processing
Parallel Complex Event ProcessingParallel Complex Event Processing
Parallel Complex Event ProcessingKarol Grzegorczyk
 
Applications of Machine Learning in High Frequency Trading
Applications of Machine Learning in High Frequency TradingApplications of Machine Learning in High Frequency Trading
Applications of Machine Learning in High Frequency TradingAyan Sengupta
 
Problem management foundation - Mission control
Problem management foundation - Mission controlProblem management foundation - Mission control
Problem management foundation - Mission controlRonald Bartels
 
model simulating
model simulatingmodel simulating
model simulatingFEG
 
Model simulation VHDL
Model simulation VHDLModel simulation VHDL
Model simulation VHDLAbd17m
 

Similar to Uppaal Lite (20)

JAN CARL BRIONES-Writing Programs Using Loops.pptx
JAN CARL BRIONES-Writing Programs Using Loops.pptxJAN CARL BRIONES-Writing Programs Using Loops.pptx
JAN CARL BRIONES-Writing Programs Using Loops.pptx
 
control structure by shuja ahmad
control structure by shuja ahmadcontrol structure by shuja ahmad
control structure by shuja ahmad
 
System Testing of Timing Requirements based on Use Cases and Timed Automata
System Testing of Timing Requirements based on Use Cases and Timed AutomataSystem Testing of Timing Requirements based on Use Cases and Timed Automata
System Testing of Timing Requirements based on Use Cases and Timed Automata
 
Fault tolerance
Fault toleranceFault tolerance
Fault tolerance
 
Taming event-driven software via formal verification
Taming event-driven software via formal verificationTaming event-driven software via formal verification
Taming event-driven software via formal verification
 
Lesson 5
Lesson 5Lesson 5
Lesson 5
 
Programming models for event controlled programs
Programming models for event controlled programsProgramming models for event controlled programs
Programming models for event controlled programs
 
TLA+ and PlusCal / An engineer's perspective
TLA+ and PlusCal / An engineer's perspectiveTLA+ and PlusCal / An engineer's perspective
TLA+ and PlusCal / An engineer's perspective
 
STPA and Software Verification
STPA and Software VerificationSTPA and Software Verification
STPA and Software Verification
 
Microservices Resiliency with BallerinaLang
Microservices Resiliency with BallerinaLangMicroservices Resiliency with BallerinaLang
Microservices Resiliency with BallerinaLang
 
Plc by Mohamed Al-Emam, Session3
Plc by Mohamed Al-Emam, Session3Plc by Mohamed Al-Emam, Session3
Plc by Mohamed Al-Emam, Session3
 
Structure testing
Structure testingStructure testing
Structure testing
 
Parallel Complex Event Processing
Parallel Complex Event ProcessingParallel Complex Event Processing
Parallel Complex Event Processing
 
Chapter 3
Chapter 3Chapter 3
Chapter 3
 
PLSQL
PLSQLPLSQL
PLSQL
 
Coverage and Introduction to UVM
Coverage and Introduction to UVMCoverage and Introduction to UVM
Coverage and Introduction to UVM
 
Applications of Machine Learning in High Frequency Trading
Applications of Machine Learning in High Frequency TradingApplications of Machine Learning in High Frequency Trading
Applications of Machine Learning in High Frequency Trading
 
Problem management foundation - Mission control
Problem management foundation - Mission controlProblem management foundation - Mission control
Problem management foundation - Mission control
 
model simulating
model simulatingmodel simulating
model simulating
 
Model simulation VHDL
Model simulation VHDLModel simulation VHDL
Model simulation VHDL
 

Uppaal Lite