#NEWLINE# def compose( self , other ) : #NEWLINE# #INDENT# 'Add the generators of ``other`` to ``self``' #NEWLINE# if ( self != other ) : #NEWLINE# #INDENT# syms = set ( self . symbols ) . union ( set ( other . symbols ) ) #NEWLINE# return self . clone ( symbols = list ( syms ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return syms