• No results found

Smart charging of an electric bus fleet

N/A
N/A
Protected

Academic year: 2022

Share "Smart charging of an electric bus fleet"

Copied!
67
0
0

Loading.... (view fulltext now)

Full text

(1)

UPTEC ES 21011

Examensarbete 30 hp Juni 2021

Smart charging of an electric bus fleet

Emil Färm

(2)

Teknisk- naturvetenskaplig fakultet UTH-enheten

Besöksadress:

Ångströmlaboratoriet Lägerhyddsvägen 1 Hus 4, Plan 0

Postadress:

Box 536 751 21 Uppsala

Telefon:

018 – 471 30 03

Telefax:

018 – 471 30 00

Hemsida:

http://www.teknat.uu.se/student

Abstract

Smart charging of an electric bus fleet

Emil Färm

Controlling the balance of production and consumption of electricity will become increasingly challenging as the transport sector gradually converts to electric vehicles along with a

growing share of wind power in the Swedish electric power system.

This puts greater demand on resources that maintain the balance to ensure stable grid operation. The balancing act is called

frequency regulation which historically has been performed almost entirely by hydropower. As the power production becomes more intermittent with renewable energy sources, frequency regulation will need to be performed in higher volumes on the demand side by having a more flexible consumption.

In this report, the electrification of 17 buses at

Svealandstrafiken's bus depot in Västerås has been studied. The aim has been to assess different charging strategies to

efficiently utilize the available time and power but also to investigate if Svealandstrafiken can participate in frequency regulation. A textit{smart charging} model was created that

demonstrated how smart charging can be implemented to optimize the charging in four different cases. The simulated cases were:

charging with load balancing, reduced charging power, frequency regulation, and electrifying more buses.

The results show that the power capacity limit will be exceeded if the buses are being charged directly as they arrive at the depot and without scheduling the charging session. By implementing smart charging, Svealandstrafiken can fully charge the 17 buses within the power capacity limit of the depot with 82 minutes to spare. By utilizing this 82-minute margin in the four different charging strategies, it was found that Svealandstrafiken can save 88 200 SEK per year by load balancing, save 30 000 SEK per year by reducing the charging power by 10 %, earn 111 900 SEK per year by frequency regulation or electrify five more buses. Reducing the charging power may also increase the lifetime of the batteries but quantifying this needs further studies. Conclusively, there is economic potential for Svealandstrafiken for implementing smart charging.

Ämnesgranskare: Cecilia Boström Handledare: Jonas Thyni

(3)

Populärvetenskaplig sammanfattning

Det svenska elnätet står inför stora förändringar i framtiden i samband med att vindkraften byggs ut och att transportsektorn gradvis elektrifieras. När kärnkraften som agerat som baskraft minskar och ersätts av vindkraft som är variabel blir det svårare att balansera produktion och konsumtion av el.

El konsumeras i samma ögonblick som den produceras vilket gör att det alltid måste up- prätthållas en balans i elnätet. Denna balans mäts med den elektriska frekvensen i elnätet i enheten Hertz (Hz) och bör hållas vid 50 Hz. Vid för mycket produktion eller för lite konsumtion ökar frekvensen och vid för låg produktion eller för hög konsumtion minskar frekvensen. Små förändringar av frekvensen är acceptabla inom intervallet 49,9 till 50,1 Hz.

Vid större störningar som exempelvis bortfall av en produktionsanläggning kan frekvensen hamna utanför intervallet vilket kan orsaka skador på anslutna maskiner och apparater.

För att upprätthålla den önskade frekvensen i nätet handlar nätoperatören Svenska Kraftnät med balansresurser för att återställa balansen. Dessa resurser är enheter som är flexibla i sin produktion eller konsumtion av el så att de kan stötta regleringen av frekvensen vid behov vilket kallas frekvensreglering. En balansresurs som undersökts i detta examensarbete är smart laddning av elbussar. Genom att planera laddningen av elbussar kan lasten som laddningen av bussarna utgör agera som en balansresurs. Om detta styrs på ett smart sätt kan ägaren av bussflottan skapa en sekundär intäkt från frekvensreglering och fortfarande ladda sina bussar så att de är redo för morgondagens resor.

I detta examensarbete undersöktes laddningen av Svealandstrafikens 17 nya elbussar till bussdepån i Västerås. Under arbetet utvecklades en smart laddnings modell som planerar och prioriterar laddningen av bussarna efter bussdepåns förutsättningar. Modellen användes för att optimera fyra fall av optimerad laddning. Fallen som undersöktes var: lastbalansering, minskad laddningseffekt, frekvensreglering och att elektrifiera fler bussar.

Resultaten visar att det maximalt tillåtna effektuttaget i bussdepån överskrids om bussarna laddas direkt när de ankommer till depån utan att schemaläggas eller prioriteras. Genom att använda smart laddnings modellen kan bussarna laddas klart utan att överskrida det tillåtna effektuttaget och skapa en tidsmarginal på 82 minuter. Genom att optimera användandet av marginalen enligt de fyra laddningsstrategierna kan Svealandstrafiken antingen spara 88 200 kr per år genom att lastbalansera vilket kan minska toppeffektbehovet med 250 kW eller spara 30 000 kr per år genom att minska laddningseffekten till vardera buss med 10 %.

Att minska laddningseffekten till bussarna kan potentiellt förlänga livslängden av bussarnas batterier men detta behöver fortsatta studier för att fastställas. Det tredje alternativet är att tjäna 111 900 kr per år genom att frekvensreglera eller slutligen kan de använda marginalen till att ladda fem extra bussar.

De undersökta fallen har sina egna unika värden och därmed kan det konstateras att det finns tydliga fördelar för Svealandstrafiken att implementera smart laddning.

(4)

Executive summary

This master thesis project was carried out in collaboration with Tvinn to investigate four different charging strategies for Svealandstrafiken’s 17 electric buses. A smart charging algorithm was created during the project to simulate and optimize the charging strategies which were: charging with load balancing, reduced charging power, frequency regulation, and electrifying more buses.

The results show that if the buses are charged directly as the buses arrive at the depot the power capacity limit of the depot will be exceeded. By implementing the smart charging algorithm this issue can be resolved and Svealandstrafiken can fully charge all buses within the power limit with a time margin. By optimizing the utilization of the time margin Svealandstrafiken can either save 88 200 SEK per year in power costs by load balancing, 30 000 SEK per year by reducing the charging power to each bus, earn 111 900 SEK by participating in frequency regulation or electrify five more buses within the studied system.

(5)

Foreword

This Master’s thesis is the final part of the Master’s program in Energy Systems Engineering and has been conducted in cooperation with Tvinn.

I want to thank Jonas, Joakim, and Jakob at Tvinn for the support during the project and for the opportunity to work with you. I also want to thank my subject reviewer Cecilia for her valuable remarks.

Apart from being the conclusion of these years of studies, this also marks an end of an era.

An era filled with new experiences and challenges that I could enjoy and overcome thanks to the fantastic company I had the luck to be surrounded by in Uppsala. Therefore, I would like to thank everyone from the Uppsala Union of Engineering and Science Students that have both made events for me and with me. I also want to thank my friends from the Energy Systems program who not just endured the exam periods and lectures with me but also made them worth remembering.

Emil Färm

Uppsala, June 2021

(6)

Contents

1 Introduction 1

1.1 Purpose . . . 1

1.2 Thesis questions . . . 2

1.3 Scope . . . 2

1.4 Report structure . . . 3

2 Background 4 2.1 The Swedish national electricity grid . . . 4

2.2 Energy trade . . . 5

2.3 Balancing of electric power systems . . . 6

2.3.1 Operating reserves . . . 7

2.3.2 Other reserves and emerging markets . . . 8

2.4 Electric buses . . . 9

2.5 Svealandstrafiken . . . 9

2.6 Smart charging . . . 10

3 Theory 12 3.1 Frequency regulation by varying a load . . . 12

3.2 Frequency containment and restoration reserves . . . 13

3.3 Batteries . . . 14

3.3.1 Battery degradation . . . 15

3.3.2 Battery charging methods . . . 17

3.4 Genetic algorithm . . . 18

4 Method 20 4.1 Model configuration . . . 20

4.2 Smart charging algorithm . . . 21

4.3 Optimized charging and utilization of margin . . . 23

4.4 Optimization of FCR bids with Genetic Algorithm . . . 24

5 Implementation 27 5.1 Data and model parameters . . . 27

5.1.1 SoC calculations . . . 27

5.1.2 Margin . . . 28

5.1.3 Svealandstrafiken’s bus depot . . . 28

5.1.4 Frequency statistics and FCR market prices . . . 29

5.1.5 Calculating revenue from frequency regulation . . . 31

5.2 Simulated cases . . . 32

6 Result 34 6.1 Demonstration of the smart charging algorithm . . . 34

6.1.1 Case 1: Direct charging . . . 34

6.1.2 Case 2: Scheduled charging . . . 36

6.1.3 Case 3: Scheduled and prioritized charging . . . 38

(7)

6.2 Optimized utilization of margin . . . 39

6.2.1 Case A: Load balancing . . . 40

6.2.2 Case B: Minimize charging power . . . 41

6.2.3 Case C: Frequency regulation . . . 43

6.2.4 Case D: Electrify more buses . . . 45

6.3 Values of smart charging . . . 46

6.4 Sensitivity analysis . . . 48

7 Discussion 49 7.1 Smart charging and the simulated cases . . . 49

7.2 Future work . . . 51

8 Conclusion 52

A Appendix: Model parameters 58

B Appendix: Buses 59

(8)

Nomenclature

Symbol Unit/type Description

C kWh/km Average consumption of the buses

D km Estimated distance of a bus route

E kWh Battery capacity of a bus battery

Pavailable kW Power available for charging the buses

Pc kW Charging powers for each bus

Pc,bus kW Charging power for a specific bus

Pdemand kW Total power demand of the depot and buses

Pdepot kW Depot power capacity limit

Pload kW Base load of the depot

SoCg % The goal state of charge

SoCstart % State of charge at the beginning of the simulation

SoCt % State of charge at time t

t Point in time Time of the current iteration ta Point in time Arrival time of a bus td Point in time Departure time of a bus

tf ull Point in time Time when the bus was fully charged

Tf Period of time Time frame between when a bus is fully charged and it leaves the depot

(9)

1 Introduction

To achieve Sweden’s ambitious goal of no net greenhouse gas emissions by 2045 (Ministry of the Environment 2017) and an entirely renewable electricity production by 2040 (Government Offices 2016), there has been a significant increase in renewable energy sources in the Swedish electricity grid in the last ten years (Swedish Energy Agency 2020b). As the share of renewable energy sources in the form of wind and solar power increases and the share of nuclear power decreases, the Swedish electricity production altogether shift to a more non-dispatchable form of production with less moment of inertia (Svenska Kraftnät 2017). The shift creates challenges in controlling the balance of production and consumption of electricity and makes the power system more sensitive to disturbances. This puts a greater demand on power reserves to ensure stable grid operation and frequency regulation.

The electrical frequency of the grid must always be kept at 50 Hz with a precision of +/− 0.1 Hz counting as the normal interval. Higher or lower frequencies count as disturbances. To keep the balance of production and consumption, the Swedish transmission system operator (TSO) Svenska Kraftnät buys and sells reserves that help contain the frequency in its nominal interval. Historically, hydropower has been the primary reserve to handle the frequency regulation but in the future new technologies and innovative solutions will have to complement this regulation to counter the lack of inertia (ibid.).

A relatively new emerging reserve for frequency regulation is aggregated charging of electric vehicles (Power Circle 2019). By planning the charging of the vehicle, the load towards the grid can be adjusted in time, and by aggregating several vehicles the load can be increased to a size that is eligible to be traded as a product on the balancing markets, thus contributing to the balancing of the frequency.

This study has investigated a case, led by the innovation company Tvinn, to create a smart charging model of electric buses that enables the vehicle owner Svealandstrafiken to participate in frequency regulation while also ensuring normal operation of the buses.

1.1 Purpose

The purpose of this thesis project is to investigate how to design an aggregator energy system that utilizes smart charging to reduce peak power demand and to participate in frequency regulation to create an ancillary revenue. The asset owner investigated in this project is Svealandstrafiken, the energy system studied is their bus depot with associated electric buses and chargers and the grid support is in the shape of frequency regulation that utilizes margins within the system boundaries during normal operation.

The investigation includes the creation of a smart charging model that ensures that the electric buses are fully charged before they depart from the depot. Meanwhile, the model utilizes the margin, in terms of time and power, to place frequency regulating bids on a corresponding frequency balance market. The aim of the model is to find an optimal charging schedule for the buses that allows the buses to fully recharge while creating ancillary values or revenues for Svealandstrafiken.

(10)

1.2 Thesis questions

This thesis project aims to answer the following questions:

• How can a smart charging model that enables Svealandstrafiken to participate in grid support with their electric buses be constructed?

• How much can the power demand be changed by utilizing smart charging?

• How much revenue can smart charging with frequency regulation generate?

• What other ancillary values can be created from smart charging?

1.3 Scope

Optimizing the charging of an electric fleet involves knowledge in several disciplines. Therefore, the thesis is limited to the topics listed below:

• Only the Swedish power system and the frequency regulation markets operated by Swedish TSO Svenska Kraftnät is considered. The operating reserves are described in Section 2.3.1 and out of these the FCR-D Up reserve investigated.

• Calculations of power only include active power as only active power is relevant on the frequency regulation markets. Reactive power analyzes of power quality will not be discussed in the report.

• The ancillary services for the electric grid investigated in this report is limited to load balancing and frequency regulation.

• Only lithium-ion batteries are considered in the report.

• All the simulated cases are based on the electrification plans of Svealandstrafiken’s bus depot and do not include measured data.

• The simulations do not include cost estimations related to the operation.

(11)

1.4 Report structure

From here the report is divided into the following structure:

• Background: Puts the context of the thesis in a larger perspective.

• Theory: Introduces the theoretical background on frequency regulation, batteries, and genetic algorithm.

• Method: Describes the methodology of the work and the algorithms used.

• Implementation: Information about how the model parameters were calculated and how the simulations were implemented.

• Results: Presents the outcome of the simulations.

• Discussion: Discusses the results of the report and possible future work.

• Conclusion: Answering the thesis questions of the thesis.

(12)

2 Background

In this section, the context and setting of the thesis project will be presented to give the reader a thorough introduction to the content of the report. This background will place the method and results of the report in a larger context.

2.1 The Swedish national electricity grid

Due to the topography and demographics of Sweden, the electricity generation is mainly situated in the north of Sweden with large quantities of hydropower. The majority of the electricity consumption is located in the southern part of Sweden, which is more densely populated. To ensure efficient transfer of electric power, the electric grid is divided into a hierarchy of different voltage levels with different responsibilities: the transmission grid, the distribution grid, and the local grid. The transmission grid transports electricity at high voltages in a north-south orientation. The high voltage reduces the inherent losses of power transmission, but at the same time, it prevents end-users to connect to the grid due to the high voltage. Therefore, the voltage is stepped down in transformers before the power is transferred via the distribution grid. The distribution grid connects to local producers and larger consumers, such as energy-intensive industries. Finally, the voltage is stepped down once again as the distribution grid connects to the local grid which in turn provides smaller end-users with electricity at low voltages (Svenska Kraftnät 2021c).

The situation of high production in the north and high consumption in the south of Sweden leads to high demands on the transmission grid, demands that during certain periods of the year cannot be met. These situations, where a large amount of power must be transferred at a specific instant, can result in a bottleneck of the lines which is called a capacity shortage.

A capacity shortage means that there is a deficit of power at a specific time and place. This is not to confuse with an energy shortage, because Sweden is over the course of a year a net exporter of electricity (Swedish Energy Agency 2020a).

In 2011 the national grid was divided into four bidding areas from north to south (SE1, SE2, SE3, SE4). This worked as a successful attempt to address capacity shortages. When the transmission reaches the capacity limits within the bidding areas the pricing of the electricity will start to change between the areas which then will alleviate the most stressed areas.

Additionally, the differences in energy prices between the areas can act as an indicator of where to invest in development projects of the grid (Svenska Kraftnät 2017).

Hydropower and nuclear power stand for the majority of Sweden’s produced electricity with nuclear power acting as base power and hydropower as a regulator to match the consumption.

In 2018 41 % of Sweden’s electricity was produced by nuclear power, 39 % by hydropower, 10 % by wind power, and 0.4 % by solar power. The remaining 9 % was combustion-based power production (Swedish Energy Agency 2020a). The intermittent production is planned to increase significantly in the near future and with plans to shut down nuclear power plants, the hydropower will have to take on the role of base generation as presented in Figure 1. This will also increase the need for other types of regulatory energy sources (Svenska Kraftnät 2017).

(13)

Figure 1: Historical data of the electricity production and consumption of Sweden from 2010, 2015, and 2018 together with a forecast until 2050 (Swedish Energy Agency 2021).

2.2 Energy trade

Due to the difficulty of storing electricity, the power that is bought and sold on a power market is only an estimation of the actual power that will be delivered on the hour of operation. Therefore, the power markets are divided into different markets based on the time left until the hour of operation. Up to 10 years in advance of the hour of operation, actors can buy and sell electricity on a financial market held on Nasdaq (Nord Pool 2020). Financial contracts are long-term agreements used for price hedging and risk management. Closer to the actual operation hour, there are markets concerning the physical delivery of power. In the synchronous Nordic grids the physical markets are coordinated by the marketplace Nord Pool with the two markets: the Day ahead market and the Intra day market (ibid.).

Actors on the Day ahead marketplace bids of what volumes of power they can buy or sell and at what price for each hour of the following day. The actors are placing these bids within their respective bidding area of the grid until 12:00 when the market closes. Nord pool then compiles all bids and matches the bids of production and consumption to set the electricity price for each hour which is announced at 13:00 the same day. On the following day, the Intra day market allows for adjustments in production or consumption of electricity of the previously agreed bids from the Day ahead market. These adjustments can be made up to one hour before the hour of operation.

After that, the price is settled and the delivery of power takes place (The Swedish Energy

(14)

Markets Inspectorate 2021).

In addition to the markets at Nord pool, there is a different set of markets to handle the instantaneous balance of production and consumption during the hour of operation. These markets are held by the TSO and are divided into different categories based on how the products respond to an imbalance that occurs during the hour of operation.

2.3 Balancing of electric power systems

An electric power system must maintain a continuous equilibrium of power entering and leaving the system. This can be interpreted as a constant balancing act of the input power from generation and the output power in the form of loads and losses within the system. This balance can be measured by the electric frequency in the grid which has a nominal value of 50 Hz and should be kept within the interval of 49,9 Hz to 50,1 Hz during normal operation.

In Figure 2 the balancing act is illustrated. The Swedish national grid is synchronously connected to the grids of Finland, Norway, and Denmark. This means that the frequency is the same in the entire power system and that disturbances within the system can cause deviations from the interval which can damage connected components across the Scandinavian peninsula. The responsibility to operate the grids safely is therefore shared between the countries (Svenska Kraftnät 2021c).

Figure 2: The production and consumption of electricity always have to be balanced in a power system. This can be illustrated as a scale that weighs the electricity producers and electricity users with the grid frequency as the weighed quantity (Svenska Kraftnät 2021a).

Svenska Kraftnät, a state-owned authority, is the TSO of the Swedish power system. They own and operate the grid and maintain the balance between consumption and production.

In order to ensure the balance, Svenska Kraftnät authorizes other companies to balance the supply and demand of electricity locally by establishing balance responsibility agreements with local companies. An authorized company is called a balance responsible party. A balance

(15)

responsible party can be an electric supplier, but it can also be a company that electric suppliers contract to handle the responsibility in their place. The balance responsibility agreement includes planning and providing an hourly balance of the power situation for their customers. But as unplanned interruptions may occur and intermittent generation and consumption only are estimates of the actual situation, the plan rarely results in a perfect balance. To solve the imbalances, Svenska Kraftnät buys or sells power during the hours of imbalance from reserves which will be introduced in Section 2.3.1. The cost for restoring balance is paid by the actor that has caused the imbalance. This cost is based on standardized measurements taken by all parties in the grid and sent to Svenska Kraftnät, which processes the data and calculates the cost in a balance settlement (Svenska Kraftnät 2021a).

2.3.1 Operating reserves

The operating reserves that are available to handle deviations of the frequency are divided into several different products with different objectives that are bought and sold on their own respective market. The main differentiation of the reserves is the distinction of frequency containment reserves (FCR) and frequency restoration reserves (FRR) (Svenska Kraftnät 2020b). In the event of an accident in the grid that causes a frequency deviation, the first response is for the FCR to stop the continuous worsening of the problem and stabilize the situation by containing the frequency drop or rise. For example, if there is an unplanned loss of a large production plant in the grid which causes a drop in frequency, the main job of the FCR reserves is to stop the decline in frequency. The next step is for the FRR to restore the frequency from the stabilized lower level back to the nominal level. The restoration is first activated automatically and if that is not enough the manual reserves are activated. In the exemplified loss of production, the frequency might have started dropping from 50 Hz when the accident occurred, stabilized by the FCR to 49,5 Hz, and then restored back to the nominal 50 Hz by the FRR. The example is illustrated in Figure 3.

Figure 3: The different type of frequency control in the Swedish grid. The FCR interrupts the decline of frequency, the FRR restores the frequency, and the manual reserves are handling the long term imbalances (Eng et al. 2014).

The frequency containment reserves are divided further into frequency containment reserve

(16)

for normal operation (FCR-N), frequency containment reserve for disturbances (FCR-D), and fast frequency response (FFR). The frequency restoration reserves are divided into automatic (aFRR) and manual (mFRR) reserves. The different products are specialized to handle a specific interval of frequency where the requirements on endurance and speed differ. This implies certain technical requirements which will be explained in Section 3.2 and it also implies that the different reserves are bought and sold on different markets. Figure 4 shows a chronologically coherent illustration of the balance markets together with the Day ahead and Intra day markets introduced in Section 2.2.

Figure 4: The different electricity markets are shown as they are opened and closed before the hour of operation which is when the actual delivery of the traded power will take place (Svenska Kraftnät 2020b).

During the grey boxes in Figure 4, the auctions on each respective market take place which results in which reserves are procured. This means deciding which actor will operate during the hour of operation. There is a specific volume of the operating reserves that must be procured for each hour of each day. This means that Svenska Kraftnät will buy the operating reserves with the lowest price first until the specific volume of the reserve is met. As a result, a resource providing an operating reserve may not be procured if the competition is too high.

2.3.2 Other reserves and emerging markets

Along with the well-established balance markets, there are other emerging markets that can help counter capacity shortages and increase grid stability in the future. One such project, initiated by the European Union, is called CoordiNet which relies upon on-demand flexibility (Coordinet 2020). The idea is to create local marketplaces on the platform Flexmarket that allows for more efficient usage of the grid. By letting end-users with flexible consumption shift their consumption to hours that are less taxing for the grid, the end-users can help reduce capacity shortages. An example is for a household to have a remotely controlled dishwasher that can be automatically turned on according to the market that will help reduce the load in high-demand hours of the day.

(17)

The CoordiNet project has three pilot countries: Spain, Greece, and Sweden. The benefits that the project in Sweden is expected to bring are many but most importantly to make capacity more locally available and mitigate shortages as the grid develops. Potentially, demand flexibility markets can reduce grid development in the future at large (Svenska Kraftnät 2020a).

2.4 Electric buses

Electric buses are taking an increasingly larger share of public transport throughout Sweden.

The public transport company in Stockholm is aiming for 100 electric buses by 2022 (SVT 2019), in Gothenburg 150 electric buses went into service in December 2020 (Göteborgs Stad 2020) and smaller cities are following the example. The public transport company in Gävle recently bought 8 electric buses (ABB 2021) and Svealandstrafiken in Västerås have bought 10 electric buses with a preemption of 7 more (Svealandstrafiken 2020).

Switching to electric buses can be beneficial for several reasons, most notably the positive effects on the environment, energy consumption, noise, and health. WSP stated in their report Framtidens Kollektivtrafik i Västerås (2018), that the electrification of line 5 would apart from completely removing emissions while in traffic, also reduce the energy consumption by 70 % and the noise by 7 dBA which is a significant reduction in noise due to the scale being logarithmic.

There are several different types of electric buses. Firstly, there are hybrid buses with two drivetrains, one combustion and one electric, and then pure electric buses with only an electric drivetrain. Excluding hybrid buses, the electric buses can be further categorized by how they are charged which is either overnight charging in the depot, fast charging at bus stops throughout the day, or inductive charging that allows the bus to be charged while driving via either a charger device in the road or suspended above (Aldenius et al. 2016). Out of the projects mentioned above the most common type is overnight charging.

For the depot-charged buses to last an entire day they have large batteries of 500 to 600 kWh and are usually charged with 40 to 150 kW during the night. Buses that are charged at bus stops can instead have smaller batteries of 50 to 150 kWh but are charged with high power between 300 to 500 kW (Trafikförvaltningen 2018).

The bus types have their pros and cons which makes the choice of which technology to use difficult. Some of the parameters that influence the transport system are cost, reach, flexibility, and infrastructural demands (WSP 2018). The depot-charged buses will be more expensive and heavier due to the large battery but will not require expensive charging stations scattered throughout the city. Buses that charge at bus stops or inductively will not have the issue of returning to the depot to recharge but are at the same time strictly tied to a specific route that supports the specific charging technology (ibid.).

2.5 Svealandstrafiken

Svealandstrafiken is owned by the public transport authority of Västmanland and Örebro and their mission is to plan, develop and operate public transportation in both counties

(18)

in their respective brands VL-Buses and LT-Buses. An overview of the structure of the aforementioned organizations is shown in Figure 5. Svealandstrafiken’s fleet consists of 322 buses, of which 309 buses are powered by biogas, 5 by HVO and 5 buses are electric buses (Svealandstrafiken n.d.).

Tvinn has along with Svealandstrafiken, and several other parties recently initiated an ambitious project of reinventing their bus depot along with the electrification of the bus fleet.

This will include installing solar cells on the roofs and battery energy storage to utilize the resulting micro-grid of the depot more efficiently. The project has the possibility to support the local grid, increase the depot’s independence and level out peak demands (Schaap 2021).

This thesis focuses on the electrification of the VL-Buses fleet in Västerås where Svealand- strafiken has purchased 10 electric buses that are scheduled to be in traffic by late summer 2021 and 7 additional buses that will be delivered in 2022 (Svealandstrafiken 2020). These buses will operate in the regular bus lines meanwhile their current 5 electric buses are carrying out support services for the elderly and disabled.

Figure 5: A graphic overview of Svealandstrafikens owners and brands.

2.6 Smart charging

As more vehicles in society are being electrified, there has been a steep increase in services that support so-called smart charging (Lundqvist 2021). With the term being used frequently in the electric vehicle industry to describe several different services or values connected to charging vehicles, the organization Power Circle defined smart charging as a concept with different levels of smartness (Power Circle 2021). Power circle is an organization run by the Swedish Energy Agency dedicated to questions regarding electrification.

(19)

The levels of smartness defined by Power Circle while charging an electric vehicle ranges from level 0 to level 4:

• Level 0: No smartness. The vehicle starts charging when it is connected to a charger, also called direct charging.

• Level 1: Convenient features such as booking a charger at a public charging station through a mobile device or schedule charging to start at a later time.

• Level 2: Internal control. The charging is optimized within the facility’s limits. This could be managing the charging of several vehicles or scheduling such that the power never exceeds the fuse or subscribed grid connection, also called load balancing.

• Level 3: External control. The charger and/or electric vehicle takes the needs of the vehicle, facility, and the surrounding grid into account when planning the charging session. This includes taking tariffs and the electricity price into consideration.

• Level 4: Optimized charging. At the highest level of smart charging, the charging is operated by an external party that can control the charging of several vehicles or fleets of vehicles in order to optimize the needs of the vehicle owner, the facilities, and the grid. This actor is called an aggregator that can aggregate the charging to act of local flexibility markets or the balance markets with the charging vehicles acting as operating reserves.

This thesis investigates how Svealandstrafiken’s bus depot can plan the charging of their 17 purchased buses with an increasing level of smartness. In this case, the operating reserve that the buses will provide on the fourth level is chosen to be FCR-D Up. The different reserves will be explained in Section 3.2.

Making an FCR-D Up bid with the bus depot would mean that the charging of the buses would contribute to regulating up the frequency in the grid by decreasing the charging power in relation to how much the frequency drops below 49,9 Hz during the hour of the bid. By supporting the grid with this service, Svealandstrafiken could be able to charge their buses and at the same time create an ancillary revenue. The thesis will investigate how large savings Svealandstrafiken can make by applying the second level of smartness and how large revenue streams can be made from frequency regulation at the fourth level.

(20)

3 Theory

3.1 Frequency regulation by varying a load

The control center of a TSO monitor the grid frequency, generating outputs and power flows between areas in the grid to provide load-frequency control to maintain the grid frequency at its nominal value and power flows to their scheduled values (Duncan Glover et al. 2017, p.

741). One crucial part of this control is frequency regulation which ensures safe operation in an interconnected power system. It is traditionally performed by turbine generators (Duncan Glover et al. 2017, p. 761) but it can also be performed by electric vehicles that either act as variable loads or as distributed generation if the vehicles have vehicle-to-grid capability (Sortomme & El-Sharkawi 2012).

To relate variation of a load to the frequency, begin by considering the relation between steady-state frequency and power of a turbine generator. It is defined as

∆f

∆Pm = −R (1)

where ∆f is the change in frequency in Hz, ∆Pm is the change in turbine mechanical output power in MW and R is the regulation constant with the units Hz/MW (Duncan Glover et al. 2017, p. 762). This relation explains how one generator can help increase or decrease the grid frequency and by expanding the analysis to a larger area of the power system, the steady-state frequency-power relation of the interconnected power system becomes

∆f PN

n=1∆Pm = −1

β (2)

where the area frequency response characteristic β is defined as

β = 1 R1

+ 1 R2

+ ... + 1

RN (3)

for N generator units (ibid.).

As all units in a synchronous grid is connected, any power generated in a power system will be consumed by a load in the system (Duncan Glover et al. 2017, p.63). This premise and equation 2 show that changes to the production and consumption in a power system will affect the frequency and it can be concluded that frequency regulation can be performed by varying a load.

(21)

3.2 Frequency containment and restoration reserves

Different interconnected areas of a power system agree to both import and export a scheduled amount of power to each neighboring area and support in returning changes of the frequency to its nominal value (Duncan Glover et al. 2017, p. 768). To mitigate imbalances of the power flow, operating reserves are procured on balance markets as was introduced in Section 2.3.1. In Table 1 the reserves are shown with their different technical requirements.

Requirements on reserves

Reserve Minimum bid size Activation Volume

FFR 0.1 MW 100 % in 0.7 s at 49.5 Hz 100 MW

100 % in 1.0 s at 49.6 Hz 100 % in 1.3 s at 49.7 Hz

FCR-N 0.1 MW 49.9 - 50.1 Hz 240 MW

63 % in 1 min & 100 % in 3 min

FCR-D Up 0.1 MW 49.9 - 49.5 Hz 580 MW

50 % in 5 s & 100 % in 30 s

FCR-D Down 0.1 MW 50.1 - 50.5 Hz 560 MW

50 % in 5 s & 100 % in 30 s

aFFR 5 MW Automatic if f 6= 50Hz 140 MW

100 % in 2 min

mFFR 10 MW Manually at request -

(5 MW in SE4) 100 % in 15 min

Table 1: Technical requirements of frequency containment and restoration reserves (Svenska Kraftnät 2020b).

Each reserve has a minimum bid size which is the minimum amount of power that the reserve must provide. Activation means that the reserve responds to the frequency and starts consuming or delivering power to the grid depending on the type of the resource that is supplying the reserve. If it is a generation-based resource, it generates power towards the grid and if it is a load-based resource it consumes the power from the grid. Each reserve also must be activated to a certain amount within a certain period. The volume requirement is the total amount of power that Svenska Kraftnät has deemed necessary to procure for each hour every day (Svenska Kraftnät 2020b). That means for example that there is a total of 580 MW always ready to be activated as FCR-D Up if the frequency drops below 49.9 Hz.

The focus of this report is the FCR-D Up reserve, for this reason the following information is concerning FCR-D Up. Activation of the FCR-D Up reserve requires to follow a specific interval according to the graph in Figure 6. In the graph when the frequency drops below 49.9 Hz, the FCR-D Up resource has to respond with a certain amount of power related to its bid size. This means for example that the resource must be activated to approximately 50 % if the frequency is 49.7 Hz. The allowed outcome of the response makes it possible for stepwise activation of the resource as opposed to a linearly activated unit that would respond in direct relation to the target response.

(22)

Figure 6: A graph showing the activation regime of piece-wise linear FCR-D resources. The blue area from 49.9 Hz and below is the allowed outcome for FCR-D Up resources and the blue area from 50.1 Hz and above is the allowed outcome for FCR-D Down resources (Entsoe 2021).

3.3 Batteries

Batteries are one out of several technologies to store energy, other examples are stored energy as potential energy in water reservoirs, kinetic energy in flywheels or chemically in fuels.

Batteries themselves are differentiated into several different technologies but all work on the same principal that two electrodes are submerged in an electrolyte and separated by a separator to create a flow of electrons that allows the battery to store energy electrochemically (Battery University 2019). In this study, the focus lies on batteries with lithium-ion technology

therefore all examples are on lithium-ion batteries.

To discuss the characteristics of a battery several concepts must be defined. Here will the concepts capacity, state of charge, cycle, depth of discharge, charge rate and lifetime be introduced (ibid.).

• The capacity is how much energy the battery can store, usually measured either in ampere-hours (Ah) or kilowatt-hours (kWh). In this report, kWh will be used.

• State of Charge SoC is used to express the amount of energy currently stored in the battery related to its maximum capacity. This means a fully charged battery has a SoC of 100 % and a completely discharged battery have SoC of 0 %.

(23)

• A cycle refers to a full charge and discharge of the battery or vice versa. For example, letting the SoC go from 100 % to 0 % and back to 100 % again. Batteries are usually cycled in a smaller interval to increase battery lifetime.

• Depth of Discharge DoD is used to express the extent of a discharge or depth an interval of a cycle. DoD does not specify from which SoC. Both discharging from

100 % to 20 % SoC and from 90 % to 10 % SoC is an 80 % DoD.

• Charge rate C − rate refers to how quickly the battery is either charged or discharged with respect to its capacity. A fully charged battery of 1 kWh that is completely discharged during 1 hour have been discharged with 1 C. If it is recharged during half an hour it has been charged with 2 C.

• The lifetime of a battery is described in how many cycles it can undergo before its capacity decreases to a certain limit. Usually, this limit is 80 % of the nominal capacity. This means a battery could for instance have a nominal capacity of 100 kWh and withstand 5000 cycles before its capacity decreased to 80 kWh. The lifetime is strongly connected to DoD, C-rate, and operating temperature. High C-rates, DoD, and temperatures are taxing for the battery, thus reducing the lifetime of the battery which translates to fewer cycles before it reaches the limit (Battery University 2020b).

3.3.1 Battery degradation

Battery performance decrease during the lifetime of the battery due to elevated temperatures, aging and cycling (Battery University 2020b). The decreased performance can be translated into how much of the capacity that the battery can retain after a certain amount of time or certain number of cycles. A battery experiences capacity loss by simply aging which is accelerated at elevated temperatures, with temperatures above 30 C counting as an elevated temperature (ibid.). This behavior can be seen in Table 2. It can also be noted that the battery experiences a greater capacity loss when stored at higher SoC.

Battery degradation

Temperature 40 % charged 100 % charged 0 C 98 % (after 1 year) 94 % (after 1 year) 25C 96 % (after 1 year) 80 % (after 1 year) 40C 85 % (after 1 year) 65 % (after 1 year) 60C 75 % (after 1 year) 60 % (after 3 months)

Table 2: Amount of recoverable capacity of stored batteries. The batteries were stored at different temperatures over a one year period (Battery University 2020b).

Batteries also degrade when being used; this capacity loss is similar to the fatigue process of a material subjected to cyclic loading (Xu et al. 2016). The cycling of a battery depends on the DoD and the SoC levels where the cycle is performed, which can be seen in Figure 7 which shows the results of a study performed to model degradation of lithium-ion batteries (ibid.). The batteries were put through dynamic stress tests at different cycle intervals and

(24)

different DoD. Increasing DoD decreases battery retention when comparing the black and orange curve in the figure. It can also be seen that using an interval closer to the mid-range of the battery SoC increases capacity retention when comparing the red and the green curve.

Both the red and the green curve utilizes 60 % of the battery capacity but the green curve retains a higher capacity due to keeping the SoC in the mid-range of the battery SoC.

The final factor that will be mentioned concerning battery degradation is C-rate. High C-rates mean that the battery is charged or discharged fast but it also increases degradation of the battery, therefore some manufacturers of lithium-ion batteries recommend to charge at 0.8 C or less to increase the lifetime of the battery (Battery University 2020a). High C-rates is often referred to C-rates higher than 1 C, which means charging or discharging the battery in less than an hour. The rate of degradation can be increased if several stress factors are combined which was shown in the study Extending Battery Lifetime by Avoiding High SOC by Wikner & Thiringer 2018. The study showed that a battery cycled between 20 - 30 % SoC at 2 C retained a higher capacity than a battery cycled between 40 - 50 % SoC at 0.5 C after 5000 test cycles and concluded that C-rate affects the battery lifetime but not as much as cycling the battery at high SoC.

Figure 7: The capacity retention of a lithium-ion battery as a function of Dynamic Stress Test (DST) cycles. The degradation is affected both by the DoD and the interval of the cycle (Xu et al. 2016).

(25)

3.3.2 Battery charging methods

There are many different modes of charging electrical vehicles which varies both with the charger and the vehicles battery management system (BMS). The chargers can have static or dynamic outputs which can let the charger manage the power between a set of charging outputs (Kempower 2019) and the BMS can limit the charging to ensure safe and healthy charging (Battery University 2020c).

Four traditional methods of charging are CC, CV, CC-CV and MCC charging. CC stands for constant-current, and CV stands for constant-voltage, CC-CV is a combination of the two and MCC stands for multiple-stage constant-current. In CC-CV charging the charging goes through two stages as the SoC of the battery increases over time. To begin with a constant current is applied to the battery meanwhile the voltage increases gradually until a certain limit. This limit can be set to for example 80 %, where the next stage starts which lets the voltage remain constant and the current to decline as the battery is topped up before the charging session is complete. This is illustrated in Figure 8a.

The MCC method implies that the current is set to a step-wise decline of constant currents as the voltage reaches a predetermined value which can be seen in Figure 8b. Both the CC-CV and the MCC charging methods have proven to be simple and efficient ways to charge electric vehicles (Liu et al. 2019). The CC-CV method gives high capacity utilization and a stable terminal voltage and the MCC method is easy to implement and can easily achieve fast charging. The disadvantages of both methods are that it can be difficult to balance other objectives of the charging such as charging speed, temperature, and battery lifetime.

(a) The CC-CV charging method. (b) The MCC charging method.

Figure 8: Two graphs showing different charging methods with the battery current in red and battery voltage in blue as it charges (Liu et al. 2019).

(26)

3.4 Genetic algorithm

A Genetic Algorithm (GA) is a computational optimization method inspired by natural selection. The method is a heuristic global optimization algorithm that creatively encodes a potential solution to a specific function as a "chromosome" and then lets the solution evolve as it tends towards the global optimum (Whitley 1994).

The general optimization problem that the genetic algorithm will attempt to solve is to maximize f(x) subject to x ∈ Ω where x is a variable vector in the domain Ω ⊂ Rn and f is a real value function as f(x) : Ω 7→ R.

In the GA, a set of variable vectors are initialized as binary strings, and these bitstrings form a population P that from each iteration, called a generation, evolves by the evolutionary concepts evaluation, selection, crossover and mutation (Ali et al. 2005).

• Evaluation is performed by evaluating the function f(x) of each bitstring in population P for each generation which gives that bitstring a score. To evaluate f(x) the bitstring may have to be "decoded" to form valid inputs to f.

• Selection implies selecting the "parents" for the next generation. This is done through stochastic selection of parents in P with a bias towards bitstrings with high scores.

The selection can be modified to include duplication of parents and different levels of randomness and bias.

• Crossover is one out of two genetic operations that is applied to the selected parents to create the next generation. The crossover alters the selected parents by splitting the bitstrings at random index of each parent and exchanging the substrings of the parents to create two "children". A hyperparameter determines the rate of how often or if the crossover occur. A hyperparameter is a parameter whose value is used to control the

"learning" process of the algorithm.

• Mutation is the other genetic operation applied when creating the next generation.

The mutations are performed on a random subset of children by flipping a random bit in the children’s bitstring. The mutation is also governed by a hyperparameter that determines the rate of mutation.

Consider an example of how the reproduction is performed on two selected parents from the population P encoded as binary strings of five bits: Parent 1 = 00000 and Parent 2 = 11111 creates the randomly crossed over children Child 1 = 11100 and Child 2 = 00011 which then might mutate Child 1 to Child 1 = 11101 by flipping the last bit of the bitstring.

(27)

Applying all steps of the genetic evolution into an algorithm can be summarized into the following steps, which are inspired by the Controlled algorithm search and Genetic algorithm in A Numerical Evaluation of Several Stochastic Algorithms on Selected Continuous Global Optimization Test Problems presented by Ali et al. 2005.

• Step 1: Initialize the initial population P = {x1, x2, ..., xN}where each x is a bitstring uniformly sampled from Ω.

• Step 2: Evaluate f(x) of each bitstring in P .

• Step 3: Select the parents with the highest score from a random subset of P .

• Step 4: Create children from the selected parents by using crossover and mutation.

• Step 5: Repeat step 3 and 4 until N children are created.

• Step 6: Update the population P to be the set of children.

• Step 7: Go to step 2 and continue until a stopping condition is satisfied (e.g. a fixed number of generations or until fmax(x) − fmin(x) <  where x ∈ P and  is a hyperparameter connected to the specific implementation.

(28)

4 Method

In this section, the modeling of Svealandstrafiken’s bus depot will be explained along with the algorithms within the model.

4.1 Model configuration

As the model is developed in cooperation with Tvinn and the results from this project will be used as a starting point for further development, some details of how the model operates will be excluded. For more information about the model, the reader is encouraged to contact Tvinn1.

The model is written in Python which is an object-oriented language. This model handles the buses in the model as objects which allow for efficient sorting and storing attributes of the buses. A generalized representation of the model is shown in Figure 9 which shows the model inputs in the form of vehicles, chargers, and depot parameters. These inputs are run through a smart charging algorithm that yields a detailed output of the charging of the buses during a simulated period. The output returns a statement saying if the buses were fully charged or not, the SoC of all buses, and the power demand of the total system. Additionally, the model can take an input of a set of frequency regulation bids and plan those into the charging schedule. This restrains the charging further and will add an output of estimated revenue for the input bids. The process and decision-making of the smart charging algorithm will be explained in detail in Section 4.2.

Figure 9: A general representation of the model configuration showing the inputs and outputs to the smart charging algorithm.

1https://tvinn.se/

(29)

4.2 Smart charging algorithm

The smart charging algorithm decides which bus will be charged or not and calculates the power demand and SoC of all buses every iteration while taking the depot, chargers, and bid limits into account. In Section the terms and abbreviations used in the smart charging algorithm is presented.

Before the algorithm starts looping through the chosen period, the start SoC of each bus SoCstart is initialized as

SoCstart= SoCg−C[kW h/km] ∗ D[km]

E[kW h]

 (4)

where C is the average energy consumption while driving, D is the distance of the bus route, E is the battery capacity and SoCg is the goal state of charge. When a bus has reached its SoCg it is considered fully charged. By calculating the SoCstart from the SoCg, the charging and discharging cycle can be chosen to be a certain interval. This can help to ensure safe operation of the batteries as discussed in Section 3.3.1.

After SoCstartand the charging interval is determined the algorithm starts by loading arriving buses into the depot, removing departing buses from the depot, and removing buses that have reached its SoCg from the chargers. The buses that remain within the depot are either in the queue to be charged, idle since they are fully charged, or assigned to a charger. Which bus that will be charged first is determined by an attribute called time frame Tf that prioritizes the buses such that a bus with a short Tf will be prioritized over a bus with a longer Tf. Tf

is calculated as

Tf = td− tf ull = td− (t + (E ∗ (SoCg− SoCt))/Pc) (5) where Tf is defined as the interval between the departure time td and an estimation of when the bus will be fully charged tf ull. This means that buses with early departure times will be prioritized higher but also the buses that arrive with low SoC since tf ull takes the SoCt

into account. A bus with a low SoCt translates into having a longer charger time before it is fully charged. The buses are then assigned to the remaining chargers and charging priority is determined with respect to the buses’ Tf.

Before the buses are charged, the depot capacity limit for the current iteration is determined.

This is governed by the depot power capacity Pdepot, the baseload of the depot Pload, and possibly by any FCR bids placed Pbids. Determining and optimizing FCR bids will be explained thoroughly in Section 4.4, but ultimately, placing bids result in limiting the power available for the chargers to charge the buses. The power available to charge the buses Pavailable is calculated as

Pavailable = Pdepot− Pload− Pbids. (6)

(30)

When the depot power capacity is determined the next step of the algorithm is to set the charging power output to each bus, abbreviated to Pc,bus. Each bus has an individual charging power Pc,bus which is stored in a list called Pc. With the buses prioritized by Tf, Pavailable

will be divided among the chargers with buses assigned to them in falling order of priority.

The bus with the highest priority will be given its desired power output first and then the second in the prioritized list and so forth.

When determining how much power is distributed to each bus, the power is modeled step-wise to replicate an MCC charging method explained in Section 3.3.2, which lets the user of the algorithm determine when the steps will occur and the size of the steps. The MCC method is simplified into stepping down the power rather than the constant current and the steps occur at different SoCs of the battery rather than at different voltage levels during the charging session. Even though the charging method is simplified it was considered more accurate than constant charging throughout the charging session. With this method, the chargers will attempt to charge with as high power as the bus is able to receive, which is determined by the SoC of the bus battery. The charging output was chosen to follow the battery limits as shown in Table 3.

Battery limits SoCt intervals Pc,bus

[0%, 70%) 50 kW [70%, 80%) 40 kW [80%, 100%] 30 kW

Table 3: A table showing the battery limits and the corresponding maximum charging power the buses can receive.

The sum of the charging powers in Pc does not necessarily add up to Pavailable but when it does, the algorithm aims to maximize the use of Pavailable. To minimize the power not utilized, the chargers that receive the final portion of Pavailable might get a charging power that is less than the bus can receive. An example of the distribution of Pc in an arbitrary iteration is presented in Table 4. In the example, the buses are placed in falling order of priority. Bus 1, 2, and 5 can all receive 50 kW since they all have less than 70 % SoC but charging all with 50 kW would make the sum of Pc exceed the power capacity limit Pdepot. Therefore, bus 5 is charged with 20 kW to utilize all of Pavailable.

Charging power example Pdepot = 690 kW

Pload = 500 kW

Pavailable = 690 - 500 kW = 190 kW

Bus 1 2 3 4 5

SoCt 20 % 30 % 70 % 80 % 60 %

Pc,bus 50 kW 50 kW 40 kW 30 kW 20 kW

Table 4: An example of how the algorithm distributes Pc to the charging buses.

(31)

After the charging power has been set for each charger with an assigned bus with respect to the battery SoC, the total power demand of the depot can be determined as in Equation 7 where N is the number of buses assigned to a charger at the current iteration.

Pdemand = Pload+

N

X

n=1

Pc,n (7)

With the charging powers Pc determined, the buses are ready to be charged to the next time step which updates their SoCt according to Equation 8. Buses that are in traffic also have their SoCt reduced by the average energy consumption C while in traffic according to Equation 9, where the average speed v is calculated according to Equation 10.

SoCt+1 = SoCt+Pc[kW ] ∗ ∆t[h]

E[kW h]

 (8)

SoCt+1= SoCt−C[kW h/km] ∗ v[km/h] ∗ ∆t[h]

E[kW h]

 (9)

v[km/h] = D/(ta− td) (10)

4.3 Optimized charging and utilization of margin

By using the smart charging algorithm, the charging of the buses can be done more efficiently than charging each bus directly as it arrives at the depot. This efficiency can reduce the time to when the last bus is fully charged by charging all buses in a more compact manner.

This creates a margin that allows the charging of the buses to be flexible in ways that can create values for the asset owner. Depending on what Svealandstrafiken’s objective is, the margin can be utilized to either load balance the total power demand, minimize the charging power to each bus, participate in frequency regulation or electrify more of their fleet. The different cases are briefly explained below and the case to participate in frequency regulation is described thoroughly in Section 4.4.

• Load balancing: By spreading out the charging of the buses during the night, the total power demand of the depot can be minimized such that the subscribed power never exceeds a certain limit. To level out the power demand over a longer period is referred to as load balancing.

• Minimize charging power: Limiting the charging power to each individual bus increases the time it takes to charge each bus but can increase battery lifetime as explained in Section 3.3.1. This also reduces the total power demand of the bus depot since each charger will charge with a decreased power.

(32)

• Frequency regulation: The bus depot can participate in frequency regulation by placing bids on an FCR market. This means using the flexibility of the margin as a product that can be sold for profit rather than minimizing the parameters of the charging as in the other cases suggested above.

• Electrify more buses: Svealandstrafiken have both time and power available during a night to electrify more buses within the current bus depot power capacity and the time schedule of the simulated buses. Therefore, a fourth case was simulated to see how many buses that could be added within the margin.

All these cases were simulated as separate cases with the model parameters presented in Section 5 and the respective results presented in Section 6.

4.4 Optimization of FCR bids with Genetic Algorithm

Section 2.6 introduced that charging buses can be used as a balance reserve and this Section will explain how the model places FCR-D Up bids during a night of charging. The optimization is focused on how large and how many bids that the bus depot can make while still making sure that the buses can be fully charged. All bids are simulated as the limiting scenarios which mean that the bids always are simulated as 100 % activated. This means that there are no simulations on how the power adjusts to the frequency in this model.

The model is programmed to simulate the limiting scenarios and not actually adjusting the charging power in relation to the frequency variations during the bid hour.

The FCR-D Up reserve is chosen since it is considered to have the least impact on the charging of the buses. The reasoning behind it is that by acting on the FCR-D market the bids will not be activated as much when compared to the FCR-N market and by choosing FCR-D Up the buses will charge if not activated and decrease the power of the charge if activated. To regulate on the FCR-D Down reserve the buses would have to be charged with a lower power than in normal operation and occasionally increase the power if activated which interferes more with the normal charging compared to FCR-D Up. In conclusion, FCR-D Up is most likely the frequency regulating reserve that interferes the least with a normal charging schedule.

With the frequency being an unknown factor, making a bid on the market imply that the charging may or may not be limited during the bid hour. To make sure that the buses will be fully charged when placing a bid, the model always expect the limiting scenario which is an activation of 100 %. By expecting a full activation of the bids and still being able to fully charge the buses, the model can confidently guarantee that the buses will be fully charged regardless of how the frequency varies during the bid hour.

With this premise, a bid can be modeled as a power capacity restriction during an hour and an eligible bid can be determined by restricting the available power to the chargers for an hour and run the model. If the model returns that the buses are fully charged with the restriction, a bid of that size can safely be placed of that capacity during that hour. This can be expanded by placing several bids of different sizes to increase the amount of power in the aggregated bids during the night.

(33)

The buses stay in the depot from 18:00 to 06:00 and the bid sizes range from 100 kW up to the maximum power demand of the chargers during each hour in increments of 100 kW. This makes up a large quantity of possible sets of bids that can be made but only a fraction of all the combinations can be made and still fully charge the buses. Therefore, an optimization problem naturally arises: to choose which combination of bids allows for the buses to be fully charged while also making as large bids as possible. The number of combinations of bids that can be made makes finding the optimal set of FCR bids during a night a time-consuming problem to solve. For this reason, an optimization algorithm was used to maximize the amount of power placed in the bids while still allowing for a full recharge of the buses. The algorithm used is called Genetic Algorithm and was implemented as an extension to the original model as shown in Figure 10.

Figure 10: A figure illustrating the method used to finding optimized sets of bids during a night for Svealandstrafiken’s bus depot.

The process of finding the optimal set of bids starts with running the model without any bids which gives information about the SoC of all buses and the power output of the depot during the night. This initial charging session shows how the buses would charge both if there were no bids placed at all, and also if there were bids placed during the hours that the buses were charged that were not activated. This idea is used to determine the possible bids.

The second step is to analyze the output from the model of the first run. The possible bids are found by examining the minimum power demand of each hour during the night. Since the bus depot has a baseload, the power that can be regulated as a reserve is the power demand of the chargers. The power demand of the chargers is flattened to an even number of 100 kW to match the requirements of the FCR bid sizes which increase in increments of 100 kW with a minimum bid size of 100 kW. For instance, if the power demand is 1350 kW and the baseload is 500 kW during a specific hour, the largest bid that can be placed that hour is 800 kW.

The third step is to set up the Genetic Algorithm (GA) and create inputs to it such that it takes all the possible bids as inputs and then can be run to search for the optimal set of bids.

The GA was set up as the steps in Section 3.4 along with influence from the tutorial Simple Genetic Algorithm From Scratch in Python (Brownlee 2021). A crucial step in implementing the GA is to decode the bitstrings used in the GA into inputs that can be used by the smart charging algorithm. This was done by setting up a table from which the GA could decode a bitstring into bits that each represented a bid of a particular size for each hour that had a power demand of the chargers that met the technical requirements of the FCR-D reserve.

The table used for decoding is shown in Table 5. In the table, the green cells are determined in the previous step by analyzing the first output from the model when run without any bids.

That shows which hours that have power available to place in a bid and the maximum bid

(34)

size of each hour. The yellow cells are bid sizes that range from 0 kW to the maximum bid size and the blue cells are the key used to decode a bit from the bitstring into a certain bid size for the hour related to that bit. An example bitstring is decoded in Table 6 that show how the decoding is performed.

The fourth and final step is to run the GA. For each iteration the GA evaluates all bitstrings and determine if they are possible solutions that allow the buses to fully charge. If the buses are fully charged the bitstring is given a score of the total sum of the bid sizes. If the buses are not fully charged the score of the bitstring is 0. The output of the GA will be a viable solution with the highest score of all the combinations tried during the run.

Table 5: A table showing how the decoding was performed in the genetic algorithm (GA).

The bitstrings used in the GA are decoded into sets of bids that are used as inputs to the smart charging algorithm. The power demand and corresponding maximum bid sizes are taken from a charging session without any bids.

Table 6: A table showing decoding of an example bitstring that uses Table 5 to determine the bid sizes of each bid hour. The bitstring is divided into three bits per hour that acts as a key to find the bid size. This decoded bitstring results in seven bids of a total sum of 2900 kW. Running a simulation with these bids will not let the buses to fully charge which gives this bitstring a score of 0. If the buses would be fully charged, the score would be 2900 kW.

(35)

5 Implementation

5.1 Data and model parameters

As the report investigates future scenarios of Svealandstrafiken’s bus depot, no actual measurements have been taken. Instead, the findings in the report are based on plans of the new installations at Svealandstrafikens depot and data sheets of the purchased buses.

Additional necessary practical information for the model e.g., the energy consumption of electric buses and ideal SoC levels have been researched from similar studies and assumed in the model. All model parameters are presented in their entirety in Table 15 in the Appendix.

5.1.1 SoC calculations

From the bus datasheet, the battery capacity E of the buses is known to be 564 kWh but to calculate the SoCs of the buses in the model, several assumptions had to be made. The energy consumption C is assumed to be 1.8 kWh/km. This is based on a similar study that used 2 kWh/km with heating included (Beekman & van den Hoed 2016) and the buses that Svealandstrafiken have bought are heated occasionally by an internal combustion-heater that uses hydrated vegetable oil (HVO) which does not contribute to discharging the battery.

The goal SoC of a fully charged battery SoCg is chosen to be 85 % to have a DoD that cycles between 85 % and around 25% for the buses that are simulated. With a DoD of around 60

%, this is considered to be the healthiest interval as explained in Section 3.3.1. The DoD interval is determined by the distances S that the buses travel during the day, which was estimated by measuring the routes with Google Maps. An example of a bus route is shown in Figure 11 and the buses used in the simulation are presented in Table 16 with their respective circulation in the Appendix.

Figure 11: An example of how the distances for each bus circulation was estimated. The figure shows the route of bus line 3 which is measured to be 15.1 km.

References

Related documents

Samtidig användning av Oxikodon Depot Actavis och sedativa läkemedel såsom bensodiazepiner eller liknande läkemedel kan leda till sedering andningsdepression koma , , och

Detta projekt utvecklar policymixen för strategin Smart industri (Näringsdepartementet, 2016a). En av anledningarna till en stark avgränsning är att analysen bygger på djupa

To prove Theorem 1.2, we can state, in view of the general variational formula of p-capacity for general bounded convex domains, the p-capacitary Minkowski inequality for

Sådana insatser kan även gynna hyresgäster och andra brukare av lokaler i området om kommunen även stimulerar till kon- kurrens mellan olika områden.. Om så inte är fallet

the long run this tendency of the participating firms in these industries with few players to increase their market power could lead to a market with less players and more dominant

Tenthaus Winter Depot aims to create a different kind of meeting between artist and public outside the set prescription of exhibition opening or artist talk.. Tenthaus Oslo

Microsoft has been using service orientation across its entire technology stack, ranging from developers tools integrated with .NET framework for the creation of Web Services,

Přestože velmi často bývají oba termíny považovány za popis stejné transakce, není tomu tak. V prvním případě, tedy v případě akvizice dochází k tomu, že