Example solution based on the novel ''Jane Eyre'': Difference between revisions

From Lexical Resource Semantics
Jump to navigation Jump to search
No edit summary
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
== Task 5: Variables  ==
= Task 5: Variables  =


1. Provide a variable assignment function g which maps the variables ''x<sub>1</sub>, ..., x<sub>10</sub>'' to members of your
1. Provide a variable assignment function g which maps the variables ''x<sub>1</sub>, ..., x<sub>10</sub>'' to members of your
Line 8: Line 8:
3. Compute the truth value of this formula with respect to your assingment function g.
3. Compute the truth value of this formula with respect to your assingment function g.


== Variable assignment function ==
== 1. Variable assignment function ==


* g(x<sub>1</sub>) = ''JaneEyre''
* g(x<sub>1</sub>) = ''JaneEyre''
Line 21: Line 21:
* g(x<sub>10</sub>) = ''JaneEyre''
* g(x<sub>10</sub>) = ''JaneEyre''


== One formulae with two occurrences of variables ==
== 2. One formulae with two occurrences of variables ==


Formula: '''family-of(st.john,'''x<sub>9</sub>''') &and; female('''x<sub>7</sub>''')'''
Formula: '''family-of(st.john,'''x<sub>9</sub>''') &and; female('''x<sub>7</sub>''')'''


 
== 3. Interpretation of the formula ==
 
== Interpretation of the formula ==


Given the model from the earlier tasks and the variable assignment function g, we can compute the truth of the formula as follows:
Given the model from the earlier tasks and the variable assignment function g, we can compute the truth of the formula as follows:
Line 36: Line 34:
iff < ''St.John'',''JaneEyre'' > &isin; I('''family-of''') and < ''BerthaMason'' > &isin; I('''female''')
iff < ''St.John'',''JaneEyre'' > &isin; I('''family-of''') and < ''BerthaMason'' > &isin; I('''female''')


Since both conditions are met, the formula is true.




<hr />
<hr />
Back to the [[Assignmentsheet_Logic_Summer_Term_2013|assignment sheet of Chapter 2]].
Back to the [[Assignmentsheet_Logic_Summer_Term_2013|assignment sheet of Chapter 2]].

Latest revision as of 22:56, 28 June 2013

Task 5: Variables

1. Provide a variable assignment function g which maps the variables x1, ..., x10 to members of your universe.

2. Provide one formula that contains two occurrences of variables.

3. Compute the truth value of this formula with respect to your assingment function g.

1. Variable assignment function

  • g(x1) = JaneEyre
  • g(x2) = JaneEyre
  • g(x3) = MrRochester
  • g(x4) = MrRochester
  • g(x5) = BerthaMason
  • g(x6) = St.John
  • g(x7) = BerthaMason
  • g(x8) = MrRochester
  • g(x9) = JaneEyre
  • g(x10) = JaneEyre

2. One formulae with two occurrences of variables

Formula: family-of(st.john,x9) ∧ female(x7)

3. Interpretation of the formula

Given the model from the earlier tasks and the variable assignment function g, we can compute the truth of the formula as follows:

[[family-of(st.john,x9) ∧ female(x7)]]g = 1
iff [[family-of(st.john,x9)]]g = 1 and [[female(x7)]]g = 1
iff < I(st.john),g(x9) > ∈ I(family-of) and < g(x7) > ∈ I(female)
iff < St.John,JaneEyre > ∈ I(family-of) and < BerthaMason > ∈ I(female)

Since both conditions are met, the formula is true.



Back to the assignment sheet of Chapter 2.