(s)
return sympify(re.sub(r'([a-zA-Z_][a-zA-Z0-9_]*)', r'Symbol("\1")', s))
Transforms a rule into a SymPy expression
    A rule is a string of the form "symbol1 & symbol2 | ..."

    Note: This function is deprecated.  Use sympify() instead.
Transforms a rule into a SymPy expression
    A rule is a string of the form "symbol1 & symbol2 | ..."
Transforms a rule into a SymPy expression A rule is a string of the form symbol1 & symbol2 | ...
def compile_rule(s):
    """
    Transforms a rule into a SymPy expression
    A rule is a string of the form "symbol1 & symbol2 | ..."

    Note: This function is deprecated.  Use sympify() instead.

    """
    import re
    return sympify(re.sub(r'([a-zA-Z_][a-zA-Z0-9_]*)', r'Symbol("\1")', s))
def compile_rule ( s ) : import re return sympify ( re . sub ( r'([a-zA-Z_][a-zA-Z0-9_]*)' , r'Symbol("\1")' , s ) )