{"id":223518,"date":"2025-06-02T03:30:07","date_gmt":"2025-06-02T03:30:07","guid":{"rendered":"https:\/\/learnexams.com\/blog\/?p=223518"},"modified":"2025-06-02T03:30:09","modified_gmt":"2025-06-02T03:30:09","slug":"well-formed-formulas-wffs-are-defined-recursively-as-follows","status":"publish","type":"post","link":"https:\/\/www.learnexams.com\/blog\/2025\/06\/02\/well-formed-formulas-wffs-are-defined-recursively-as-follows\/","title":{"rendered":"Well-formed formulas (wffs) are defined recursively as follows"},"content":{"rendered":"\n<p>Well-formed formulas (wffs) are defined recursively as follows: T is a wff. F is a wff. Any proposition variable is a wff. If X is a wff, then (~X) is also a wff. If X and Y are wffs, then (X ^ Y) is also a wff. If X and Y are wffs, then (X V Y) is also a wff. We say that a formula is in De Morgan normal form if it satisfies the following conditions. (&#8220;De Morgan normal form&#8221; is not standard terminology; I just made it up.) Every negation in the formula is applied to a variable, not to a more complicated subformula. Either the entire formula is T, or the formula does not contain T. Either the entire formula is F, or the formula does not contain F. Prove that for every wff, there is a logically equivalent wff in De Morgan normal form. For example, the well-formed formula (~((p ^ q) V ~))^(-(p V ~) ^ q) is logically equivalent to the following wff in De Morgan normal form: (((-p V -q) ^ r))^((-P A) ^ q)<br>Well-formed formulas (wffs) are defined recursively as follows: T is a wff. F is a wff. Any proposition variable is a wff. If X is a wff, then (~X) is also a wff. If X and Y are wffs, then (X ^ Y) is also a wff. If X and Y are wffs, then (X V Y) is also a wff. We say that a formula is in De Morgan normal form if it satisfies the following conditions. (&#8220;De Morgan normal form&#8221; is not standard terminology; I just made it up.) Every negation in the formula is applied to a variable, not to a more complicated subformula. Either the entire formula is T, or the formula does not contain T. Either the entire formula is F, or the formula does not contain F. Prove that for every wff, there is a logically equivalent wff in De Morgan normal form. For example, the well-formed formula (~((p ^ q) V ~))^(-(p V ~) ^ q) is logically equivalent to the following wff in De Morgan normal form: (((-p V -q) ^ r))^((-P A) ^ q)<\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-ast-global-color-0-color\">The Correct Answer and Explanation is:<\/mark><\/strong><\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Theorem:<\/strong><\/h3>\n\n\n\n<p>For every well-formed formula (wff) in propositional logic, there exists a logically equivalent formula in <strong>De Morgan normal form (DMNF)<\/strong>.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Proof Outline (Structural Induction):<\/strong><\/h3>\n\n\n\n<p>We proceed by <strong>structural induction<\/strong> on the formation of wffs.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>Base Cases:<\/strong><\/h4>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>T<\/strong> and <strong>F<\/strong> are trivially in De Morgan normal form (DMNF), as they satisfy the condition that the entire formula is T or F or contains neither.<\/li>\n\n\n\n<li>Any <strong>propositional variable<\/strong> is in DMNF.<\/li>\n\n\n\n<li>A <strong>negated variable<\/strong>, e.g., <code>~p<\/code>, is in DMNF because negation applies directly to a variable.<\/li>\n<\/ol>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>Inductive Step:<\/strong><\/h4>\n\n\n\n<p>Assume wffs <code>X<\/code> and <code>Y<\/code> have logically equivalent formulas <code>X'<\/code> and <code>Y'<\/code> in DMNF. We must show that:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>~X<\/code>, <code>(X ^ Y)<\/code>, and <code>(X V Y)<\/code> also have logically equivalent formulas in DMNF.<\/li>\n<\/ul>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Negation:<\/strong>\n<ul class=\"wp-block-list\">\n<li>If <code>X<\/code> is a variable \u2192 <code>~X<\/code> is already in DMNF.<\/li>\n\n\n\n<li>If <code>X<\/code> is a negation <code>~Y<\/code> \u2192 <code>~(~Y)<\/code> \u2261 <code>Y<\/code> (double negation elimination).<\/li>\n\n\n\n<li>If <code>X = (A ^ B)<\/code>, then <code>~(A ^ B)<\/code> \u2261 <code>~A V ~B<\/code> (De Morgan&#8217;s Law).<\/li>\n\n\n\n<li>If <code>X = (A V B)<\/code>, then <code>~(A V B)<\/code> \u2261 <code>~A ^ ~B<\/code> (De Morgan&#8217;s Law).<br>Apply the inductive hypothesis recursively to subformulas so all negations apply only to variables.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>Conjunction and Disjunction:<\/strong>\n<ul class=\"wp-block-list\">\n<li>Given <code>X \u2261 X'<\/code> and <code>Y \u2261 Y'<\/code> in DMNF, then <code>(X ^ Y) \u2261 (X' ^ Y')<\/code>, and <code>(X V Y) \u2261 (X' V Y')<\/code> are also in DMNF.<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Conclusion:<\/strong><\/h3>\n\n\n\n<p>By recursively applying <strong>De Morgan\u2019s laws<\/strong> and <strong>double negation elimination<\/strong>, we can push negations down to the level of propositional variables. This transformation eliminates any negation of compound formulas. Furthermore, if T or F appears inside a formula (not as the entire formula), we can apply logical equivalences (e.g., <code>T ^ X \u2261 X<\/code>, <code>F V X \u2261 X<\/code>, etc.) to eliminate them. Therefore, every wff has a logically equivalent formula in De Morgan normal form.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Example:<\/strong><\/h3>\n\n\n\n<p>Given wff:<br><code>~((p ^ q) V r) ^ (~(p V s) ^ q)<\/code><\/p>\n\n\n\n<p>Apply De Morgan:<br>\u2192 <code>(\u00ac(p ^ q) \u2227 \u00acr) \u2227 ((\u00acp \u2227 \u00acs) \u2227 q)<\/code><br>\u2192 <code>((\u00acp \u2228 \u00acq) \u2227 \u00acr) \u2227 ((\u00acp \u2227 \u00acs) \u2227 q)<\/code> \u2190 in DMNF (negations apply only to variables)<\/p>\n\n\n\n<p>This proves the transformation is always possible.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/learnexams.com\/blog\/wp-content\/uploads\/2025\/06\/learnexams-banner4-90.jpeg\" alt=\"\" class=\"wp-image-223519\"\/><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>Well-formed formulas (wffs) are defined recursively as follows: T is a wff. F is a wff. Any proposition variable is a wff. If X is a wff, then (~X) is also a wff. If X and Y are wffs, then (X ^ Y) is also a wff. If X and Y are wffs, then (X [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[25],"tags":[],"class_list":["post-223518","post","type-post","status-publish","format-standard","hentry","category-exams-certification"],"_links":{"self":[{"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/posts\/223518","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/comments?post=223518"}],"version-history":[{"count":0,"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/posts\/223518\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/media?parent=223518"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/categories?post=223518"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.learnexams.com\/blog\/wp-json\/wp\/v2\/tags?post=223518"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}