Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/test-mango.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ jobs:
pip3 install -r docs/requirements.txt
pip3 install -e .[test]
brew install mosquitto
echo "allow_anonymous true" >> /opt/homebrew/etc/mosquitto/mosquitto.conf
echo "listener 1883" >> /opt/homebrew/etc/mosquitto/mosquitto.conf
brew services start mosquitto
sleep 2
pip3 install pytest coverage ruff
- name: Lint with ruff
run: |
Expand Down
1 change: 1 addition & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ pika
pyzmq
furo>=2024.8.6
sphinx-copybutton
sphinx-design
2 changes: 2 additions & 0 deletions docs/source/_static/ev_soc_netpower.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<div> <script type="text/javascript">window.PlotlyConfig = {MathJaxConfig: 'local'};</script>
<script charset="utf-8" src="https://cdn.plot.ly/plotly-3.3.1.min.js" integrity="sha256-4rD3fugVb/nVJYUv5Ky3v+fYXoouHaBSP20WIJuEiWg=" crossorigin="anonymous"></script> <div id="ev-overview" class="plotly-graph-div" style="height:440px; width:100%;"></div> <script type="text/javascript"> window.PLOTLYENV=window.PLOTLYENV || {}; if (document.getElementById("ev-overview")) { Plotly.newPlot( "ev-overview", [{"hovertemplate":"%{y:.1f} kWh at hour %{x}\u003cextra\u003eEV 1\u003c\u002fextra\u003e","legendgroup":"EVs","legendgrouptitle":{"text":"EVs"},"line":{"color":"royalblue","width":2.2},"name":"EV 1","x":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[20.0,20.0,20.0,17.5,15.0,12.5,10.0,7.5,5.0,5.0,5.0,7.535533905932738,7.535533905932738,7.535533905932738,10.835533905932738,14.13553390593274,17.43553390593274,17.43553390593274,17.43553390593274,17.43553390593274,17.43553390593274,14.93553390593274,12.43553390593274,9.93553390593274],"type":"scatter","xaxis":"x","yaxis":"y"},{"hovertemplate":"%{y:.1f} kWh at hour %{x}\u003cextra\u003eEV 2\u003c\u002fextra\u003e","legendgroup":"EVs","legendgrouptitle":{"text":"EVs"},"line":{"color":"crimson","width":2.2},"name":"EV 2","x":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[15.0,15.0,15.0,15.0,15.0,13.0,11.0,9.0,7.0,7.0,8.0,8.0,8.0,8.0,8.0,8.0,11.3,11.3,11.3,10.611733315717649,10.611733315717649,10.611733315717649,10.611733315717649,8.611733315717649],"type":"scatter","xaxis":"x","yaxis":"y"},{"hovertemplate":"%{y:.1f} kWh at hour %{x}\u003cextra\u003eEV 3\u003c\u002fextra\u003e","legendgroup":"EVs","legendgrouptitle":{"text":"EVs"},"line":{"color":"darkorange","width":2.2},"name":"EV 3","x":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[10.0,10.0,8.0,6.0,4.0,2.0,0.0,0.0,0.0,0.0,0.0,0.0,3.196152422706632,6.496152422706632,6.496152422706632,9.796152422706632,12.992304845413264,15.23494553253255,15.23494553253255,15.23494553253255,13.23494553253255,13.23494553253255,13.23494553253255,11.23494553253255],"type":"scatter","xaxis":"x","yaxis":"y"},{"hovertemplate":"%{y:.2f} kW at hour %{x}\u003cextra\u003eH1 (6 kW PV)\u003c\u002fextra\u003e","legendgroup":"Households","legendgrouptitle":{"text":"Households"},"line":{"color":"teal","width":1.8},"name":"H1 (6 kW PV)","x":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[-2.0,-2.0,-2.0,-2.0,-2.0,-2.0,-0.44708572938487556,0.9999999999999996,2.2426406871192848,3.1961524227066316,3.79555495773441,4.0,3.79555495773441,3.196152422706632,2.242640687119284,1.0,-0.4470857293848738,-1.9999999999999982,-2.0,-2.0,-2.0,-2.0,-2.0],"type":"scatter","xaxis":"x2","yaxis":"y2"},{"hovertemplate":"%{y:.2f} kW at hour %{x}\u003cextra\u003eH2 (4 kW PV)\u003c\u002fextra\u003e","legendgroup":"Households","legendgrouptitle":{"text":"Households"},"line":{"color":"purple","width":1.8},"name":"H2 (4 kW PV)","x":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[-1.5,-1.5,-1.5,-1.5,-1.5,-1.5,-0.46472381958991704,0.4999999999999998,1.3284271247461898,1.9641016151377546,2.3637033051562737,2.5,2.363703305156273,1.9641016151377553,1.3284271247461898,0.5,-0.46472381958991527,-1.5,-1.5,-1.5,-1.5000000000000018,-1.5,-1.5],"type":"scatter","xaxis":"x2","yaxis":"y2"},{"hovertemplate":"%{y:.2f} kW at hour %{x}\u003cextra\u003eH3 (7 kW PV)\u003c\u002fextra\u003e","legendgroup":"Households","legendgrouptitle":{"text":"Households"},"line":{"color":"sienna","width":1.8},"name":"H3 (7 kW PV)","x":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[-2.5,-2.5,-2.5,-2.5,-2.5,-2.5,-0.6882666842823539,0.9999999999999996,2.449747468305832,3.56217782649107,4.261480784023478,4.5,4.261480784023476,3.562177826491073,2.4497474683058336,1.0,-0.6882666842823539,-2.5,-2.5,-2.5,-2.5,-2.5,-2.5],"type":"scatter","xaxis":"x2","yaxis":"y2"},{"hovertemplate":"%{y:.2f} kW at hour %{x}\u003cextra\u003eH4 (5 kW PV)\u003c\u002fextra\u003e","legendgroup":"Households","legendgrouptitle":{"text":"Households"},"line":{"color":"olivedrab","width":1.8},"name":"H4 (5 kW PV)","x":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[-1.0,-1.0,-1.0,-1.0,-1.0,-1.0,0.2940952255126037,1.4999999999999996,2.5355339059327373,3.3301270189221928,3.8296291314453423,4.0,3.8296291314453406,3.3301270189221945,2.5355339059327378,1.5,0.29409522551260636,-0.9999999999999991,-1.0000000000000009,-1.0,-1.0,-1.0,-1.0],"type":"scatter","xaxis":"x2","yaxis":"y2"},{"hovertemplate":"%{y:.2f} kW at hour %{x}\u003cextra\u003eH5 (3 kW PV)\u003c\u002fextra\u003e","legendgroup":"Households","legendgrouptitle":{"text":"Households"},"line":{"color":"steelblue","width":1.8},"name":"H5 (3 kW PV)","x":[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],"y":[-2.0,-2.0,-2.0,-2.0,-2.0,-2.0,-1.223542864692437,-0.5,0.12132034355964239,0.598076211353316,0.897777478867205,1.0,0.897777478867205,0.5980762113533156,0.12132034355964283,-0.5,-1.223542864692437,-2.0,-2.0,-2.0,-2.0,-2.0,-2.0],"type":"scatter","xaxis":"x2","yaxis":"y2"}], {"template":{"data":{"histogram2dcontour":[{"type":"histogram2dcontour","colorbar":{"outlinewidth":0,"ticks":""},"colorscale":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]]}],"choropleth":[{"type":"choropleth","colorbar":{"outlinewidth":0,"ticks":""}}],"histogram2d":[{"type":"histogram2d","colorbar":{"outlinewidth":0,"ticks":""},"colorscale":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]]}],"heatmap":[{"type":"heatmap","colorbar":{"outlinewidth":0,"ticks":""},"colorscale":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]]}],"contourcarpet":[{"type":"contourcarpet","colorbar":{"outlinewidth":0,"ticks":""}}],"contour":[{"type":"contour","colorbar":{"outlinewidth":0,"ticks":""},"colorscale":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]]}],"surface":[{"type":"surface","colorbar":{"outlinewidth":0,"ticks":""},"colorscale":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]]}],"mesh3d":[{"type":"mesh3d","colorbar":{"outlinewidth":0,"ticks":""}}],"scatter":[{"fillpattern":{"fillmode":"overlay","size":10,"solidity":0.2},"type":"scatter"}],"parcoords":[{"type":"parcoords","line":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scatterpolargl":[{"type":"scatterpolargl","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"bar":[{"error_x":{"color":"#2a3f5f"},"error_y":{"color":"#2a3f5f"},"marker":{"line":{"color":"#E5ECF6","width":0.5},"pattern":{"fillmode":"overlay","size":10,"solidity":0.2}},"type":"bar"}],"scattergeo":[{"type":"scattergeo","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scatterpolar":[{"type":"scatterpolar","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"histogram":[{"marker":{"pattern":{"fillmode":"overlay","size":10,"solidity":0.2}},"type":"histogram"}],"scattergl":[{"type":"scattergl","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scatter3d":[{"type":"scatter3d","line":{"colorbar":{"outlinewidth":0,"ticks":""}},"marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scattermap":[{"type":"scattermap","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scattermapbox":[{"type":"scattermapbox","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scatterternary":[{"type":"scatterternary","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"scattercarpet":[{"type":"scattercarpet","marker":{"colorbar":{"outlinewidth":0,"ticks":""}}}],"carpet":[{"aaxis":{"endlinecolor":"#2a3f5f","gridcolor":"white","linecolor":"white","minorgridcolor":"white","startlinecolor":"#2a3f5f"},"baxis":{"endlinecolor":"#2a3f5f","gridcolor":"white","linecolor":"white","minorgridcolor":"white","startlinecolor":"#2a3f5f"},"type":"carpet"}],"table":[{"cells":{"fill":{"color":"#EBF0F8"},"line":{"color":"white"}},"header":{"fill":{"color":"#C8D4E3"},"line":{"color":"white"}},"type":"table"}],"barpolar":[{"marker":{"line":{"color":"#E5ECF6","width":0.5},"pattern":{"fillmode":"overlay","size":10,"solidity":0.2}},"type":"barpolar"}],"pie":[{"automargin":true,"type":"pie"}]},"layout":{"autotypenumbers":"strict","colorway":["#636efa","#EF553B","#00cc96","#ab63fa","#FFA15A","#19d3f3","#FF6692","#B6E880","#FF97FF","#FECB52"],"font":{"color":"#2a3f5f"},"hovermode":"closest","hoverlabel":{"align":"left"},"paper_bgcolor":"white","plot_bgcolor":"#E5ECF6","polar":{"bgcolor":"#E5ECF6","angularaxis":{"gridcolor":"white","linecolor":"white","ticks":""},"radialaxis":{"gridcolor":"white","linecolor":"white","ticks":""}},"ternary":{"bgcolor":"#E5ECF6","aaxis":{"gridcolor":"white","linecolor":"white","ticks":""},"baxis":{"gridcolor":"white","linecolor":"white","ticks":""},"caxis":{"gridcolor":"white","linecolor":"white","ticks":""}},"coloraxis":{"colorbar":{"outlinewidth":0,"ticks":""}},"colorscale":{"sequential":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]],"sequentialminus":[[0.0,"#0d0887"],[0.1111111111111111,"#46039f"],[0.2222222222222222,"#7201a8"],[0.3333333333333333,"#9c179e"],[0.4444444444444444,"#bd3786"],[0.5555555555555556,"#d8576b"],[0.6666666666666666,"#ed7953"],[0.7777777777777778,"#fb9f3a"],[0.8888888888888888,"#fdca26"],[1.0,"#f0f921"]],"diverging":[[0,"#8e0152"],[0.1,"#c51b7d"],[0.2,"#de77ae"],[0.3,"#f1b6da"],[0.4,"#fde0ef"],[0.5,"#f7f7f7"],[0.6,"#e6f5d0"],[0.7,"#b8e186"],[0.8,"#7fbc41"],[0.9,"#4d9221"],[1,"#276419"]]},"xaxis":{"gridcolor":"white","linecolor":"white","ticks":"","title":{"standoff":15},"zerolinecolor":"white","automargin":true,"zerolinewidth":2},"yaxis":{"gridcolor":"white","linecolor":"white","ticks":"","title":{"standoff":15},"zerolinecolor":"white","automargin":true,"zerolinewidth":2},"scene":{"xaxis":{"backgroundcolor":"#E5ECF6","gridcolor":"white","linecolor":"white","showbackground":true,"ticks":"","zerolinecolor":"white","gridwidth":2},"yaxis":{"backgroundcolor":"#E5ECF6","gridcolor":"white","linecolor":"white","showbackground":true,"ticks":"","zerolinecolor":"white","gridwidth":2},"zaxis":{"backgroundcolor":"#E5ECF6","gridcolor":"white","linecolor":"white","showbackground":true,"ticks":"","zerolinecolor":"white","gridwidth":2}},"shapedefaults":{"line":{"color":"#2a3f5f"}},"annotationdefaults":{"arrowcolor":"#2a3f5f","arrowhead":0,"arrowwidth":1},"geo":{"bgcolor":"white","landcolor":"#E5ECF6","subunitcolor":"white","showland":true,"showlakes":true,"lakecolor":"white"},"title":{"x":0.05},"mapbox":{"style":"light"}}},"xaxis":{"anchor":"y","domain":[0.0,0.45],"title":{"text":"Hour of day"},"showgrid":true,"gridcolor":"#e8e8e8","zeroline":false,"range":[0,24],"dtick":4},"yaxis":{"anchor":"x","domain":[0.0,1.0],"title":{"text":"SoC (kWh)"},"range":[0,44],"showgrid":true,"gridcolor":"#e8e8e8","zeroline":false},"xaxis2":{"anchor":"y2","domain":[0.55,1.0],"title":{"text":"Hour of day"},"showgrid":true,"gridcolor":"#e8e8e8","zeroline":false,"range":[0,24],"dtick":4},"yaxis2":{"anchor":"x2","domain":[0.0,1.0],"title":{"text":"Net power (kW)"},"showgrid":true,"gridcolor":"#e8e8e8","zeroline":false},"annotations":[{"font":{"size":16},"showarrow":false,"text":"EV Battery State of Charge","x":0.225,"xanchor":"center","xref":"paper","y":1.0,"yanchor":"bottom","yref":"paper"},{"font":{"size":16},"showarrow":false,"text":"Household Net Power (PV \u2212 Load)","x":0.775,"xanchor":"center","xref":"paper","y":1.0,"yanchor":"bottom","yref":"paper"}],"title":{"font":{"size":15},"text":"EV Coordination Simulation \u2014 24-Hour Overview","x":0.5},"legend":{"groupclick":"toggleitem"},"height":440,"plot_bgcolor":"white","paper_bgcolor":"white"}, {"responsive": true} ) }; </script> </div>
Loading
Loading