public void write(ArrowRelation arrow, BufferedWriter file) throws IOException {
        SortedSet<Edge> edges = arrow.getEdges();
        TreeSet<Node> m = new TreeSet<Node>();
        TreeSet<Node> j = new TreeSet<Node>();
        for (Edge e : edges) {
            m.add(e.getFrom());
            j.add(e.getTo());
        }
        String str = "\\begin{tabular}{|c|*{" + Integer.toString(j.size()) + "}{c|}}\n";
        str += "\\hline\n";
        for (Node nj : j) {
            str += " & " + nj.getContent();
        }
        str += "\\\\ \n";
        str += "\\hline\n";
        for (Node nm : m) {
            str += nm.getContent();
            for (Node nj : j) {
                Edge e = arrow.getEdge(nm, nj);
                if ((String) e.getContent() == "Up") {
                    str += " & $\\uparrow$";
                } else {
                    if ((String) e.getContent() == "Down") {
                    str += " & $\\downarrow$";
                } else {
                    if ((String) e.getContent() == "UpDown") {
                    str += " & $\\updownarrow$";
                } else {
                    if ((String) e.getContent() == "Cross") {
                    str += " & $\\times$";
                } else {
                    str += " & $\\circ$";
                    }
                    }
                    }
                /* Previous code, in a Java7 only way, was :
                switch ((String)e.getContent()) {
                    case "Up":str += " & $\\uparrow$";break;
                    case "Down":str += " & $\\downarrow$";break;
                    case "UpDown":str += " & $\\updownarrow$";break;
                    case "Cross":str += " & $\\times$";break;
                    case "Circ":str += " & $\\circ$";break;
                    default :break;
                */
                }
            }
            str += "\\\\ \n";
            str += "\\hline\n";
        }
        str += "\\end{tabular}\n";
        file.write(str);
    }