The base of the intersection of two free submonoids

Abstract Given two free submonoids of a free monoid, one wishes to find a specification for the base of the intersection. An algorithm to construct a graph-theoretic specification of the base is presented. From this specification it can easily be determined whether the base is finite. In addition, a a polynomial-time algorithm to determine if a regular set is a circular code is presented.