code: public int findTileSYMPART(double x1, double x2)
     {
        int dim;
        double[] x = new double[2];
        double h1;
        double omega =  Math.PI / 4.0;
        double si = Math.sin(omega);
        double co = Math.cos(omega);
        x[0] = x1;
        x[1] = x2;
        //rotate( 2, x );
        for( dim=0; dim+1 < 2; dim+=2 )
        {
           h1 = x[dim];
           x[dim] = co * h1 - si * x[dim+1];
           x[dim+1] = si * h1 + co * x[dim+1];
        }
        TupleTwo<Integer, Integer> tt = findTile(x[0], x[1]);
        int i = tt._1();
        int j = tt._2();
        // restrict to 9 tiles
        if (Math.abs(i) > 1 || Math.abs(j) > 1) return -1;
        return (i + 1) * 3 + (j + 1);
     }
docs: /* returns tile number between 0 and 8
  returns - 1 if out of any tile, function does
  not depend on objFct!