GridModule.get_cost#
- GridModule.get_cost(import_export, as_source, as_sink)[source]#
Current cost of the grid’s usage.
Includes both the cost of importing/exporting as well as the cost of carbon dioxide production. Note that the “cost” of exporting may be negative as the module may receive revenue in exchange for energy export. If the module is exporting to the grid, co2 production cost will be zero.
Parameters#
- import_exportfloat
Amount of energy that is imported or exported.
- as_sourcebool
Whether the grid is acting as a source.
- as_sinkbool
Whether the grid is acting as a sink.
Returns#
- costfloat
Cost of using the grid.