public Double[] maximizeMod(Double[] max, int[] numberOfValues, NodeVariable x, int xIndex, FunctionEvaluator fe, HashMap<NodeVariable, MessageQ> modifierTable){

        if(debug>=3){
            System.out.print("Oplus_MaxSum.maximizeMod: modifier table size="+modifierTable.size());
            if (modifierTable.size()>=1){
                Iterator<NodeVariable> it = modifierTable.keySet().iterator();
                while (it.hasNext()) {
                    NodeVariable nodeVariable = it.next();
                    System.out.print(" Node:"+nodeVariable+" Value:"+modifierTable.get(nodeVariable));
                }

            }
            System.out.println("");
        }
        double cost = 0;
        for (int xParamIndex = 0; xParamIndex  < x.size(); xParamIndex ++) {
            numberOfValues[xIndex] = xParamIndex;
            // NOW it's pretty ready
            // this is the part where it is maximized
            cost = ( fe.evaluateMod(fe.functionArgument(numberOfValues), modifierTable));
            if (max[xParamIndex] == null){
                max[xParamIndex] = ( cost );
            } else {
                max[xParamIndex] = ( cost > max[xParamIndex] ) ? cost : max[xParamIndex];
            }
        }
        return max;
    }