Hands-on session Model checking logical regulatory...
Transcript of Hands-on session Model checking logical regulatory...
![Page 1: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/1.jpg)
Hands-on sessionModel checking logical regulatory networks
Pedro T. Monteiro
INESC-ID Lisbon, PT
[BC]2 - Tutorial T04Logical modelling of regulatory networks
June 9, 2015
![Page 2: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/2.jpg)
Formal verification
Formal verification based on temporal logic and model checking provides a powerfultechnology to query models of discrete systems.
It has been developed, since the 70s, for hardware and software verification
In the last decade model checking has been successfully employed to tackle theanalysis of large biological regulatory models.(Chabrier et al., CMSB 2003) (Monteiro et al., Bioinformatics 2008) (Batt et al., Bioinformatics 2010)
1
![Page 3: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/3.jpg)
Formal verification
Formal verification based on temporal logic and model checking provides a powerfultechnology to query models of discrete systems.
It has been developed, since the 70s, for hardware and software verification
In the last decade model checking has been successfully employed to tackle theanalysis of large biological regulatory models.(Chabrier et al., CMSB 2003) (Monteiro et al., Bioinformatics 2008) (Batt et al., Bioinformatics 2010)
1
![Page 4: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/4.jpg)
Formal verification: Model checking
Model checking
Automated exhaustive exploration of the state space of the model.
Specify the model transition function for state space generationRemember: LRG (model) → STG (dynamics)
Specify dynamical properties as logical statements that are interpreted on STG
(Emerson and Clarke, ICALP 1980) (Queille and Sifakis, Intl. Symp. Program. 1982)
In this tutorial, we will:
use the symbolic model checker NuSMV v2.4.3 http://nusmv.fbk.eu
export the logical model defined in GINsim into a NuSMV specification
verify reachability properties between T-helper cell types
2
![Page 5: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/5.jpg)
Formal verification: Model checking
Model checking
Automated exhaustive exploration of the state space of the model.
Specify the model transition function for state space generationRemember: LRG (model) → STG (dynamics)
Specify dynamical properties as logical statements that are interpreted on STG
(Emerson and Clarke, ICALP 1980) (Queille and Sifakis, Intl. Symp. Program. 1982)
In this tutorial, we will:
use the symbolic model checker NuSMV v2.4.3 http://nusmv.fbk.eu
export the logical model defined in GINsim into a NuSMV specification
verify reachability properties between T-helper cell types
2
![Page 6: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/6.jpg)
Global approach
NuSMV specification file
3
![Page 7: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/7.jpg)
Global approach
NuSMV specification file
3
![Page 8: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/8.jpg)
T-helper cell modelModel rules
NuSMV specification file
File → Export → NuSMV
(Naldi et al., PLoS Comp Biol 2010)
VirtualBox:~$ cd Desktop/Tutorial/ModelChecking
VirtualBox:~/Desktop/Tutorial/ModelChecking$ ls
th-reduced-model.smv th-reduced-input-patterns.smv
th-reduced-state-patterns.smv ...
4
![Page 9: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/9.jpg)
T-helper cell modelModel rules
NuSMV specification file
File → Export → NuSMV
(Naldi et al., PLoS Comp Biol 2010)
VirtualBox:~$ cd Desktop/Tutorial/ModelChecking
VirtualBox:~/Desktop/Tutorial/ModelChecking$ ls
th-reduced-model.smv th-reduced-input-patterns.smv
th-reduced-state-patterns.smv ...
4
![Page 10: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/10.jpg)
T-helper cell environmental conditionsInput patterns
NuSMV specification file
(Naldi et al., PLoS Comp Biol 2010)
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-input-patterns.smv
noStml := APC=0 & IL2_e=0 & IL4_e=0 & IL6_e=0 & IL10_e=0 & IL12_e=0 & TGFB_e=0 & IFNG_e=0;
APConly := APC=1 & IL2_e=0 & IL4_e=0 & IL6_e=0 & IL10_e=0 & IL12_e=0 & TGFB_e=0 & IFNG_e=0;
proTh1a := APC=1 & IL2_e=1 & IL4_e=0 & IL6_e=0 & IL10_e=0 & IL12_e=0 & TGFB_e=0 & IFNG_e=1;
...
5
![Page 11: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/11.jpg)
T-helper cell environmental conditionsInput patterns
NuSMV specification file
(Naldi et al., PLoS Comp Biol 2010)
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-input-patterns.smv
noStml := APC=0 & IL2_e=0 & IL4_e=0 & IL6_e=0 & IL10_e=0 & IL12_e=0 & TGFB_e=0 & IFNG_e=0;
APConly := APC=1 & IL2_e=0 & IL4_e=0 & IL6_e=0 & IL10_e=0 & IL12_e=0 & TGFB_e=0 & IFNG_e=0;
proTh1a := APC=1 & IL2_e=1 & IL4_e=0 & IL6_e=0 & IL10_e=0 & IL12_e=0 & TGFB_e=0 & IFNG_e=1;
...
5
![Page 12: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/12.jpg)
T-helper cell typesState patterns
NuSMV specification file
(Naldi et al., PLoS Comp Biol 2010)
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-state-patterns.smv
...
Th1 := IL2R=0 & IL2RA=0 & IFNG=0 & IL2=0 & IL4=0 & IL10=0 & IL21=0 & IL23=0
& TGFB=0 & TBET=1 & GATA3=0 & FOXP3=0 & NFAT=0 & STAT1=0 & STAT3=0
& STAT4=0 & STAT5=0 & STAT6=0 & proliferation=1 & RORGT=0 & IL17=0;
...
6
![Page 13: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/13.jpg)
T-helper cell typesState patterns
NuSMV specification file
(Naldi et al., PLoS Comp Biol 2010)
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-state-patterns.smv
...
Th1 := IL2R=0 & IL2RA=0 & IFNG=0 & IL2=0 & IL4=0 & IL10=0 & IL21=0 & IL23=0
& TGFB=0 & TBET=1 & GATA3=0 & FOXP3=0 & NFAT=0 & STAT1=0 & STAT3=0
& STAT4=0 & STAT5=0 & STAT6=0 & proliferation=1 & RORGT=0 & IL17=0;
...
6
![Page 14: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/14.jpg)
Property specificationTemporal logic
NuSMV specification file
Temporal logic is a formalism for describing sequences oftransitions between states (the biological system observations)
Different kinds of Temporal Logics
Ctl∗:Ctl - Computation Tree Logic (branching-time)Ltl - Linear Temporal Logic (linear-time)
Ctrl - Computation Tree Regular Logic
Main CTL operators
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
EFg EGg AFg AGg
Verification of complex properties performed through composition of operators
7
![Page 15: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/15.jpg)
Property specificationTemporal logic
NuSMV specification file
Temporal logic is a formalism for describing sequences oftransitions between states (the biological system observations)
Different kinds of Temporal Logics
Ctl∗:Ctl - Computation Tree Logic (branching-time)Ltl - Linear Temporal Logic (linear-time)
Ctrl - Computation Tree Regular Logic
Main CTL operators
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
EFg EGg AFg AGg
Verification of complex properties performed through composition of operators
7
![Page 16: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/16.jpg)
Property specificationTemporal logic
NuSMV specification file
Temporal logic is a formalism for describing sequences oftransitions between states (the biological system observations)
Different kinds of Temporal Logics
Ctl∗:Ctl - Computation Tree Logic (branching-time)Ltl - Linear Temporal Logic (linear-time)
Ctrl - Computation Tree Regular Logic
Main CTL operators
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
��������
��������
g
EFg EGg AFg AGg
Verification of complex properties performed through composition of operators
7
![Page 17: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/17.jpg)
Hands-on model checking exercisesExercise 1: Th0 to Th1 differentiation
The model should differentiate from Th0 into Th1 under proTh1a environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-1-Th0-proTh1a-Th1Act.smv
INIT Th0
INIT proTh1a
SPEC EF ( Th1Act & AG ( Th1Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-1-Th0-proTh1a-Th1Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th1Act & AG Th1Act) is true
8
![Page 18: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/18.jpg)
Hands-on model checking exercisesExercise 1: Th0 to Th1 differentiation
The model should differentiate from Th0 into Th1 under proTh1a environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-1-Th0-proTh1a-Th1Act.smv
INIT Th0
INIT proTh1a
SPEC EF ( Th1Act & AG ( Th1Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-1-Th0-proTh1a-Th1Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th1Act & AG Th1Act) is true
8
![Page 19: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/19.jpg)
Hands-on model checking exercisesExercise 1: Th0 to Th1 differentiation
The model should differentiate from Th0 into Th1 under proTh1a environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-1-Th0-proTh1a-Th1Act.smv
INIT Th0
INIT proTh1a
SPEC EF ( Th1Act & AG ( Th1Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-1-Th0-proTh1a-Th1Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th1Act & AG Th1Act) is true
8
![Page 20: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/20.jpg)
Hands-on model checking exercisesExercise 2: Th0 to Th2 differentiation
The model should differentiate from Th0 into Th2 under proTh2 environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-2-Th0-proTh2-Th2Act.smv
INIT Th0
INIT proTh2
SPEC EF ( Th2Act & AG ( Th2Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-2-Th0-proTh2-Th2Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th2Act & AG Th2Act) is true
9
![Page 21: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/21.jpg)
Hands-on model checking exercisesExercise 2: Th0 to Th2 differentiation
The model should differentiate from Th0 into Th2 under proTh2 environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-2-Th0-proTh2-Th2Act.smv
INIT Th0
INIT proTh2
SPEC EF ( Th2Act & AG ( Th2Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-2-Th0-proTh2-Th2Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th2Act & AG Th2Act) is true
9
![Page 22: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/22.jpg)
Hands-on model checking exercisesExercise 2: Th0 to Th2 differentiation
The model should differentiate from Th0 into Th2 under proTh2 environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-2-Th0-proTh2-Th2Act.smv
INIT Th0
INIT proTh2
SPEC EF ( Th2Act & AG ( Th2Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-2-Th0-proTh2-Th2Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th2Act & AG Th2Act) is true
9
![Page 23: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/23.jpg)
Hands-on model checking exercisesExercise 3: Th1 to Th2 differentiation
The model should not differentiate from Th1 into Th2 under proTh2 environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-3-Th1-proTh2-Th2Act.smv
INIT Th1
INIT proTh2
SPEC EF ( Th2Act & AG ( Th2Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-3-Th1-proTh2-Th2Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th2Act & AG Th2Act) is false
10
![Page 24: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/24.jpg)
Hands-on model checking exercisesExercise 3: Th1 to Th2 differentiation
The model should not differentiate from Th1 into Th2 under proTh2 environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-3-Th1-proTh2-Th2Act.smv
INIT Th1
INIT proTh2
SPEC EF ( Th2Act & AG ( Th2Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-3-Th1-proTh2-Th2Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th2Act & AG Th2Act) is false
10
![Page 25: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/25.jpg)
Hands-on model checking exercisesExercise 3: Th1 to Th2 differentiation
The model should not differentiate from Th1 into Th2 under proTh2 environmentalconditions. This can be stated as a reachability property to be interpreted by themodel checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-3-Th1-proTh2-Th2Act.smv
INIT Th1
INIT proTh2
SPEC EF ( Th2Act & AG ( Th2Act ))
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-3-Th1-proTh2-Th2Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (Th2Act & AG Th2Act) is false
10
![Page 26: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/26.jpg)
Hands-on model checking exercisesExercise 4: Th1 to Th2 differentiation
Could the model differentiate from Th1 into Th2 under any environmental condition?This can be stated as a reachability property to be interpreted by the model checker.
1. Create a script that calls NuSMV for all combinations of environmental conditions.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-4-Th1-x-Th2Act.sh
...
for input in $INPUTS; do
echo "INIT Th1 under $input"
cat $MODEL $STATEPATTERNS $INPUTPATTERNS init-input-$input.tmp \
init-state-Th1.tmp spec-state-Th2Act.tmp | $NuSMV -dcx 2> /dev/null\
| grep specification
done
...
2. Verify the properties running the script.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ sh prop-4-Th1-x-Th2Act.sh
INIT Th1 under i00000000
-- specification EF (Th2Act & AG Th2Act) is false
INIT Th1 under i00000001
-- specification EF (Th2Act & AG Th2Act) is false
INIT Th1 under i00000010
-- specification EF (Th2Act & AG Th2Act) is false
...
11
![Page 27: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/27.jpg)
Hands-on model checking exercisesExercise 4: Th1 to Th2 differentiation
Could the model differentiate from Th1 into Th2 under any environmental condition?This can be stated as a reachability property to be interpreted by the model checker.
1. Create a script that calls NuSMV for all combinations of environmental conditions.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-4-Th1-x-Th2Act.sh
...
for input in $INPUTS; do
echo "INIT Th1 under $input"
cat $MODEL $STATEPATTERNS $INPUTPATTERNS init-input-$input.tmp \
init-state-Th1.tmp spec-state-Th2Act.tmp | $NuSMV -dcx 2> /dev/null\
| grep specification
done
...
2. Verify the properties running the script.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ sh prop-4-Th1-x-Th2Act.sh
INIT Th1 under i00000000
-- specification EF (Th2Act & AG Th2Act) is false
INIT Th1 under i00000001
-- specification EF (Th2Act & AG Th2Act) is false
INIT Th1 under i00000010
-- specification EF (Th2Act & AG Th2Act) is false
...
11
![Page 28: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/28.jpg)
Hands-on model checking exercisesExercise 4: Th1 to Th2 differentiation
Could the model differentiate from Th1 into Th2 under any environmental condition?This can be stated as a reachability property to be interpreted by the model checker.
1. Create a script that calls NuSMV for all combinations of environmental conditions.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-4-Th1-x-Th2Act.sh
...
for input in $INPUTS; do
echo "INIT Th1 under $input"
cat $MODEL $STATEPATTERNS $INPUTPATTERNS init-input-$input.tmp \
init-state-Th1.tmp spec-state-Th2Act.tmp | $NuSMV -dcx 2> /dev/null\
| grep specification
done
...
2. Verify the properties running the script.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ sh prop-4-Th1-x-Th2Act.sh
INIT Th1 under i00000000
-- specification EF (Th2Act & AG Th2Act) is false
INIT Th1 under i00000001
-- specification EF (Th2Act & AG Th2Act) is false
INIT Th1 under i00000010
-- specification EF (Th2Act & AG Th2Act) is false
...
11
![Page 29: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/29.jpg)
Hands-on model checking exercisesExercise 5: differentiation between all T-helper cell types
We should be able to obtain the reachability between all T-helper cell types under allpossible environmental conditions (Figure 7 of Naldi et al. 2010).
1. Create a script that calls NuSMV for all combinations of environmental conditions,between all T-helper cell types.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-5-all-x-all.sh
...
for srcstate in $STATES; do
for input in $INPUTS; do
echo "INIT $srcstate under $input"
for target in $STATES; do
cat $MODEL $STATEPATTERNS $INPUTPATTERNS init-input-$input.tmp \
init-state-$srcstate.tmp spec-state-$target.tmp | $NuSMV -dcx 2> \
/dev/null | grep true
done
done
done
...
2. Verify the properties running the script.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ sh prop-5-all-x-all.sh
INIT Th0 under noStml
-- specification EF (Th0 & AG Th0) is true
INIT Th0 under APConly
-- specification EF (Th0Act & AG Th0Act) is true
INIT Th0 under proTh1a
-- specification EF (Th1Act & AG Th1Act) is true
...
12
![Page 30: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/30.jpg)
Hands-on model checking exercisesExercise 5: differentiation between all T-helper cell types
We should be able to obtain the reachability between all T-helper cell types under allpossible environmental conditions (Figure 7 of Naldi et al. 2010).
1. Create a script that calls NuSMV for all combinations of environmental conditions,between all T-helper cell types.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-5-all-x-all.sh
...
for srcstate in $STATES; do
for input in $INPUTS; do
echo "INIT $srcstate under $input"
for target in $STATES; do
cat $MODEL $STATEPATTERNS $INPUTPATTERNS init-input-$input.tmp \
init-state-$srcstate.tmp spec-state-$target.tmp | $NuSMV -dcx 2> \
/dev/null | grep true
done
done
done
...
2. Verify the properties running the script.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ sh prop-5-all-x-all.sh
INIT Th0 under noStml
-- specification EF (Th0 & AG Th0) is true
INIT Th0 under APConly
-- specification EF (Th0Act & AG Th0Act) is true
INIT Th0 under proTh1a
-- specification EF (Th1Act & AG Th1Act) is true
...
12
![Page 31: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/31.jpg)
Hands-on model checking exercisesExercise 5: differentiation between all T-helper cell types
We should be able to obtain the reachability between all T-helper cell types under allpossible environmental conditions (Figure 7 of Naldi et al. 2010).
1. Create a script that calls NuSMV for all combinations of environmental conditions,between all T-helper cell types.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-5-all-x-all.sh
...
for srcstate in $STATES; do
for input in $INPUTS; do
echo "INIT $srcstate under $input"
for target in $STATES; do
cat $MODEL $STATEPATTERNS $INPUTPATTERNS init-input-$input.tmp \
init-state-$srcstate.tmp spec-state-$target.tmp | $NuSMV -dcx 2> \
/dev/null | grep true
done
done
done
...
2. Verify the properties running the script.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ sh prop-5-all-x-all.sh
INIT Th0 under noStml
-- specification EF (Th0 & AG Th0) is true
INIT Th0 under APConly
-- specification EF (Th0Act & AG Th0Act) is true
INIT Th0 under proTh1a
-- specification EF (Th1Act & AG Th1Act) is true
...
12
![Page 32: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/32.jpg)
Hands-on model checking exercisesExercise 6: Th0 to Th1 differentiation
The model should differentiate from Th0 into Th1 under proTh1a environmentalconditions, with an activation of IL2 (IL2 = 1). This can be stated as a reachabilityproperty to be interpreted by the model checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-6-Th0-IL2-Th1Act.smv
INIT Th0
INIT proTh1a
SPEC EF (IL2=1 & EF (Th1Act & AG (Th1Act)))
SPEC E [ IL2=1 U Th1Act & AG (Th1Act)]
SPEC EF (Th1Act) & ! E [ IL2=0 U Th1Act ]
SPEC E [ IL2=0 U Th1Act & AG (Th1Act)]
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-6-Th0-IL2-Th1Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (IL2 = 1 & EF (Th1Act & AG Th1Act)) is true
-- specification E [ IL2 = 1 U (Th1Act & AG Th1Act) ] is false
-- specification (EF Th1Act & !E [ IL2 = 0 U Th1Act ] ) is false
-- specification E [ IL2 = 0 U (Th1Act & AG Th1Act) ] is true
13
![Page 33: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/33.jpg)
Hands-on model checking exercisesExercise 6: Th0 to Th1 differentiation
The model should differentiate from Th0 into Th1 under proTh1a environmentalconditions, with an activation of IL2 (IL2 = 1). This can be stated as a reachabilityproperty to be interpreted by the model checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-6-Th0-IL2-Th1Act.smv
INIT Th0
INIT proTh1a
SPEC EF (IL2=1 & EF (Th1Act & AG (Th1Act)))
SPEC E [ IL2=1 U Th1Act & AG (Th1Act)]
SPEC EF (Th1Act) & ! E [ IL2=0 U Th1Act ]
SPEC E [ IL2=0 U Th1Act & AG (Th1Act)]
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-6-Th0-IL2-Th1Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (IL2 = 1 & EF (Th1Act & AG Th1Act)) is true
-- specification E [ IL2 = 1 U (Th1Act & AG Th1Act) ] is false
-- specification (EF Th1Act & !E [ IL2 = 0 U Th1Act ] ) is false
-- specification E [ IL2 = 0 U (Th1Act & AG Th1Act) ] is true
13
![Page 34: Hands-on session Model checking logical regulatory …compbio.igc.gulbenkian.pt/nmd/sites/compbio.igc...Hands-on session Model checking logical regulatory networks Pedro T. Monteiro](https://reader034.fdocuments.net/reader034/viewer/2022042110/5e8ac3d99be23b0d8f21ceea/html5/thumbnails/34.jpg)
Hands-on model checking exercisesExercise 6: Th0 to Th1 differentiation
The model should differentiate from Th0 into Th1 under proTh1a environmentalconditions, with an activation of IL2 (IL2 = 1). This can be stated as a reachabilityproperty to be interpreted by the model checker.
1. Create a NuSMV specification file that verifies this behaviour.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat prop-6-Th0-IL2-Th1Act.smv
INIT Th0
INIT proTh1a
SPEC EF (IL2=1 & EF (Th1Act & AG (Th1Act)))
SPEC E [ IL2=1 U Th1Act & AG (Th1Act)]
SPEC EF (Th1Act) & ! E [ IL2=0 U Th1Act ]
SPEC E [ IL2=0 U Th1Act & AG (Th1Act)]
2. Verify the property using NuSMV.
VirtualBox:~/Desktop/Tutorial/ModelChecking$ cat th-reduced-model.smv \
th-reduced-state-patterns.smv th-reduced-input-patterns.smv \
prop-6-Th0-IL2-Th1Act.smv | NuSMV-2.4.3 -ctlei -dcx
-- specification EF (IL2 = 1 & EF (Th1Act & AG Th1Act)) is true
-- specification E [ IL2 = 1 U (Th1Act & AG Th1Act) ] is false
-- specification (EF Th1Act & !E [ IL2 = 0 U Th1Act ] ) is false
-- specification E [ IL2 = 0 U (Th1Act & AG Th1Act) ] is true
13