Question: Consider the following partial Alloy model, then answer the following questions. abstract sig Person { } father: set Person, mother: set Person, children: set
Consider the following partial Alloy model, then answer the following questions. abstract sig Person { } father: set Person, mother: set Person, children: set Person sig Man extends Person { } wife: set Person sig Woman extends Person { } husband: set Person a) Write a constraint for the assertion "the father and children of a person are different" as an assert. b) Write a constraint for the assertion "a person doesn't have more than one father" as an assert. c) Write a constraint for the assertion "the father of a person is a man" as an assert. d) Write a constraint for the assertion "a person isn't his/her own descendant" as an assert. e) Write a constraint for the assertion "the mother of a person is his/her father's wife" as an assert.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
