@Override
  public SchlegelCompound transformResultString() {

    // splitting result string into two. One contains the points, the other
    // the edges.

    int numberOfPoints = 0;
    String pointsString;
    String edgesString;
    String facesString = "";
    try {
      String[] pointsAndEdges = resultString.split("\\$\n");
      numberOfPoints = Integer.parseInt(pointsAndEdges[0]);
      pointsString = pointsAndEdges[1];
      edgesString = pointsAndEdges[2];

      // faces are only available in 3d
      if (is3D) {
        facesString = pointsAndEdges[3];
      }
    }
    catch (Exception e) {
      logger.severe("Wrong Format of resultString. Probably missing \\$\n");
      logger.fine(e.getMessage());
      logger.fine("resultString was: " + resultString);
      throw new PolymakeOutputException("Can't split Resultstring at \\$\n");
    }

    // transforming strings into Point-Objects
    Point3D[] points;
    try {
      points = parsePoints(pointsString);
    }
    catch (Exception e) {
      logger.severe("Can't parse points in resultString.");
      logger.fine(e.getMessage());
      logger.fine("resultString was: " + resultString);
      throw new PolymakeOutputException("Wrong Format of resultString.");
    }

    Edge[] edges;
    try {
      edges = parseEdges(edgesString);
    }
    catch (Exception e) {
      logger.severe("Can't parse edges in resultString.");
      logger.fine(e.getMessage());
      logger.fine("resultString was: " + resultString);
      throw new PolymakeOutputException("Wrong Format of resultString.");
    }

    Face[] faces = null;
    try {
      // faces are only available in 3d
      if (is3D) {
        faces = parseFaces(facesString);
      }
    }
    catch (Exception e) {
      // logger.severe("Can't parse faces in resultString.");
      // logger.fine(e.getMessage());
      // logger.fine("resultString was: " + resultString);
      // throw new PolymakeOutputException("Wrong Format of resultString.");
      logger.severe("Can't parse faces in resultString.");
      logger.severe(e.getMessage());
      logger.severe(facesString);
      faces = null;
    }

    Polytope<Point3D> polytope = null;

    if (is3D) {
      polytope = buildPolytope(edges, faces, numberOfPoints);
    }

    return new SchlegelCompound(new Schlegel(points, edges, polytope),
        this.sym, this.p);
  }