Assume that R, Q and P are sets such that P does not contain the string of length zero, and R is defined byR = Q + RPWe wish to show thatR = QP*We first show that QP* is contained in R. By definition, R = Q + RP.
To see if QP* is a solution, we insert it as the value of R in Q + RP and see if the equation balancesR = Q + QP*P = Q(e+PP*) = QP*Hence QP* is a solution, but not necessarily the only solution.
To prove uniqueness, we show that R is contained in QP*. By definition,R = Q+RP = Q+(Q+RP)PChoose any W in R, where the length of W is equal to k. Then, from above,
= Q+QP+RP^2 = Q+QP+(Q+RP)P^2
= Q(e+P+P^2+ ... +P^i)+RP^(i+1), for all i>=0R = Q(e+P+P^2+ ... +P^k)+RP^(k+1)but, since P does not contain the string of length zero, W is not in RP^(k+1). But then W is inQ(e+P+P^2+ ... +P^k) and hence W is in QP*.We use the above to solve simultaneous regular equations. For example, we can associate regular expressions with finite state automata as follows
Hence,A = B10* + 0*and therefore
B = B10*1 + B0 + 0*1B = 0*1(10*1 + 0)*Note: This technique fails if there are lambda transitions.