diff --git a/networks.rkt b/networks.rkt index 28c5d64..5765165 100644 --- a/networks.rkt +++ b/networks.rkt @@ -174,6 +174,10 @@ ;;; state. (define update-function/c (-> state? any/c)) +;;; A domain mapping is a hash set mapping variables to the lists of +;;; values in their domains. +(define domain-mapping/c (hash/c variable? list?)) + ;;; A network consists of a mapping from its variables to its update ;;; variables, as a well as of a mapping from its variables to ;;; their domains. @@ -334,10 +338,6 @@ (check-false (has-edge? ig 'c 'b)) (check-false (has-edge? ig 'c 'a)))) -;;; A domain mapping is a hash set mapping variables to the lists of -;;; values in their domains. -(define domain-mapping/c (hash/c variable? list?)) - ;;; Given a hash-set mapping variables to generic sets of their ;;; possible values, constructs the list of all possible states. (define (build-all-states vars-domains)