diff --git a/ssc/cmod_hybrid.cpp b/ssc/cmod_hybrid.cpp index 1bda992d7..bc3f6b974 100644 --- a/ssc/cmod_hybrid.cpp +++ b/ssc/cmod_hybrid.cpp @@ -226,9 +226,8 @@ class cm_hybrid : public compute_module if ( ts_adj ) log(util::format("Simulation time step for hybrid system is %d minutes.", 60 / int(maximumTimeStepsPerHour), SSC_NOTICE)); size_t genLength = 8760*maximumTimeStepsPerHour*analysisPeriod;// assumes single year gen ssc_number_t* pGen = ((var_table*)outputs)->allocate("gen", genLength); // add to top level "output" - assumes analysis period the same for all generators -// ssc_number_t* pGen = ((var_table*)outputs)->allocate("gen", genLength); // move to top level to use accumlate funtions below - fails precheck - + // TODO - test for different timesteps for each generator and lifetime and non-lifetime generators size_t idx = 0; for (size_t i=0; i genTimestepsPerHour[g]) offset = genTimestepsPerHour[g]; - pGen[idx] += gen[h + offset] * cf_degradation[y]; // Not valid for lifetime output - e.g. pvsamv1 + if (count_gen == genLength) + pGen[idx] += gen[idx]; // lifetime output with degradation and availability + else + pGen[idx] += gen[h + offset] * cf_degradation[y]; idx++; } } diff --git a/ssc/cmod_pvsamv1.cpp b/ssc/cmod_pvsamv1.cpp index 4522118f2..977dc5998 100644 --- a/ssc/cmod_pvsamv1.cpp +++ b/ssc/cmod_pvsamv1.cpp @@ -1060,6 +1060,7 @@ cm_pvsamv1::cm_pvsamv1() add_var_info(vtab_resilience_outputs); add_var_info(vtab_utility_rate_common); // Required by battery add_var_info(vtab_grid_curtailment); // Required by battery + add_var_info(vtab_hybrid_tech_om); }