public boolean paretoDominates(MultiObjectiveFitness other)
        {
        boolean abeatsb = false;
        if (maximize != other.maximize)
            throw new RuntimeException(
                "Attempt made to compare two multiobjective fitnesses; but one expects higher values to be better and the other expectes lower values to be better.");
        if (objectives.length != other.objectives.length)
            throw new RuntimeException("Attempt made to compare two multiobjective fitnesses; but they have different numbers of objectives.");
        if (maximize)
            {
            for (int x = 0; x < objectives.length; x++)
                {
                if (objectives[x] > other.objectives[x])
                    abeatsb = true;
                else if (objectives[x] < other.objectives[x])
                    return false;
                }
            }
        else
            {
            for (int x = 0; x < objectives.length; x++)
                {
                if (objectives[x] < other.objectives[x])
                    abeatsb = true;
                else if (objectives[x] > other.objectives[x])
                    return false;
                }
            }
        return abeatsb;
        }