SMT-BASED ANALYSIS OF BIOLOGICAL SYSTEMS
Nicola Paoletti
CS department, Oxford University Molecular Programming and Biological Computation reading group
8th June 2016
SMT-BASED ANALYSIS OF BIOLOGICAL SYSTEMS Nicola Paoletti CS - - PowerPoint PPT Presentation
SMT-BASED ANALYSIS OF BIOLOGICAL SYSTEMS Nicola Paoletti CS department, Oxford University Molecular Programming and Biological Computation reading group 8 th June 2016 Motivation Information processing in biosystems Biological computation
SMT-BASED ANALYSIS OF BIOLOGICAL SYSTEMS
Nicola Paoletti
CS department, Oxford University Molecular Programming and Biological Computation reading group
8th June 2016
Medicine in 2050: “Doctor in a Cell”
Programmable Computer Molecular Input
computers can fit into a drop of water?”
Dunn, S-J., et al, Science 344.6188 (2014): 1156-1160.
NOT TODAY TODAY
Boolean Satisfiability Problem (SAT)
satisfiable? + Truth assignment
and logic circuits
φ = (x1 ∨ ¬x2) ∧ x2
φ
Satisfiability Modulo Theories Problem (SMT)
background theories
satisfiable? + Interpretation of free variables in their respective domains
φ
φ = x1 ≤ x2 = ⇒ f(x1) ≤ f(x2)
predicate and constant) symbols
well in practice
Satisfiability Modulo Theories Problem (SMT)
background theories
satisfiable? + Interpretation of free variables in their respective domains
φ
φ = x1 ≤ x2 = ⇒ f(x1) ≤ f(x2)
COMMON (LAZY) APPROACH:
and conjunction of atomic propositions
COMMON (LAZY) APPROACH:
and conjunction of atomic propositions
APPLICATIONS (in CS):
a > b + 2 ∧ a = 2 · c + 10 ∧ b + c ≤ 1000
SAT, [a = 10, b = 0, c = 0]
UNSAT
x · x = x + 2.0 ∧ x · y = x ∧ (y − 1.0) · z = 1.0
¬((x & y) = (x | y))
Validity of De Morgan’s law:
UNSAT Play with http://rise4fun.com/Z3/tutorial/
a.b = “abc”.a[1]
SAT, [a = ‘bcc’, b = ‘a’]
Play with http://rise4fun.com/Z3/tutorial/
f(10) > f(2) ∧ f(10) > f(a)
SAT, [a = 3, f(x) = {0 if x=10, -1 if x=2, -1 if x=3, -1 otherwise} ]
Ø Less conventional, but useful
property and finding SAT assignment
I(ρ[0]) ∧ ^
0≤i<k
T(ρ[i], ρ[i + 1]) ∧ _
0≤i<k
¬φ(ρ[i])
INVARIANT/SAFETY PROPERTY
property and finding SAT assignment
I(ρ[0]) ∧ ^
0≤i<k
T(ρ[i], ρ[i + 1]) ∧ _
0≤i<k
¬φ(ρ[i])
INVARIANT/SAFETY PROPERTY
xi[j]
φ(x) = ¬x[0] ∨ ¬x[1]
(it always holds that at least one of the two bits is 0) (counter set to 00)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
I(x) = ¬x[0] ∧ ¬x[1]
x0[0] x0[1] x0 x1[0] x1[1] x1 x2[0] x2[1] x2 x3[0] x3[1] x3
φ(x) = ¬x[0] ∨ ¬x[1]
T(x0,x1)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
T(x1,x2) T(x2,x3)
I(x) = ¬x[0] ∧ ¬x[1]
x0[0] x0[1] x0 x1[0] x1[1] x1 x2[0] x2[1] x2 x3[0] x3[1] x3
φ(x) = ¬x[0] ∨ ¬x[1]
T(x0,x1)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
T(x1,x2) T(x2,x3)
I(x0) ∧ ^
0≤i<3
T(xi, xi+1) ∧ _
0≤i≤3
¬φ(xi)
NEED TO CHECK:
I(x) = ¬x[0] ∧ ¬x[1]
x0[0] x0[1] x0 x1[0] x1[1] x1 x2[0] x2[1] x2 x3[0] x3[1] x3
φ(x) = ¬x[0] ∨ ¬x[1]
T(x0,x1)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
T(x1,x2) T(x2,x3) Step 1: I(x0) ∧ ¬φ(x0)
I(x) = ¬x[0] ∧ ¬x[1]
[UNSAT, safe so far]
x0[0] x0[1] x0 x1[0] x1[1] x1 x2[0] x2[1] x2 x3[0] x3[1] x3
φ(x) = ¬x[0] ∨ ¬x[1]
T(x0,x1)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
T(x1,x2) T(x2,x3) Step 1: I(x0) ∧ ¬φ(x0)
I(x0) ∧ T(x0, x1) ∧ ¬φ(x1)
Step 2:
I(x) = ¬x[0] ∧ ¬x[1]
[UNSAT, safe so far] [UNSAT, safe so far]
x0[0] x0[1] x0 x1[0] x1[1] x1 x2[0] x2[1] x2 x3[0] x3[1] x3
φ(x) = ¬x[0] ∨ ¬x[1]
T(x0,x1)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
T(x1,x2) T(x2,x3) Step 1: I(x0) ∧ ¬φ(x0)
I(x0) ∧ T(x0, x1) ∧ ¬φ(x1) I(x0) ∧ T(x0, x1) ∧ T(x1, x2) ∧ ¬φ(x2)
Step 2: Step 3:
I(x) = ¬x[0] ∧ ¬x[1]
[UNSAT, safe so far] [UNSAT, safe so far] [UNSAT, safe so far]
x0[0] x0[1] x0 x1[0] x1[1] x1 x2[0] x2[1] x2 x3[0] x3[1] x3
φ(x) = ¬x[0] ∨ ¬x[1]
T(x0,x1)
T(x, x0) = (x0[1] = x[1] ⊕ x[0]) ∧ (x0[0] = ¬x[0])
T(x1,x2) T(x2,x3) Step 1: I(x0) ∧ ¬φ(x0)
I(x0) ∧ T(x0, x1) ∧ ¬φ(x1) I(x0) ∧ T(x0, x1) ∧ T(x1, x2) ∧ ¬φ(x2) I(x0) ∧ T(x0, x1) ∧ T(x1, x2) ∧ T(x2, x3) ∧ ¬φ(x3)
Step 2: Step 3: Step 4: [UNSAT, safe so far] [UNSAT, safe so far] [UNSAT, safe so far] [SAT, CE found: x3[0]=1, x3[1]=1, …]
I(x) = ¬x[0] ∧ ¬x[1]
longest loop-free path
longest loop-free path
In practice…
with minimal length
satisfying the property.
(I(p), T(p))
∃~ p. @I(~ p, ⇢[0]) ∧ ^
0≤i<k
T(~ p, ⇢[i], ⇢[i + 1]) ∧ ^
0≤i≤k
(⇢[i]) 1 A
SYNTHESIS WITH INVARIANT PROPERTY
satisfying the property.
(I(p), T(p))
I(ρ[0]) ∧ ^
0≤i<k
T(ρ[i], ρ[i + 1]) ∧ _
0≤i<k
¬φ(ρ[i])
INVARIANT VERIFICATION
∃~ p. @I(~ p, ⇢[0]) ∧ ^
0≤i<k
T(~ p, ⇢[i], ⇢[i + 1]) ∧ ^
0≤i≤k
(⇢[i]) 1 A
SYNTHESIS WITH INVARIANT PROPERTY
T(x, x0) = (x0 = x4c), 4 2 {+, , |, &, . . .}
T(op, c, x, x0) = x0 = x + c if op = 0 x0 = x − c if op = 1 x0 = −x if op = 2 . . . . . . x0 = x NAND c
φ(x, x0) = x > x0
I(x) = x > 6
∃op, c. I(ρ[0]) ∧ ^
0≤i<3
T(op, c, ρ[i], ρ[i + 1]) ∧ ^
0≤i<3
φ(ρ[i], ρ[i + 1])
NEED TO CHECK:
φ(x, x0) = x > x0
I(x) = x > 6
[SAT, op=1, c=1, …] à T(x, x0) = (x0 = x − 1) ∃op, c. I(ρ[0]) ∧ ^
0≤i<3
T(op, c, ρ[i], ρ[i + 1]) ∧ ^
0≤i<3
φ(ρ[i], ρ[i + 1])
NEED TO CHECK:
consumed and produced
(S, R) r = (Rr, Pr)
[Yordanov et al, DNA19], [Dachau et al, DNA21]
in state q
T = (Q, q0, T)
q(s)
in state q
reactants:
T = (Q, q0, T)
q(s)
enabled(r, q) = ^
s∈S
q(s) ≥ Rr(s)
in state q
reactants:
T = (Q, q0, T)
q(s)
enabled(r, q) = ^
s∈S
q(s) ≥ Rr(s)
terminal(q) = ^
r∈R
¬enabled(r, q)
in state q
reactants:
T = (Q, q0, T)
q(s)
enabled(r, q) = ^
s∈S
q(s) ≥ Rr(s)
terminal(q) = ^
r∈R
¬enabled(r, q)
T(q, q0) = _
r2R
enabled(r, q) ∧ ^
s2S
q0(s) = q(s) + Pr(s) − Rr(s) !
Displacement (DSD) circuits
computation occurs through DNA strands interacting following base pairing rules
BMC-BASED ANALYSIS (Intuition)
^
0≤i<k
T(xi, xi+1) ∧ terminal(xk) ∧ P(x0, xk)
AND, OR
stoichiometry constants
Majority and Division
∃r1, . . . , rn. ^
0≤i<k
T(xi, xi+1) ∧ terminal(xk) ∧ P(x0, xk)
(from SAT to SMT, examples)
(approach, limitations, alternatives, verification and synthesis, examples)
(SMT encoding, DSD circuit verification, CRNs synthesis)
SMT overview
De Moura, Leonardo, and Nikolaj Bjørner. "Satisfiability modulo theories: An appetizer." Formal Methods: Foundations and Applications, 2009. 23-36. Barrett, Clark W., et al. "Satisfiability Modulo Theories." Handbook of satisfiability 185 (2009): 825-885.
Bounded model checking and others
Biere, Armin, et al. "Symbolic Model Checking without BDDs." Tools and Algorithms for the Construction of Analysis of Systems: 5th International Conference, TACAS'99, Springer, 1999. Clarke, Edmund, et al. "Computational challenges in bounded model checking." International Journal on Software Tools for Technology Transfer 7.2 (2005): 174-183. Amla, Nina, et al. "An analysis of SAT-based model checking techniques in an industrial environment." Correct hardware design and verification methods, 2005. 254-268.
SMT + biological networks
Yordanov, Boyan, et al. "Functional analysis of large-scale DNA strand displacement circuits." DNA Computing and Molecular Programming. Springer International Publishing, 2013. 189-203. Dalchau, Neil, et al. "Synthesizing and tuning chemical reaction networks with specified behaviours." DNA Computing and Molecular Programming. Springer International Publishing, 2015. 16-33. Paoletti, Nicola, et al. "Analyzing and synthesizing genomic logic functions." Computer Aided Verification. Springer International Publishing, 2014.
Dunn, S-J., et al. "Defining an essential transcription factor program for naïve pluripotency." Science 344.6188 (2014): 1156-1160.