// Computation unit = machine_dependent_factor (SU value) * cpu seconds;
  // Computation units/3600 seconds per hour = Service Units;
  protected void sumSUCharge(
      ProcessorTypeArrayList ptlist,
      ProjectHashMap projecthm,
      PrincipalInvestigatorHashMap pihm,
      UtilizationArray ua,
      Map<String, Float> ghm,
      Map<String, Float> ohm) {
    Project p;
    PrincipalInvestigator pi;

    // Lookup host information
    ProcessorType pt = ptlist.lookupProcessorType(hostname);
    Float suCharge = 0.0F;
    String cluster = "";
    if (pt == null) {
      suCharge = 1.0F;
      cluster = "katana";
      System.err.println("Error: SU charge arbitrarily set to 1.0 for host: " + hostname);
      System.err.println("Error: Cluster arbitrarily set to katana for host: " + hostname);
    } else {
      suCharge = pt.suCharge;
      cluster = pt.cluster;
    }

    // Do per record service unit calculation
    Float computationUnitsPerAcctRecord = (suCharge * cpu);

    // In earth-systems-only mode, only look at Earth Systems project groups
    // so that utilization totals can be compared to PI totals
    // apples to apples
    if (!Global.earthSystemsOnly || projecthm.containsKey(group)) {
      // Do per cluster utilitzation calculations
      Integer index = ua.calcIntervalArrayIndex(end_time * 1000L);
      if (cluster.equals("scluster")) {
        ua.sclusterLineGraphValues[index] += computationUnitsPerAcctRecord;
        ua.sclusterServiceUnits += computationUnitsPerAcctRecord;
      } else {
        ua.katanaLineGraphValues[index] += computationUnitsPerAcctRecord;
        ua.katanaServiceUnits += computationUnitsPerAcctRecord;
      }
    }

    if (projecthm.containsKey(group)) {

      // Sum service units per project
      p = projecthm.get(group);
      // In the error check, project = group and project list = project hashmap
      if (p == null) {
        System.err.println("Error: Unable to find project " + "\"" + group + "\" in project list");
        return;
      }
      p.suSum += computationUnitsPerAcctRecord;
      projecthm.totalServiceUnits += computationUnitsPerAcctRecord;

      // Sum service units per PI
      pi = pihm.get(p.piOwnerUserID);
      // In the error check, and PI list = PI hashmap
      if (pi == null) {
        System.err.println("Error: Unable to find PI " + "\"" + p.piOwnerUserID + "\" in PI list");
        return;
      }
      pi.suSum += computationUnitsPerAcctRecord;
      pihm.totalServiceUnits += computationUnitsPerAcctRecord;

      // Print messages
      if (Global.debug > 1) {
        System.out.printf(
            "SCLUSTER group: %8s cpu: %8.2f sucharge: %8.2f gpsum: %f\n",
            group, cpu, suCharge, projecthm.get(group).suSum);
      }
    } else if (Global.debug > 1) {
      System.out.printf("Other group: %8s cpu: %8.2f sucharge: %8.2f\n", group, cpu, suCharge);
    }

    // Sum group, owner SU
    Float groupSUSum = 0.0F;
    if (ghm.containsKey(group)) {
      groupSUSum = ghm.get(group);
      ghm.remove(group);
    }
    ghm.put(group, computationUnitsPerAcctRecord + groupSUSum);

    Float ownerSUSum = 0.0F;
    if (ohm.containsKey(owner)) {
      ownerSUSum = ohm.get(owner);
      ohm.remove(owner);
    }
    ohm.put(owner, computationUnitsPerAcctRecord + ownerSUSum);
  }
 protected void printShortAttributes(ProcessorTypeArrayList ptlist) {
   ProcessorType pt = ptlist.lookupProcessorType(hostname);
   System.out.printf(
       "%22s\t%8s\t%8s\t%10d\t%10d\t%14f\t%8f\n",
       hostname, group, owner, start_time, end_time, cpu, pt.suCharge);
 }