Skip to content

Commit

Permalink
fix error
Browse files Browse the repository at this point in the history
  • Loading branch information
arght committed Dec 27, 2023
1 parent b5694ec commit 177bcb9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion openTEPES/openTEPES_ModelFormulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ def eAdequacyReserveMargin(OptModel,p,ar):
print('eAdequacyReserveMargin... ', len(getattr(OptModel, 'eAdequacyReserveMargin_'+str(p)+'_'+str(sc)+'_'+str(st))), ' rows')

def eMaxSystemEmission(OptModel,p,ar):
if mTEPES.pEmission[p,ar] < math.inf and sum(mTEPES.pEmissionVarCost[p,sc,n,nr] for nr in mTEPES.nr if (ar,nr) in mTEPES.a2g):
if mTEPES.pEmission[p,ar] < math.inf and sum(mTEPES.pEmissionVarCost[p,sc,n,nr] for n,nr in mTEPES.nn*mTEPES.nr if (st,n) in mTEPES.s2n and (ar,nr) in mTEPES.a2g):
return sum(OptModel.vTotalECostArea[p,sc,n,ar]/mTEPES.pCO2Cost for n in mTEPES.nn if (st,n) in mTEPES.s2n) <= mTEPES.pEmission[p,ar]
else:
return Constraint.Skip
Expand Down

0 comments on commit 177bcb9

Please sign in to comment.