code: public void evaluate(DoubleSolution solution) {
      double[] f = new double[getNumberOfObjectives()];
  
      f[0] = solution.getVariableValue(0);
      double g = this.evalG(solution);
      double h = this.evalH(f[0], g);
      f[1] = h * g;
  
      solution.setObjective(0, f[0]);
      solution.setObjective(1, f[1]);
    }
docs: Evaluate() method