2
; Error model (section 4.1)
3
; -------------------------
6
(include-book "arithmetic-3/top" :dir :system)
7
(include-book "make-event/defspec" :dir :system)
10
(defthm thm-natp-add-type
11
(implies (and (natp n) (natp m))
14
; definition of an error in a register of type natp
15
; -------------------------------------------------
19
(((STD-natp-error *) => *))
21
(local (defun STD-natp-error (x)
26
(defthm STD-natp-type1 ; returns a natp
28
(natp (STD-natp-error x))))
30
(defthm STD-natp-type2 ; takes a natp
31
(implies (not (natp x))
32
(equal (STD-natp-error x)
35
(defthm STD-natp-def ; fault-injection is actual
37
(not (equal (STD-natp-error x)
40
; the third property (only one memorizing element differs)
41
; is explicitly expressed in each component
44
; Note: similar definitions can be given for other types of
45
; memorizing elements (boolean, integer,...)