nickolasclarke / dispatch

A discrete-event simulation (DES) model for simulating deployment of EV bus fleets, using GTFS data
2 stars 0 forks source link

Bus starts overcharged, and continues to overcharge #90

Open nickolasclarke opened 4 years ago

nickolasclarke commented 4 years ago

found while investigating #89, using the same scenario and data. See that ticket for the csv used.

Expected results:

  1. Bus is created with 220 kwh, and can only charge to 220kwh max.
  2. Bus only serves 1 trip at at time.

Observed Results: In this scenario Bus 767 appears to start with significantly higher power than 220kwh (assuming energy left is in units kwh) It also continues to overcharge, over 2000kwh at its peak. It also serves two trips with the same start/end arrival_time fields, one of which starts from a depot, another of which starts in the middle of a block. This suggests it serves two trips at at time.

opti_trips = pd.read_csv('actransit/220kwh_500_kw_trips.csv', index_col=0)
opti_trips[opti_trips['bus_id'] == 767].sort_values('end_arrival_time')
block_id bus_busy_end bus_busy_start bus_id distance end_arrival_time end_depot_id end_stop_id energy_left start_arrival_time start_depot_id start_stop_id trip_id wait_time
6086 9.3227e+07 33540 30000 767 22821.2 33540 -9.22337e+18 5256 621.668 30000 -9.22337e+18 5546 3.83441e+08 1260
6098 9.3227e+07 33540 28032.6 767 22821.2 33540 -9.22337e+18 5256 358.007 30000 3 5546 3.83441e+08 1260
6087 9.3227e+07 38280 34800 767 22490 38280 -9.22337e+18 1351 786.259 34800 -9.22337e+18 1593 3.83387e+08 1320
6088 9.3227e+07 43320 39600 767 22821.2 43320 -9.22337e+18 5256 917.242 39600 -9.22337e+18 5546 3.83449e+08 1080
6089 9.3227e+07 47940 44400 767 22490 47940 -9.22337e+18 1351 1073.5 44400 -9.22337e+18 1593 3.83395e+08 1260
6090 9.3227e+07 52980 49200 767 22821.2 52980 -9.22337e+18 5256 1196.15 49200 -9.22337e+18 5546 3.83457e+08 1020
6091 9.3227e+07 57660 54000 767 22490 57660 -9.22337e+18 1351 1335.74 54000 -9.22337e+18 1593 3.83403e+08 1140
6092 9.3227e+07 63000 58800 767 22821.2 63000 -9.22337e+18 5256 1566.72 58800 -9.22337e+18 5546 3.83465e+08 1800
6093 9.3227e+07 68280 64800 767 22490 68280 -9.22337e+18 1351 1731.31 64800 -9.22337e+18 1593 3.83412e+08 1320
6094 9.3227e+07 73200 69600 767 22821.2 73200 -9.22337e+18 5256 1878.96 69600 -9.22337e+18 5546 3.83474e+08 1200
6095 9.3227e+07 77520 74400 767 22490 77520 -9.22337e+18 1351 2093.56 74400 -9.22337e+18 1593 3.8342e+08 1680
6096 9.3227e+07 82800 79200 767 22821.2 82800 -9.22337e+18 5256 2241.2 79200 -9.22337e+18 5546 3.83482e+08 1200
6097 9.3227e+07 30765.1 84000 767 22490 86820 3 1351 2204.82 84000 -9.22337e+18 1593 3.83428e+08 0