(eq, num=1, start=1, prefix='C')
return (Cs[0] if num == 1 else tuple(Cs))
Returns a list of constants that do not occur
    in eq already.
Returns a list of constants that do not occur
    in eq already.
Returns a list of constants that do not occur in eq already .
def get_numbered_constants(eq, num=1, start=1, prefix='C'):
    """
    Returns a list of constants that do not occur
    in eq already.
    """

    if isinstance(eq, C.Expr):
        eq = [eq]
    elif not is_iterable(eq):
        raise ValueError("Expected Expr or iterable but got %s" % eq)

    atom_set = set.union(*[i.free_symbols for i in eq])
    ncs = numbered_symbols(start=start, prefix=prefix, exclude=atom_set)
    Cs = [next(ncs) for i in xrange(num)]
    return (Cs[0] if num == 1 else tuple(Cs))
def get_numbered_constants ( eq , num = 1 , start = 1 , prefix = 'C' ) : if isinstance ( eq , C . Expr ) : eq = [ eq ] elif not is_iterable ( eq ) : raise ValueError ( "Expected Expr or iterable but got %s" % eq ) atom_set = set . union ( * [ i . free_symbols for i in eq ] ) ncs = numbered_symbols ( start = start , prefix = prefix , exclude = atom_set ) Cs = [ next ( ncs ) for i in xrange ( num ) ] return ( Cs [ 0 ] if num == 1 else tuple ( Cs ) )