def readOrder(filename):
    """Read an elimination order from a file

    Elimination orders are stored as unknown length vectors, format "[nvar] [v0] [v1] ... [vn]"

    Note: the same file format may also be useful for MPE configurations, etc.
    """
    with open(filename,'r') as fp:
        lines = fp.readlines();
    text = lines[-1].strip('\n').split(' ');
    nvar = int(text[0]);
    vals = [int(text[i]) for i in range(1,nvar+1)];
    if len(vals) != nvar: raise ValueError("Problem with file?");
    return vals