程序代写代做代考 Haskell 11/9/2020 Grok | COMP30026 Practice Exam

11/9/2020 Grok | COMP30026 Practice Exam
Queson 3
Queson 3 Part B (2 marks)
For parts A, B, and C, consider these closed first-order predicate logic formulas and :
: :
Part B (2 marks)
Show that is not valid.
Show this by giving an interpretaon involving the finite domain of three objects
. That is, give a definion of the two-place predicate which, along with
this domain, is a countermodel for .
Note: This part asks about (the previous part asks about ).
Instrucons
Define asaHaskellfunconpredicateP :: Domain -> Domain -> Bool.  Format
You can use any available Haskell syntax to define your funcon. You should make sure that:
predicateP x yevaluatesto ,and
predicateP x yisdefinedforallvaluesofxandyfromthedomain.
The objects in the domain have type Domain, which derives familiar typeclasses such as Ord and Eq, so you can even use ==, <, and other standard operaons to compare elements. For example, either of the following two snippets define the predicate : predicateP x y = not (x == y) predicateP A A = False predicateP B B = False di l https://groklearning.com/learn/unimelb-comp30026-2020-s2/prac-exam/6/ 1/1 Cheng F G∧F G∨F G∨F P }C ,B ,A{ G∨F )y,x(P ))x,y(P⇒)y,x(P(y∀x∀ G )x,x(Px∀ F )y ≠ x( : )y,x(P P G