Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Let L be the well-known standard language of propositional logic. Now we define the language LRP of propositional formulas in Reverse Polish notation, as follows:

image text in transcribed

Let L be the well-known standard language of propositional logic. Now we define the language LRP of propositional formulas in Reverse Polish notation, as follows: i Each propositional atom p; is a well-formed reverse Polish formula in LRP. ii If A and B are well-formed reverse Polish formulas in LRP, then so are A-, ABA, ABV, AB + and AB H. iii Nothing is a well-formed reverse Polish formula in LRP unless it is generated by finitely many repeated applications of i and ii. So reverse Polish notation gives a postfix-version without parentheses of propositional formulas. For example, the formula Pi-P2A in reverse Polish notation is logically equivalent to the formula Pi AP2) in standard notation. 1. Is P1 P2 - V P2 P3 A + a well-formed reverse Polish formula in LRP? Why (not)? 2. Show by induction that every well-formed formula P in the language L of propositional logic is equivalent to a well-formed formula P' in reverse Polish notation in LRP Prove this in two steps: (a) Define P' by induction on well-formed formulas of propositional logic. (b) Prove by induction that for every formula P of propositional logic, P is logically equivalent to P, that is, for all valuations v, v(P) = v(P). Explicitly formulate an induction hypothesis. (Here, you may assume that someone else has already proved by induction that for every well-formed propositional formula P in L, the formula P' is in LRP.) Let L be the well-known standard language of propositional logic. Now we define the language LRP of propositional formulas in Reverse Polish notation, as follows: i Each propositional atom p; is a well-formed reverse Polish formula in LRP. ii If A and B are well-formed reverse Polish formulas in LRP, then so are A-, ABA, ABV, AB + and AB H. iii Nothing is a well-formed reverse Polish formula in LRP unless it is generated by finitely many repeated applications of i and ii. So reverse Polish notation gives a postfix-version without parentheses of propositional formulas. For example, the formula Pi-P2A in reverse Polish notation is logically equivalent to the formula Pi AP2) in standard notation. 1. Is P1 P2 - V P2 P3 A + a well-formed reverse Polish formula in LRP? Why (not)? 2. Show by induction that every well-formed formula P in the language L of propositional logic is equivalent to a well-formed formula P' in reverse Polish notation in LRP Prove this in two steps: (a) Define P' by induction on well-formed formulas of propositional logic. (b) Prove by induction that for every formula P of propositional logic, P is logically equivalent to P, that is, for all valuations v, v(P) = v(P). Explicitly formulate an induction hypothesis. (Here, you may assume that someone else has already proved by induction that for every well-formed propositional formula P in L, the formula P' is in LRP.)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions