SlideShare une entreprise Scribd logo
1  sur  25
By
Kashif khan
Kashif.namal@gmail.com
Muhammad Yasir khan
Adnan Saleem
adnanskyousafzai@gmail.com
Muhammad Ejaz khan
University of Camerino Italy
 Introduction to mCRL2
 LPS , LTS,PBES
 Operators
 Vending Machine
 Odd counter
 Login
 Car park
 Phone book
 Micro Common representation language 2
 Specification Language
 Used for modeling , verification and
validation
 Based on Algebra of communicating process
include data and time.
 Process perform actions, can carry data as
parameter
 Every process has LTS contain all states
 Stored in binary Format
 LTS constructed from LPS
 LPS, symbolic representation of LTS to
describe behavior of system explicitly
 LPS can be printed in Human Readable format
 LPS is speedy than LTS
 Statistical info Can be collected in LPSPP
 Generated from LPS
 It show the LPS as node link Diagram
(ltsgraph)
 LTSVIEW to reduce the complexity of
image(3D)
 DIAGRAPHICA reduce complexity to 2D
 LTSCONVERT smaller than Original LTS
 LTSCOMPARE check weather the two LTS are
behaviorally equal or not
 Parameterized Boolean Equation system
 Input needed for model checking, is a
formula expressing a desired property that
the system should not violate (or satisfy)
 Pbes stored in Binary format
 Pbespp stored in human readable format.
 BES genrated from PBES
 Sort
data type definition using keyword sort. Sorts are
non-empty, possibly infinite sets with data
elements.
sort D;
cons c, d : D;
 declares sort D in which all elements can be
denoted by either c or d.
Now for Boolean
sort B
cons true, false : B;
 The sum operator allows to formulate the choice
between a possibly infinite number of processes
in a very concise way.
 The process sum n: Nat . p(n) can be seen as a
shorthand for p(0) + p(1) + p(2) + .... The use of
the sum operator is often to indicate that some
value must be read, i.e., the process wants to
read either a 0 or a 1 or a 2,
sort Val = struct c2 | c5 | c10;
act coin: Val;
init sum v: Val . coin(v);
act num: Nat;
init sum v: Nat . num(2 * v);
 sort Val = struct c2 | c5 | c10;
 act
coffee;
coin, rej: Val;
 proc P = sum v: Val . coin(v) . (
(v != c10) -> rej(v) . P + (v == c10) ->
coffee . P ); init P;
 We can let data influence the course of events
by adding conditions to the process
c -> p <> q implies if c then do process p
else do process q
 act tick, reset;
proc
Clock(n: Nat) = (n < 99) -> tick . Clock(n + 1)
<> tick . Clock(0) + (n < 50) -> reset .
Clock(0);
init Clock(0);
 comm({a|b -> c}, p) .. multi-actions are
renamed to a single action... actions a and b
must communicate to c in process p.
 act a, b, c: Nat;
proc P = a(1) || b(1);
init comm({a|b->c}, P);
 Allow (allow(A, P))
removes all multi-actions from the transition
system that do not occur in A. Any states that
have become unreachable will also be
removed by mCRL2, as the resulting system
is smaller and bisimilar.
allow({c}; p) only multi-actions consisting
of a single c are allowed in p.
allow({c},comm({send|read- > c}, send||read))
 After inserting a coin of 10 cents, the user can
push the button for an apple. An apple will then
be put in the drawer of the machine.
act ins10, optA, acc10, putA, coin, ready ;
proc
User = ins10 . optA . User ;
Mach = acc10 . putA . Mach ;
init
allow(
{ coin, ready },
comm( { ins10|acc10 -> coin,
optA|putA -> ready }, User || Mach ) ) ;
sort
Value= struct even | odd;
act
r1,r2:Nat;
s1,s2,s3 : Value;
proc
P=sum n:Nat.(n<5)->r1(n).s1(if(n mod 2 == 0, even, odd)).P;
Q(n:Nat)=sum v:Value.s2(v).((v==even)->tau
+(v==odd)->r2(n)).Q(n=min(5,n+1));
init allow ({r1,r2},
comm ({s1|s2->s3},
P||Q(0)));
Filter
P
Counter
Q
r1 r2s1 s2
s3
◦ no deadlock?
[true*]<true>true
◦ an input (r1) is always followed by an output (s3)?
[true*.r1.(!s3)*]<(!s3)*.s3>true
 User first check the system if the system
working the user enter password and
username, if it is already in the database the
user login to the system if not available then
the user first go for signup and insert all the
data.
 [true*]<true>true
 password needed (1): [loginpage] < true* .
enterpassword > true (that is: the first
‘loginpage’ can be followed by
‘enterpassword’)
 password needed (2): [true* . loginpage] <
true* . enterpassword > true (that is: every
‘loginpage’ can be followed by
‘enterpassword’)
mCRL2 specication before linearisation:
act order, receive, keep, refund; return;
proc
Start = order .Ordered;
Ordered = receive. Received + refund .Start;
Received = return .Ordered + keep;
init Start;
sort State = struct start | ordered | received;
act order, receive, keep, refund, return;
proc P(s : State) =
(s =start) -> order . P(ordered)
+ (s =ordered) -> receive . P(received)
+ (s = ordered) ->refund . P(start)
+ (s =received) -> return . P(ordered)
+ (s = received) -> keep;
init P(start);
act
enter_car,
enter_cash,recive_recipt,car_park,open_gate,acc_cash,give_recipt,
entercar,cash,recipt,park,acc_gate;
proc
User = enter_car . enter_cash. recive_recipt . car_park . User;
Machine =acc_gate . acc_cash . give_recipt. open_gate . Machine;
init
allow(
{entercar,cash,recipt,park },
comm(
{enter_car|acc_gate -> entercar, enter_cash|acc_cash->cash,
recive_recipt|give_recipt->recipt, car_park|open_gate->park },
User || Machine
) ) ;
sort Name = struct n0 | n1 ;
PhoneNumber = struct p0 | p1 ;
PhoneBook = Name -> PhoneNumber;
map
book: Name -> PhoneNumber;
var n: Name;
eqn
book(n) = p0;
act
addPhone: Name # PhoneNumber;
delPhone: Name;
findPhone: Name;
proc
PhoneDir(b: PhoneBook) =
sum n: Name, p: PhoneNumber . (p != p0) -> addPhone(n, p) . PhoneDir(b[n->p])
+ sum n: Name . findPhone(n) . PhoneDir()
+ sum n: Name . delPhone(n) . PhoneDir(b[n->p0]);
init PhoneDir(book);
Mcrl2 by kashif.namal@gmail.com, adnanskyousafzai@gmail.com

Contenu connexe

Tendances

Ppt tujuan dan prinsip ekonomi islam
Ppt tujuan dan prinsip ekonomi islamPpt tujuan dan prinsip ekonomi islam
Ppt tujuan dan prinsip ekonomi islamAnisa Muvit
 
A. jadi ppt zakat lengkap kelompok 10 PAI
A. jadi ppt zakat lengkap kelompok 10 PAIA. jadi ppt zakat lengkap kelompok 10 PAI
A. jadi ppt zakat lengkap kelompok 10 PAIRiniDwi7
 
Keawajian menuntut ilmu
Keawajian menuntut ilmuKeawajian menuntut ilmu
Keawajian menuntut ilmuDodyk Fallen
 
Islamic ecnomics system vs conventional ecnomic system
Islamic ecnomics system vs conventional ecnomic systemIslamic ecnomics system vs conventional ecnomic system
Islamic ecnomics system vs conventional ecnomic systemES Iqbal
 
Filsafat al ghazali dan ibnu rusyd
Filsafat al ghazali dan ibnu rusydFilsafat al ghazali dan ibnu rusyd
Filsafat al ghazali dan ibnu rusydDwi Andriani
 
Pilar pilar ekonomi islam
Pilar pilar ekonomi islamPilar pilar ekonomi islam
Pilar pilar ekonomi islamSatrio Adi
 
Sejarah sistem perekonomian islam dari masa ke masa
Sejarah sistem perekonomian islam dari masa ke masaSejarah sistem perekonomian islam dari masa ke masa
Sejarah sistem perekonomian islam dari masa ke masaogie nirwan
 
Etos kerja dan kesejahteraan sosial
Etos kerja dan kesejahteraan sosialEtos kerja dan kesejahteraan sosial
Etos kerja dan kesejahteraan sosialUmi Badriyah
 
Teori permintaan islami
Teori permintaan islamiTeori permintaan islami
Teori permintaan islamiRian Ramdani
 
Ppt presentasi ekonomi islam pengertian harta dalam islam
Ppt presentasi ekonomi islam pengertian harta dalam islamPpt presentasi ekonomi islam pengertian harta dalam islam
Ppt presentasi ekonomi islam pengertian harta dalam islamppt education
 
Organisasi Bisnis Dalam Islam - Anto Apriyanto
Organisasi Bisnis Dalam Islam - Anto ApriyantoOrganisasi Bisnis Dalam Islam - Anto Apriyanto
Organisasi Bisnis Dalam Islam - Anto ApriyantoAnto Apriyanto, M.E.I.
 
Coptic Church Kamal Botros
Coptic Church Kamal BotrosCoptic Church Kamal Botros
Coptic Church Kamal BotrosGeorMar
 
Pembidangan ilmu fiqih
Pembidangan ilmu fiqihPembidangan ilmu fiqih
Pembidangan ilmu fiqihM fazrul
 

Tendances (20)

Ppt tujuan dan prinsip ekonomi islam
Ppt tujuan dan prinsip ekonomi islamPpt tujuan dan prinsip ekonomi islam
Ppt tujuan dan prinsip ekonomi islam
 
A. jadi ppt zakat lengkap kelompok 10 PAI
A. jadi ppt zakat lengkap kelompok 10 PAIA. jadi ppt zakat lengkap kelompok 10 PAI
A. jadi ppt zakat lengkap kelompok 10 PAI
 
Keawajian menuntut ilmu
Keawajian menuntut ilmuKeawajian menuntut ilmu
Keawajian menuntut ilmu
 
Islamic ecnomics system vs conventional ecnomic system
Islamic ecnomics system vs conventional ecnomic systemIslamic ecnomics system vs conventional ecnomic system
Islamic ecnomics system vs conventional ecnomic system
 
Filsafat al ghazali dan ibnu rusyd
Filsafat al ghazali dan ibnu rusydFilsafat al ghazali dan ibnu rusyd
Filsafat al ghazali dan ibnu rusyd
 
Pilar pilar ekonomi islam
Pilar pilar ekonomi islamPilar pilar ekonomi islam
Pilar pilar ekonomi islam
 
Presentasi Tauhid
Presentasi TauhidPresentasi Tauhid
Presentasi Tauhid
 
14 HUKUM WADI'AH
14 HUKUM WADI'AH14 HUKUM WADI'AH
14 HUKUM WADI'AH
 
Sejarah sistem perekonomian islam dari masa ke masa
Sejarah sistem perekonomian islam dari masa ke masaSejarah sistem perekonomian islam dari masa ke masa
Sejarah sistem perekonomian islam dari masa ke masa
 
Etos kerja dan kesejahteraan sosial
Etos kerja dan kesejahteraan sosialEtos kerja dan kesejahteraan sosial
Etos kerja dan kesejahteraan sosial
 
Teori permintaan islami
Teori permintaan islamiTeori permintaan islami
Teori permintaan islami
 
Ppt presentasi ekonomi islam pengertian harta dalam islam
Ppt presentasi ekonomi islam pengertian harta dalam islamPpt presentasi ekonomi islam pengertian harta dalam islam
Ppt presentasi ekonomi islam pengertian harta dalam islam
 
Makalah perkembangan perilaku dan kepribadian
Makalah perkembangan perilaku dan kepribadianMakalah perkembangan perilaku dan kepribadian
Makalah perkembangan perilaku dan kepribadian
 
Organisasi Bisnis Dalam Islam - Anto Apriyanto
Organisasi Bisnis Dalam Islam - Anto ApriyantoOrganisasi Bisnis Dalam Islam - Anto Apriyanto
Organisasi Bisnis Dalam Islam - Anto Apriyanto
 
Produksi islami
Produksi islamiProduksi islami
Produksi islami
 
Pengelolaan wakaf
Pengelolaan wakafPengelolaan wakaf
Pengelolaan wakaf
 
Coptic Church Kamal Botros
Coptic Church Kamal BotrosCoptic Church Kamal Botros
Coptic Church Kamal Botros
 
Baitul mal
Baitul malBaitul mal
Baitul mal
 
CHRISTIAN MYSTICISM
CHRISTIAN MYSTICISMCHRISTIAN MYSTICISM
CHRISTIAN MYSTICISM
 
Pembidangan ilmu fiqih
Pembidangan ilmu fiqihPembidangan ilmu fiqih
Pembidangan ilmu fiqih
 

Similaire à Mcrl2 by kashif.namal@gmail.com, adnanskyousafzai@gmail.com

Formal Verification of Transactional Interaction Contract
Formal Verification of Transactional Interaction ContractFormal Verification of Transactional Interaction Contract
Formal Verification of Transactional Interaction ContractGera Shegalov
 
Basic_analysis.ppt
Basic_analysis.pptBasic_analysis.ppt
Basic_analysis.pptSoumyaJ3
 
Job Queue in Golang
Job Queue in GolangJob Queue in Golang
Job Queue in GolangBo-Yi Wu
 
Formal Verification of Web Service Interaction Contracts
Formal Verification of Web Service Interaction ContractsFormal Verification of Web Service Interaction Contracts
Formal Verification of Web Service Interaction ContractsGera Shegalov
 
The Ring programming language version 1.5.2 book - Part 74 of 181
The Ring programming language version 1.5.2 book - Part 74 of 181The Ring programming language version 1.5.2 book - Part 74 of 181
The Ring programming language version 1.5.2 book - Part 74 of 181Mahmoud Samir Fayed
 
The Ring programming language version 1.3 book - Part 59 of 88
The Ring programming language version 1.3 book - Part 59 of 88The Ring programming language version 1.3 book - Part 59 of 88
The Ring programming language version 1.3 book - Part 59 of 88Mahmoud Samir Fayed
 
The Ring programming language version 1.4 book - Part 21 of 30
The Ring programming language version 1.4 book - Part 21 of 30The Ring programming language version 1.4 book - Part 21 of 30
The Ring programming language version 1.4 book - Part 21 of 30Mahmoud Samir Fayed
 
Small pieces loosely joined
Small pieces loosely joinedSmall pieces loosely joined
Small pieces loosely joinedennui2342
 
chapter1.ppt
chapter1.pptchapter1.ppt
chapter1.pptebinazer1
 
PID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB ApproachPID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB ApproachWaleed El-Badry
 

Similaire à Mcrl2 by kashif.namal@gmail.com, adnanskyousafzai@gmail.com (20)

MCRL2
MCRL2MCRL2
MCRL2
 
Formal Verification of Transactional Interaction Contract
Formal Verification of Transactional Interaction ContractFormal Verification of Transactional Interaction Contract
Formal Verification of Transactional Interaction Contract
 
OSCh7
OSCh7OSCh7
OSCh7
 
OS_Ch7
OS_Ch7OS_Ch7
OS_Ch7
 
chapter1.ppt
chapter1.pptchapter1.ppt
chapter1.ppt
 
chapter1.ppt
chapter1.pptchapter1.ppt
chapter1.ppt
 
Basic_analysis.ppt
Basic_analysis.pptBasic_analysis.ppt
Basic_analysis.ppt
 
Job Queue in Golang
Job Queue in GolangJob Queue in Golang
Job Queue in Golang
 
CPP Homework Help
CPP Homework HelpCPP Homework Help
CPP Homework Help
 
Formal Verification of Web Service Interaction Contracts
Formal Verification of Web Service Interaction ContractsFormal Verification of Web Service Interaction Contracts
Formal Verification of Web Service Interaction Contracts
 
C lab-programs
C lab-programsC lab-programs
C lab-programs
 
The Ring programming language version 1.5.2 book - Part 74 of 181
The Ring programming language version 1.5.2 book - Part 74 of 181The Ring programming language version 1.5.2 book - Part 74 of 181
The Ring programming language version 1.5.2 book - Part 74 of 181
 
Loops
LoopsLoops
Loops
 
The Ring programming language version 1.3 book - Part 59 of 88
The Ring programming language version 1.3 book - Part 59 of 88The Ring programming language version 1.3 book - Part 59 of 88
The Ring programming language version 1.3 book - Part 59 of 88
 
The Ring programming language version 1.4 book - Part 21 of 30
The Ring programming language version 1.4 book - Part 21 of 30The Ring programming language version 1.4 book - Part 21 of 30
The Ring programming language version 1.4 book - Part 21 of 30
 
Small pieces loosely joined
Small pieces loosely joinedSmall pieces loosely joined
Small pieces loosely joined
 
chapter1.ppt
chapter1.pptchapter1.ppt
chapter1.ppt
 
Advanced C - Part 2
Advanced C - Part 2Advanced C - Part 2
Advanced C - Part 2
 
Angular2 rxjs
Angular2 rxjsAngular2 rxjs
Angular2 rxjs
 
PID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB ApproachPID Tuning using Ziegler Nicholas - MATLAB Approach
PID Tuning using Ziegler Nicholas - MATLAB Approach
 

Dernier

Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS ESCORT SERVICE In Bhiwan...
Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS  ESCORT SERVICE In Bhiwan...Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS  ESCORT SERVICE In Bhiwan...
Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS ESCORT SERVICE In Bhiwan...Monika Rani
 
PSYCHOSOCIAL NEEDS. in nursing II sem pptx
PSYCHOSOCIAL NEEDS. in nursing II sem pptxPSYCHOSOCIAL NEEDS. in nursing II sem pptx
PSYCHOSOCIAL NEEDS. in nursing II sem pptxSuji236384
 
Human genetics..........................pptx
Human genetics..........................pptxHuman genetics..........................pptx
Human genetics..........................pptxSilpa
 
Dr. E. Muralinath_ Blood indices_clinical aspects
Dr. E. Muralinath_ Blood indices_clinical  aspectsDr. E. Muralinath_ Blood indices_clinical  aspects
Dr. E. Muralinath_ Blood indices_clinical aspectsmuralinath2
 
CURRENT SCENARIO OF POULTRY PRODUCTION IN INDIA
CURRENT SCENARIO OF POULTRY PRODUCTION IN INDIACURRENT SCENARIO OF POULTRY PRODUCTION IN INDIA
CURRENT SCENARIO OF POULTRY PRODUCTION IN INDIADr. TATHAGAT KHOBRAGADE
 
Grade 7 - Lesson 1 - Microscope and Its Functions
Grade 7 - Lesson 1 - Microscope and Its FunctionsGrade 7 - Lesson 1 - Microscope and Its Functions
Grade 7 - Lesson 1 - Microscope and Its FunctionsOrtegaSyrineMay
 
The Mariana Trench remarkable geological features on Earth.pptx
The Mariana Trench remarkable geological features on Earth.pptxThe Mariana Trench remarkable geological features on Earth.pptx
The Mariana Trench remarkable geological features on Earth.pptxseri bangash
 
GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)Areesha Ahmad
 
Digital Dentistry.Digital Dentistryvv.pptx
Digital Dentistry.Digital Dentistryvv.pptxDigital Dentistry.Digital Dentistryvv.pptx
Digital Dentistry.Digital Dentistryvv.pptxMohamedFarag457087
 
Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...
Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...
Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...Silpa
 
FAIRSpectra - Enabling the FAIRification of Analytical Science
FAIRSpectra - Enabling the FAIRification of Analytical ScienceFAIRSpectra - Enabling the FAIRification of Analytical Science
FAIRSpectra - Enabling the FAIRification of Analytical ScienceAlex Henderson
 
Zoology 5th semester notes( Sumit_yadav).pdf
Zoology 5th semester notes( Sumit_yadav).pdfZoology 5th semester notes( Sumit_yadav).pdf
Zoology 5th semester notes( Sumit_yadav).pdfSumit Kumar yadav
 
module for grade 9 for distance learning
module for grade 9 for distance learningmodule for grade 9 for distance learning
module for grade 9 for distance learninglevieagacer
 
biology HL practice questions IB BIOLOGY
biology HL practice questions IB BIOLOGYbiology HL practice questions IB BIOLOGY
biology HL practice questions IB BIOLOGY1301aanya
 
Use of mutants in understanding seedling development.pptx
Use of mutants in understanding seedling development.pptxUse of mutants in understanding seedling development.pptx
Use of mutants in understanding seedling development.pptxRenuJangid3
 
Asymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 b
Asymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 bAsymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 b
Asymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 bSérgio Sacani
 
Introduction of DNA analysis in Forensic's .pptx
Introduction of DNA analysis in Forensic's .pptxIntroduction of DNA analysis in Forensic's .pptx
Introduction of DNA analysis in Forensic's .pptxrohankumarsinghrore1
 
Factory Acceptance Test( FAT).pptx .
Factory Acceptance Test( FAT).pptx       .Factory Acceptance Test( FAT).pptx       .
Factory Acceptance Test( FAT).pptx .Poonam Aher Patil
 

Dernier (20)

Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS ESCORT SERVICE In Bhiwan...
Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS  ESCORT SERVICE In Bhiwan...Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS  ESCORT SERVICE In Bhiwan...
Bhiwandi Bhiwandi ❤CALL GIRL 7870993772 ❤CALL GIRLS ESCORT SERVICE In Bhiwan...
 
PSYCHOSOCIAL NEEDS. in nursing II sem pptx
PSYCHOSOCIAL NEEDS. in nursing II sem pptxPSYCHOSOCIAL NEEDS. in nursing II sem pptx
PSYCHOSOCIAL NEEDS. in nursing II sem pptx
 
Human genetics..........................pptx
Human genetics..........................pptxHuman genetics..........................pptx
Human genetics..........................pptx
 
Dr. E. Muralinath_ Blood indices_clinical aspects
Dr. E. Muralinath_ Blood indices_clinical  aspectsDr. E. Muralinath_ Blood indices_clinical  aspects
Dr. E. Muralinath_ Blood indices_clinical aspects
 
CURRENT SCENARIO OF POULTRY PRODUCTION IN INDIA
CURRENT SCENARIO OF POULTRY PRODUCTION IN INDIACURRENT SCENARIO OF POULTRY PRODUCTION IN INDIA
CURRENT SCENARIO OF POULTRY PRODUCTION IN INDIA
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Grade 7 - Lesson 1 - Microscope and Its Functions
Grade 7 - Lesson 1 - Microscope and Its FunctionsGrade 7 - Lesson 1 - Microscope and Its Functions
Grade 7 - Lesson 1 - Microscope and Its Functions
 
The Mariana Trench remarkable geological features on Earth.pptx
The Mariana Trench remarkable geological features on Earth.pptxThe Mariana Trench remarkable geological features on Earth.pptx
The Mariana Trench remarkable geological features on Earth.pptx
 
GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)GBSN - Microbiology (Unit 2)
GBSN - Microbiology (Unit 2)
 
Digital Dentistry.Digital Dentistryvv.pptx
Digital Dentistry.Digital Dentistryvv.pptxDigital Dentistry.Digital Dentistryvv.pptx
Digital Dentistry.Digital Dentistryvv.pptx
 
PATNA CALL GIRLS 8617370543 LOW PRICE ESCORT SERVICE
PATNA CALL GIRLS 8617370543 LOW PRICE ESCORT SERVICEPATNA CALL GIRLS 8617370543 LOW PRICE ESCORT SERVICE
PATNA CALL GIRLS 8617370543 LOW PRICE ESCORT SERVICE
 
Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...
Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...
Locating and isolating a gene, FISH, GISH, Chromosome walking and jumping, te...
 
FAIRSpectra - Enabling the FAIRification of Analytical Science
FAIRSpectra - Enabling the FAIRification of Analytical ScienceFAIRSpectra - Enabling the FAIRification of Analytical Science
FAIRSpectra - Enabling the FAIRification of Analytical Science
 
Zoology 5th semester notes( Sumit_yadav).pdf
Zoology 5th semester notes( Sumit_yadav).pdfZoology 5th semester notes( Sumit_yadav).pdf
Zoology 5th semester notes( Sumit_yadav).pdf
 
module for grade 9 for distance learning
module for grade 9 for distance learningmodule for grade 9 for distance learning
module for grade 9 for distance learning
 
biology HL practice questions IB BIOLOGY
biology HL practice questions IB BIOLOGYbiology HL practice questions IB BIOLOGY
biology HL practice questions IB BIOLOGY
 
Use of mutants in understanding seedling development.pptx
Use of mutants in understanding seedling development.pptxUse of mutants in understanding seedling development.pptx
Use of mutants in understanding seedling development.pptx
 
Asymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 b
Asymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 bAsymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 b
Asymmetry in the atmosphere of the ultra-hot Jupiter WASP-76 b
 
Introduction of DNA analysis in Forensic's .pptx
Introduction of DNA analysis in Forensic's .pptxIntroduction of DNA analysis in Forensic's .pptx
Introduction of DNA analysis in Forensic's .pptx
 
Factory Acceptance Test( FAT).pptx .
Factory Acceptance Test( FAT).pptx       .Factory Acceptance Test( FAT).pptx       .
Factory Acceptance Test( FAT).pptx .
 

Mcrl2 by kashif.namal@gmail.com, adnanskyousafzai@gmail.com

  • 1. By Kashif khan Kashif.namal@gmail.com Muhammad Yasir khan Adnan Saleem adnanskyousafzai@gmail.com Muhammad Ejaz khan University of Camerino Italy
  • 2.  Introduction to mCRL2  LPS , LTS,PBES  Operators  Vending Machine  Odd counter  Login  Car park  Phone book
  • 3.  Micro Common representation language 2  Specification Language  Used for modeling , verification and validation  Based on Algebra of communicating process include data and time.  Process perform actions, can carry data as parameter  Every process has LTS contain all states
  • 4.
  • 5.
  • 6.  Stored in binary Format  LTS constructed from LPS  LPS, symbolic representation of LTS to describe behavior of system explicitly  LPS can be printed in Human Readable format  LPS is speedy than LTS  Statistical info Can be collected in LPSPP
  • 7.  Generated from LPS  It show the LPS as node link Diagram (ltsgraph)  LTSVIEW to reduce the complexity of image(3D)  DIAGRAPHICA reduce complexity to 2D  LTSCONVERT smaller than Original LTS  LTSCOMPARE check weather the two LTS are behaviorally equal or not
  • 8.  Parameterized Boolean Equation system  Input needed for model checking, is a formula expressing a desired property that the system should not violate (or satisfy)  Pbes stored in Binary format  Pbespp stored in human readable format.  BES genrated from PBES
  • 9.  Sort data type definition using keyword sort. Sorts are non-empty, possibly infinite sets with data elements. sort D; cons c, d : D;  declares sort D in which all elements can be denoted by either c or d. Now for Boolean sort B cons true, false : B;
  • 10.  The sum operator allows to formulate the choice between a possibly infinite number of processes in a very concise way.  The process sum n: Nat . p(n) can be seen as a shorthand for p(0) + p(1) + p(2) + .... The use of the sum operator is often to indicate that some value must be read, i.e., the process wants to read either a 0 or a 1 or a 2, sort Val = struct c2 | c5 | c10; act coin: Val; init sum v: Val . coin(v); act num: Nat; init sum v: Nat . num(2 * v);
  • 11.  sort Val = struct c2 | c5 | c10;  act coffee; coin, rej: Val;  proc P = sum v: Val . coin(v) . ( (v != c10) -> rej(v) . P + (v == c10) -> coffee . P ); init P;
  • 12.  We can let data influence the course of events by adding conditions to the process c -> p <> q implies if c then do process p else do process q  act tick, reset; proc Clock(n: Nat) = (n < 99) -> tick . Clock(n + 1) <> tick . Clock(0) + (n < 50) -> reset . Clock(0); init Clock(0);
  • 13.  comm({a|b -> c}, p) .. multi-actions are renamed to a single action... actions a and b must communicate to c in process p.  act a, b, c: Nat; proc P = a(1) || b(1); init comm({a|b->c}, P);
  • 14.  Allow (allow(A, P)) removes all multi-actions from the transition system that do not occur in A. Any states that have become unreachable will also be removed by mCRL2, as the resulting system is smaller and bisimilar. allow({c}; p) only multi-actions consisting of a single c are allowed in p. allow({c},comm({send|read- > c}, send||read))
  • 15.  After inserting a coin of 10 cents, the user can push the button for an apple. An apple will then be put in the drawer of the machine. act ins10, optA, acc10, putA, coin, ready ; proc User = ins10 . optA . User ; Mach = acc10 . putA . Mach ; init allow( { coin, ready }, comm( { ins10|acc10 -> coin, optA|putA -> ready }, User || Mach ) ) ;
  • 16. sort Value= struct even | odd; act r1,r2:Nat; s1,s2,s3 : Value; proc P=sum n:Nat.(n<5)->r1(n).s1(if(n mod 2 == 0, even, odd)).P; Q(n:Nat)=sum v:Value.s2(v).((v==even)->tau +(v==odd)->r2(n)).Q(n=min(5,n+1)); init allow ({r1,r2}, comm ({s1|s2->s3}, P||Q(0))); Filter P Counter Q r1 r2s1 s2 s3
  • 17. ◦ no deadlock? [true*]<true>true ◦ an input (r1) is always followed by an output (s3)? [true*.r1.(!s3)*]<(!s3)*.s3>true
  • 18.  User first check the system if the system working the user enter password and username, if it is already in the database the user login to the system if not available then the user first go for signup and insert all the data.
  • 19.  [true*]<true>true  password needed (1): [loginpage] < true* . enterpassword > true (that is: the first ‘loginpage’ can be followed by ‘enterpassword’)  password needed (2): [true* . loginpage] < true* . enterpassword > true (that is: every ‘loginpage’ can be followed by ‘enterpassword’)
  • 20. mCRL2 specication before linearisation: act order, receive, keep, refund; return; proc Start = order .Ordered; Ordered = receive. Received + refund .Start; Received = return .Ordered + keep; init Start;
  • 21. sort State = struct start | ordered | received; act order, receive, keep, refund, return; proc P(s : State) = (s =start) -> order . P(ordered) + (s =ordered) -> receive . P(received) + (s = ordered) ->refund . P(start) + (s =received) -> return . P(ordered) + (s = received) -> keep; init P(start);
  • 22.
  • 23. act enter_car, enter_cash,recive_recipt,car_park,open_gate,acc_cash,give_recipt, entercar,cash,recipt,park,acc_gate; proc User = enter_car . enter_cash. recive_recipt . car_park . User; Machine =acc_gate . acc_cash . give_recipt. open_gate . Machine; init allow( {entercar,cash,recipt,park }, comm( {enter_car|acc_gate -> entercar, enter_cash|acc_cash->cash, recive_recipt|give_recipt->recipt, car_park|open_gate->park }, User || Machine ) ) ;
  • 24. sort Name = struct n0 | n1 ; PhoneNumber = struct p0 | p1 ; PhoneBook = Name -> PhoneNumber; map book: Name -> PhoneNumber; var n: Name; eqn book(n) = p0; act addPhone: Name # PhoneNumber; delPhone: Name; findPhone: Name; proc PhoneDir(b: PhoneBook) = sum n: Name, p: PhoneNumber . (p != p0) -> addPhone(n, p) . PhoneDir(b[n->p]) + sum n: Name . findPhone(n) . PhoneDir() + sum n: Name . delPhone(n) . PhoneDir(b[n->p0]); init PhoneDir(book);