- 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

# What are the properties of Regular expressions in TOC?

A regular expression is basically a shorthand way of showing how a regular language is built from the base set of regular languages.

The symbols are identical which are used to construct the languages, and any given expression that has a language closely associated with it.

For each regular expression E, there is a regular language L(E).

There are some general equalities for the regular expressions.

**Properties**

All the properties held for any regular expressions R, E, F and can be verified by using properties of languages and sets.

**Additive (+) properties**

The additive properties of regular expressions are as follows −

R + E = E + R R + ∅ = ∅ + R = R R + R = R (R + E) + F = R + (E + F)

**Product (·) properties**

The product properties of regular expressions are as follows −

R∅ = ∅R = ∅ R∧ = ∧R = R (RE)F = R(EF)

**Distributive properties**

The distributive properties of regular expressions are as follows −

R(E + F) = RE + RF (R + E)F = RF + EF

**Closure properties**

The closure properties of regular expressions are as follows −

∅* = ∧ * = ∧ R* = R*R* = (R*)* = R + R* R* = ∧ + RR* = (∧ + R)R* RR* = R*R R(ER)* = (RE)*R (R + E)* = (R*E*)* = (R* + E*)* = R*(ER*)*

All the properties can be verified by using the properties of languages and sets.

**Example 1**

Show that

(∅ + a + b)* = a*(ba*)*

Using the properties above: (∅ + a + b)* = (a + b)* (+ property) = a*(ba*)* (closure property).

**Example 2**

Show that

∧ + ab + abab(ab)* = (ab)*

Using the properties above: ∧ + ab + abab(ab)* = ∧ + ab(∧ + ab(ab)*) = ∧ + ab((ab)*) (using R* = ∧ + RR*) = ∧ + ab(ab)*= (ab)* (using R* = ∧ + RR* again)

- Related Questions & Answers
- Explain about regular expressions in TOC?
- What are the basic properties of products in TOC?
- Prove the equalities of regular expressions by applying properties?
- What are the closure properties of Regular languages?
- What are regular expressions in JavaScript?
- What are regular expressions in C#
- What are the Rules of Regular Expressions in Compiler Design?
- What are the regular expressions to finite automata?
- What are anchors in regular expressions in C#?
- What are some basic examples of Python Regular Expressions?
- What is Regular Expressions?
- What are the fundamental concepts of TOC?
- What is the role of brackets ([ ]) in JavaScript Regular Expressions?
- What are negated character classes that are used in Python regular expressions?
- What is the role of special characters in JavaScript Regular Expressions?