EE1J2 Discrete Maths Lecture 2 - PowerPoint PPT Presentation

1 / 27
About This Presentation
Title:

EE1J2 Discrete Maths Lecture 2

Description:

Formalisation of NL grammatical analysis, production rules, parsing, ... The English word or' can be ambiguous. ... Remember grammar lessons in primary school? ... – PowerPoint PPT presentation

Number of Views:23
Avg rating:3.0/5.0
Slides: 28
Provided by: elec3
Category:

less

Transcript and Presenter's Notes

Title: EE1J2 Discrete Maths Lecture 2


1
EE1J2 Discrete Maths Lecture 2
  • Tutorials
  • Revision of formalisation
  • Interpreting logical statements in NL
  • Form and Content of an Argument
  • Formalisation of NL grammatical analysis,
    production rules, parsing, parse trees
  • Propositional logic as a formal language
    symbols and formulae
  • Parsing and parse trees in Propositional Logic,

2
Tutorial arrangements
  • 3 Tutorial groups X, Y and Z
  • Thursdays 3pm, starting 31st January
  • X Room 220/221, A Teye
  • Y Room 523, K Hussein
  • Z Room 521/522, G Philips
  • Hand in work Tuesday before tutorial
  • Drawers marked X, Y, Z downstairs

3
Revision - formalisation
  • Either Arsenal, Leeds, Liverpool, or ManU will
    win the league. If neither ManU nor Arsenal win
    it, then Liverpool will win. If Leeds or
    Liverpool fail to win, then Arsenal will not win
    and ManU will win it.

4
Elementary propositions
  • A Arsenal will win the league
  • L Leeds will win the league
  • P Liverpool will win the league
  • M ManU will win the league

5
Formalised statement
  • Either Arsenal, Leeds, Liverpool, or ManU will
    win the league
  • (A ? L ? P ? M)
  • If neither ManU nor Arsenal win it, then
    Liverpool will win
  • ((?M ? ?A) ? P)
  • If Leeds or Liverpool fail to win, then Arsenal
    will not win and ManU will win it.
  • ((?L ? ?P) ?(?A ? M))

6
Formalised Statement
  • (A ? L ? P ? M) ? ((?M ? ?A) ? P) ? ((?L ? ?P)
    ?(?A ? M))

7
Formalisation (continued)
  • Statement
  • If Polonius is not behind that curtain then
    Polonius is well
  • Atomic propositions
  • C Polonius is behind that curtain
  • W Polonius is well
  • Formalisation in Propositional Logic
  • (?C) ? W

8
Interpreting logical statements in NL
9
Example
  • Consider the statement p ? q ? ?r ? ?s where
  • p the thief is young
  • q the thief is hanged
  • r the thief will grow old
  • s the thief will steal
  • In NL, this equates to if the thief is young
    and the thief is hanged, then the thief will
    neither grow old nor steal

10
Exclusive and inclusive OR
  • The English word or can be ambiguous. The two
    possible meanings are denoted by inclusive or and
    exclusive or
  • Inclusive or is represented by the propositional
    connective ?
  • Exclusive or is represented by
  • (p? q) ? ?(p? q)

11
Separating Form and Content
  • If I play cricket or go to work, but not both,
    then I will not be going shopping. Therefore, if
    I go shopping then neither would I play cricket
    nor would I go to work
  • An object remaining stationary or moving at a
    constant velocity means that there is no external
    force acting upon it. Therefore, if there is a
    force acting upon the object, it is not
    stationary and it is not moving at a constant
    velocity

12
Form and Content
  • Although the content is different, the forms are
    the same

13
Argument 1
  • If I play cricket or go to work, but not both,
    then I will not be going shopping. Therefore, if
    I go shopping then neither would I play cricket
    nor would I go to work.
  • Atomic Propositions
  • P I play cricket
  • Q I go to work
  • R I go shopping
  • Formal Argument
  • ((P? Q) ? ?(P? Q) ? ?R)?(R?(?P)?(?Q))

14
Argument 2
  • An object remaining stationary or moving at a
    constant velocity means that there is no external
    force acting upon it. Therefore, if there is a
    force acting upon the object, it is not
    stationary and it is not moving at a constant
    velocity
  • Atomic propositions
  • S the object is stationary
  • M the object is moving at a constant velocity
  • F there is an external force acting upon the
    object

15
Argument 2 (cont.)
  • Atomic propositions
  • S the object is stationary
  • M the object is moving at a constant velocity
  • F there is an external force acting upon the
    object
  • Formal Argument
  • ((S? M) ? ?(S? M) ? ?F)?(F?(?S)? (?M))

16
Re-cap
  • Propositional logic motivated by analogies with
    natural language
  • Formalisation of statements in NL
  • Naturalisation of formulae in PL
  • Separation of form and meaning
  • Now move on to study propositional logic as a
    formal language
  • What is a formal language?

17
Formalisation of Natural Language
  • Remember grammar lessons in primary school?
  • The purpose is to expose the underlying
    grammatical or syntactic structure of the
    sentence
  • Or, to decide whether the given sentence is
    grammatical (i.e. in the language)

18
Grammatical analysis in NL
  • Consider S The cat devoured the tiny mouse
  • S is made up of of
  • the noun phrase NP The cat, and
  • the verb phrase VP devoured the tiny mouse

19
Grammatical Analysis
  • NP comprises the determiner The and the noun
    cat
  • VP comprises the verb devoured and the noun
    phrase the tiny mouse
  • The noun phrase the tiny mouse comprises the
    determiner the, the adjective tiny, and the
    noun mouse

20
Production Rules
  • Formally, this analysis of the sentence is with
    respect to a set of production rules
  • Production rules determine how non-terminal
    elements in a language can be expanded into
    sequences of non-terminal elements and terminal
    elements.
  • The non-terminals are structures like sentence,
    noun-phrase, verb-phrase, adjective, etc
  • The terminals are actual words

21
Production Rules
  • The first production rule which we used was
  • S ? NP VP
  • Then we applied more production rules, formally
    denoted as
  • NP ? DET N
  • VP ? V NP
  • NP ? DET ADJ N

22
Parsing
  • This process is called parsing
  • The sequence of production rules which transforms
    S into the sequence of words in the sentence is a
    parse of the sentence.

23
Grammatical sentences
  • In a formal language, a sequence of words is
  • a sentence in the language
  • or is grammatical
  • if and only if
  • a parse of the word sequence exists

24
Parse Trees
  • The parse of the sentence The cat devoured the
    tiny mouse given by the above set of production
    rules can be represented simply, intuitively and
    usefully as a tree structure
  • This tree structure is called a parse tree

25
Parse Tree for the cat devoured the tiny mouse
26
Parsing in NL
  • The bases of the branches of the tree correspond
    to non-terminal units of the language.
  • The leaves of the tree correspond to the
    terminal unit.
  • Local structure of the tree at a non-terminal
    unit corresponds to the production rule employed
    in the parse

27
Summary of Lecture 2
  • Revision of formalisation
  • Interpreting logical statements in NL
  • Form and Content of an Argument
  • Formalisation of NL grammatical analysis,
    production rules, parsing, parse trees
  • Propositional logic as a formal language
    symbols and formulae
  • Parsing a formula in Propositional Logic
Write a Comment
User Comments (0)
About PowerShow.com