- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

# How to show that the regular language is closed under the complementary operation?

**Closure property** is a technique to understand the class of the resulting language when we are performing an operation on two languages of the same class.

That means, suppose L1 and L2 belong to regular language and if regular language is closed under operation ∪, then L1∪L2 will be a Regular language. But if RL is not closed under ∩, that doesn't mean L1∩L2 won't be a RL.

For a class to be closed under an operation, it has to hold true for all languages in that class. So, if a class is not closed under an operation, we cannot say anything about the class of the resulting language of the operation – it may or may not belong to the class of the operand languages.

In brief we can say that, closure property is applicable, only when a language is closed under an operation.

Now let us prove that the regular language is closed under the complementary operation −

## Problem

Let the complementary Operation (COR) of two sets is defined as −

COR(A, B) = {x : x ∉ A or x ∉ B }, we need to show that the regular language is closed

under the COR operation.

## Solution

Let A and B be regular languages.

COR(A, B) = {x : x ∉ A or x ∉ B }

=> { x : x ∈ A's Complement } ∪ {x : x ∈ B's Complement}.

If A and B are regular,

let M1 = (Q1, ∑, δ1, q0, F1) and

M2 = (Q2, ∑, δ2, p0, F2) be DFAs that accept A and B.

Then the DFAs M1's Complement = (Q1, ∑, δ1, q0, Q1 − F1) and M2's Complement = (Q2, ∑, δ2, p0, Q2 − F2) accept A's Complement and B's Complement.

Thus, { x : x ∉ A } and { x: x ∉ B } are regular.

Then by the results of the last problem, we know that the family of regular languages is closed under finite union.

Therefore, we conclude that COR(A,B) is regular

- Related Questions & Answers
- Show that the set of recursive languages is closed under reversal?
- Explain the context free language closure under union operation?
- Prove that CFL is closed under union and star but not under intersection?
- How to show a figure that has been closed in Matplotlib?
- What is the pumping lemma for regular language?
- Explain the context free language closure under concatenation?
- Give the examples of a context free language that are not regular?
- Explain the Star Height of Regular Expression and Regular Language
- How to show the domain name of the server that loaded the document with JavaScript?
- What is the TFTP Operation?
- Explain the different operations on Regular language in TOC.
- How to identify if a language is regular or not in TOC?
- How to delete a localStorage item when the browser window/tab is closed?
- Send a notification when the Android app is closed
- Show that the set of all languages that are not recursively enumerable on {a} is not countable?