Debian Codegraph @

test/regress/cli/regress1/bags/table_join1.smt2

raw
1 (set-logic HO_ALL)
2
3 (set-info :status sat)
4
5 (declare-fun Departments () (Table Int String))
6 (declare-fun Students () (Table Int String Int))
7 (declare-fun DepartmentStudents () (Table Int String Int String Int))
8
9 (assert
10 (= Departments
11 (bag.union_disjoint
12 (bag (tuple 1 "Computer") 1)
13 (bag (tuple 2 "Engineering") 1))))
14
15 (assert
16 (= Students
17 (bag.union_disjoint
18 (bag (tuple 1 "A" 1) 1)
19 (bag (tuple 2 "B" 1) 1)
20 (bag (tuple 3 "C" 2) 1))))
21
22 ;(define-fun DepartmentStudents () (Bag (Tuple Int String Int String Int))
23 ; (bag.union_disjoint (bag (tuple 1 "Computer" 1 "A" 1) 1)
24 ; (bag (tuple 1 "Computer" 2 "B" 1) 1)
25 ; (bag (tuple 2 "Engineering" 3 "C" 2) 1)))
26
27 (assert (= DepartmentStudents ((_ table.join 0 2) Departments Students)))
28
29 (check-sat)