code: public static boolean verifyDoubleStation( double[] xStation, double[] yStation, double[] zStation, double[] hStation,
              double xTmp, double yTmp, double zTmp, double hTmp, int i, boolean doMean, IHMProgressMonitor pm ) throws Exception {
  
          for( int j = 0; j < i - 1; j++ ) {
  
              if (dEq(xTmp, xStation[j]) && dEq(yTmp, yStation[j]) && dEq(zTmp, zStation[j]) && dEq(hTmp, hStation[j])) {
                  if (!doMean) {
                      throw new IllegalArgumentException(msg.message("verifyStation.equalsStation1") + xTmp + "/" + yTmp);
                  }
                  return true;
              } else if (dEq(xTmp, xStation[j]) && dEq(yTmp, yStation[j]) && dEq(zTmp, zStation[j])) {
                  if (!doMean) {
                      throw new IllegalArgumentException(msg.message("verifyStation.equalsStation2") + xTmp + "/" + yTmp);
                  }
                  if (!isNovalue(hStation[j]) && !isNovalue(hTmp)) {
                      hStation[j] = (hStation[j] + hTmp) / 2;
                  } else {
                      hStation[j] = doubleNovalue;
                  }
                  return true;
              }
          }
          return false;
      }
docs: Verify if the current station (i) is already into the arrays.
  
  @param xStation the x coordinate of the stations
  @param yStation the y coordinate of the stations
  @param zStation the z coordinate of the stations
  @param hStation the h value of the stations
  @param xTmp
  @param yTmp
  @param zTmp
  @param hTmp
  @param i the current index
  @param doMean if the h value of a double station have different value then do the mean.
  @param pm
  @return true if there is already this station.
  @throws Exception