87
Självständigt arbete på avancerad nivå Independent degree project - second cycle Masterexamen med huvudområdet elektronik Master of Science with a major in Electronics Modeling and Simulation of Solar Energy Harvesting Systems with Artificial Neural Networks Florian Gebben

Självständigt arbete på avancerad nivå - DiVA portalmiun.diva-portal.org/smash/get/diva2:1057197/FULLTEXT01.pdf · can model a solar panel with good accuracy. Equivalent circuit

  • Upload
    others

  • View
    7

  • Download
    0

Embed Size (px)

Citation preview

  • Självständigt arbete på avancerad nivåIndependent degree project - second cycle

    Masterexamen med huvudområdet elektronikMaster of Science with a major in Electronics

    Modeling and Simulation of Solar Energy Harvesting Systemswith Artificial Neural Networks

    Florian Gebben

  • MID SWEDEN UNIVERSITYDepartment of Electronics Design (EKS)

    Examiner: Bengt Oelmann, [email protected]: Sebastian Bader, [email protected]: Florian Gebben, [email protected] programme: Master of ScienceMain field of study: ElectronicsSemester, year: Spring 2016

  • Abstract

    Simulations are a good method for the verification of the correct operation of solar-powered sensor nodes over the desired lifetime. They do, however, require accuratemodels to capture the influences of the loads and solar energy harvesting system.Artificial neural networks promise a simplification and acceleration of the modelingprocess in comparison to state-of-the-art modeling methods. This work focuses onthe influence of the modeling process’s different configurations on the accuracy ofthe model. It was found that certain parameters, such as the network’s numberof neurons and layers, heavily influence the outcome, and that these factors needto be determined individually for each modeled harvesting system. But havingfound a good configuration for the neural network, the model can predict thesupercapacitor’s charge depending on the solar current fairly accurately. This isalso true in comparison to the reference models in this work. Nonetheless, theresults also show a crucial need for improvements regarding the acquisition andcomposition of the neural network’s training set.

    iii

  • Contents

    Abstract iii

    List of Figures vii

    List of Tables ix

    Acronyms xi

    1 Introduction 11.1 Background and problem motivation . . . . . . . . . . . . . . . . . 11.2 Overall aim . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21.3 Problem statement . . . . . . . . . . . . . . . . . . . . . . . . . . . 21.4 Thesis outline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

    2 Theory 52.1 Wireless sensor networks . . . . . . . . . . . . . . . . . . . . . . . . 52.2 Energy harvesting . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

    2.2.1 Solar panel . . . . . . . . . . . . . . . . . . . . . . . . . . . 62.2.2 Harvesting circuit . . . . . . . . . . . . . . . . . . . . . . . . 72.2.3 Energy storage . . . . . . . . . . . . . . . . . . . . . . . . . 8

    2.3 Modeling techniques . . . . . . . . . . . . . . . . . . . . . . . . . . 92.3.1 Equivalent circuit modeling . . . . . . . . . . . . . . . . . . 102.3.2 Artificial neural networks . . . . . . . . . . . . . . . . . . . . 11

    3 Methodology 153.1 Artificial neural network model . . . . . . . . . . . . . . . . . . . . 183.2 Reference models . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203.3 Discharge models . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203.4 Performance determination . . . . . . . . . . . . . . . . . . . . . . . 20

    4 Representation of the Solar Energy Harvesting Systems 234.1 Solar harvesting design . . . . . . . . . . . . . . . . . . . . . . . . . 23

    4.1.1 Load emulation . . . . . . . . . . . . . . . . . . . . . . . . . 24

    v

  • Contents

    4.1.2 On-board monitoring . . . . . . . . . . . . . . . . . . . . . . 254.2 Deployment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 254.3 Real-world data set . . . . . . . . . . . . . . . . . . . . . . . . . . . 26

    5 Synthetic Data Set Generation 295.1 Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295.2 Data sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305.3 Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31

    6 Artificial Neural Network Model 376.1 Implementation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376.2 Discharge model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386.3 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

    6.3.1 Comparing different architectures . . . . . . . . . . . . . . . 406.3.2 Varying the sampling interval . . . . . . . . . . . . . . . . . 426.3.3 Varying the input currents in the training set . . . . . . . . 436.3.4 Correlation between evaluation and simulation error . . . . . 456.3.5 Normalized vs. unnormalized data . . . . . . . . . . . . . . . 476.3.6 Best models . . . . . . . . . . . . . . . . . . . . . . . . . . . 48

    7 Reference Models 537.1 Equivalent circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53

    7.1.1 Implementation . . . . . . . . . . . . . . . . . . . . . . . . . 537.1.2 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56

    7.2 Lookup table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 597.2.1 Implementation . . . . . . . . . . . . . . . . . . . . . . . . . 597.2.2 Discharge model . . . . . . . . . . . . . . . . . . . . . . . . 607.2.3 Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60

    8 Discussion 63

    9 Conclusion 65

    Bibliography 67

    A Schematics 71

    vi

  • List of Figures

    2.1 Typical structure of a solar energy harvesting system . . . . . . . . 62.2 Cross section of a solar cell . . . . . . . . . . . . . . . . . . . . . . . 72.3 IV-curve of a solar panel . . . . . . . . . . . . . . . . . . . . . . . . 82.4 Single-diode equivalent circuit of a solar cell . . . . . . . . . . . . . 102.5 Equivalent circuit of a boost converter . . . . . . . . . . . . . . . . 102.6 Equivalent circuit of a supercapacitor . . . . . . . . . . . . . . . . . 112.7 Structure of a neuron in an artificial neural network . . . . . . . . . 122.8 Structure of an artificial neural network . . . . . . . . . . . . . . . . 12

    3.1 Modeling concept . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153.2 Modeling and simulation workflow for data-driven modeling methods 173.3 ANN modeling workflow . . . . . . . . . . . . . . . . . . . . . . . . 193.4 Discharge curves . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213.5 Harmonizing different sampling intervals . . . . . . . . . . . . . . . 22

    4.1 Real-world deployment of the solar energy harvesting systems . . . . . . 254.2 Simulation data BQ25504 . . . . . . . . . . . . . . . . . . . . . . . 274.3 Simulation data LTC3129 . . . . . . . . . . . . . . . . . . . . . . . 28

    5.1 Setup to generate ANN training data . . . . . . . . . . . . . . . . . 295.2 Synthetic training sets . . . . . . . . . . . . . . . . . . . . . . . . . 325.3 Real-world data distribution . . . . . . . . . . . . . . . . . . . . . . 335.4 BQ25504 evaluation sets . . . . . . . . . . . . . . . . . . . . . . . . 345.5 LTC3129 evaluation sets . . . . . . . . . . . . . . . . . . . . . . . . 35

    6.1 Structure of an artificial neural network in MATLAB . . . . . . . . 376.2 Comparison between models with and without low-current filter . . . . 396.3 BQ25505 performance diagram for different ANN architectures . . . . . 406.4 LTC3129 performance diagram for different ANN architectures . . . . . 416.5 BQ25504 performance diagram for different sampling intervals . . . 426.6 LTC3129 performance diagram for different sampling intervals . . . 436.7 BQ25504 performance diagram for different numbers of charging

    cycles in the training set . . . . . . . . . . . . . . . . . . . . . . . . 44

    vii

  • List of Figures

    6.8 LTC3129 performance diagram for different numbers of chargingcycles in the training set . . . . . . . . . . . . . . . . . . . . . . . . 45

    6.9 Relationship between evaluation and simulation performance . . . . 466.10 BQ25505 modeling duration . . . . . . . . . . . . . . . . . . . . . . 476.11 BQ25505 modeling performance . . . . . . . . . . . . . . . . . . . . 476.12 Simulation with the best performing BQ25504 model . . . . . . . . 496.13 Simulation with the best performing LTC3129 model . . . . . . . . 506.14 Zoom in on the discharge behavior to show the influence of the

    low-current filter . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51

    7.1 Equivalent circuit model . . . . . . . . . . . . . . . . . . . . . . . . 537.2 Equivalent circuit: Harvesting IC . . . . . . . . . . . . . . . . . . . 547.3 Equivalent circuit: Supercapacitor . . . . . . . . . . . . . . . . . . . 557.4 Equivalent circuit: Boost-converter . . . . . . . . . . . . . . . . . . 557.5 Equivalent circuit: Load . . . . . . . . . . . . . . . . . . . . . . . . 567.6 Equivalent circuit simulation BQ25504 . . . . . . . . . . . . . . . . 577.7 Equivalent circuit simulation LTC3129 . . . . . . . . . . . . . . . . 587.8 Lookup table model . . . . . . . . . . . . . . . . . . . . . . . . . . . 597.9 Lookup table simulation BQ25504 . . . . . . . . . . . . . . . . . . . 617.10 Lookup table simulation LTC3129 . . . . . . . . . . . . . . . . . . . 62

    viii

  • List of Tables

    2.1 Power densities of harvesting technologies . . . . . . . . . . . . . . 62.2 Comparison between a supercapacitor and a Li-Ion battery . . . . . 9

    4.1 Configurations of the solar harvesting systems . . . . . . . . . . . . 24

    6.1 MATLAB training settings . . . . . . . . . . . . . . . . . . . . . . . 386.2 Configurations of best performing ANN models . . . . . . . . . . . 48

    7.1 Excerpt from the BQ25504 lookup table . . . . . . . . . . . . . . . 60

    8.1 Comparison of different modeling techniques (BQ25504) . . . . . . 648.2 Comparison of different modeling techniques (LTC3129) . . . . . . 64

    ix

  • Acronyms

    ANN Artificial Neural NetworkEDLC Electric Double-Layer CapacitorIC Integrated CircuitLi-Ion Lithium-IonMOSFET Metal-Oxide-Semiconductor Field-Effect TransistorMPPT Maximum Power Point TrackingMAE Mean Absolute ErrorMSE Mean Square ErrorRMSE Root Mean Square ErrorRNG Random Number GeneratorSEHS Solar Energy Harvesting SystemSoC State of ChargeSPICE Simulation Program with Integrated Circuit EmphasisWSN Wireless Sensor Network

    xi

  • 1 Introduction

    1.1 Background and problem motivation

    Wireless Sensor Networks (WSNs), which have the ability to sense, compute andsend data and signals, help to gather information about their deployment envi-ronment and understand ambient events in order to be able to react to these.While this is also true for remote and hostile environments, a higher reliabilityfrom the system is demanded here as continuous maintenance is more difficult andnot desired [1].

    In this context a reliable system is able to handle the defined tasks for the desiredamount of time without disruption. Disruptions may occur due to an insufficientsuitability to the demands regarding environment or tasks, or due to power outages.As the amount of energy stored in a node is limited and in order to extend thetime until such an outage occurs, Solar Energy Harvesting Systems (SEHSs) canbe used to scavenge ambient energy to power the system or charge a battery.For some low-energy systems the harvested energy might be sufficient to ensurea perpetual operation, other more energy-intensive systems deplete their energyresources sooner, which can lead to a power-outage and, thus, a system failure.

    In order to be able to prognosticate which system can survive under which con-ditions it is important to model the system and be able to simulate its behaviorunder the given conditions. Many state-of-the-art modeling methods strive to de-scribe each of the system’s components as accurately as possible to obtain the fullmodel by a combination of submodels [2]. This approach is logical as the model’sstructure will follow the structure of the physical system. For simple harvestingarchitectures this relatively quick and straight-forward approach is sufficient andlikely the most efficient modeling method.

    However, many harvesting system incorporate more complex components, such asspecialized Integrated Circuits (ICs), that help to increase the efficiency. Thesecomponents demand either a simplification of their behavioral description or a

    1

  • 1 Introduction

    higher modeling effort. Therefore, other modeling approaches that aim to see thesystem as a unit rather than breaking it down into subcomponents can be useful.

    1.2 Overall aim

    The aim of this work is to gain insight into how the method of Artificial NeuralNetworks (ANNs) can be used for the modeling of solar energy harvesting. ANNshave the ability to learn behaviors by inspecting input and output data to identifytheir relationships and have already been used extensively for different modelingand forecasting tasks (see Chapter 2). Using ANNs promises to speed up theprocess of developing the model and to give the developer a method that caneasily be adapted to different harvesting architectures as there is no need to modelthe individual components [3].

    This work will provide insight on important parameters and steps in the processof generating an accurate and universal ANN-model, as well as determine how thisapproach compares to other modeling methods.

    1.3 Problem statement

    The objectives of this research can be described as follows:

    First, the influence of training set parameters on the model’s performance and theduration of training and simulation will be identified. Included in these parametersare the sampling interval of the data and the overall amount of data used to trainthe model. The training set will be generated synthetically in a laboratory in orderto obtain it within a short timeframe.

    Furthermore, it is necessary to identify, which ANN-architecture is the most suit-able with respect to good simulation results and whether or not this can be gen-eralized. Two main characteristics define the architecture: the number of hiddenlayers and the number of neurons in each layer (see Section 2.3.2).

    In order to contextualize the results from the ANN-modeling, it will be comparedto two reference models: another data-driven model (a lookup table) and an equiv-alent circuit model, which is the state-of-the-art technique for electronic systems.The comparisons will include the aspects accuracy, modeling effort, and simulationduration.

    2

  • Thesis outline 1.4

    1.4 Thesis outline

    The thesis is organized into nine chapters as follows:

    • Chapter 1 defines the problem that this work addresses.

    • Chapter 2 provides necessary background information along with examplesof modeling methods and their implementation in the literature.

    • Chapter 3 deals with the methods and the workflow of this work.

    • Chapter 4 introduces the solar energy harvesting systems that have beenused in this work.

    • Chapter 5 covers the acquisition of a synthetic data set.

    • Chapter 6 addresses the modeling of the solar energy harvesting systemsusing artificial neural networks.

    • Chapter 7 describes the implementation and results of two reference modelingmethods.

    • Chapter 8 discusses the results of the three different modeling methods.

    • Chapter 9 closes the thesis by summarizing the findings and suggesting fur-ther actions.

    3

  • 2 Theory

    2.1 Wireless sensor networks

    The term WSN describes a collection of interconnected embedded sensing devices,so-called nodes, which measure ambient values, such as temperature, humidityand vibration, and transfer these values to other members of the network. Inmany cases, these tasks only take a small percentage of the total run time. In themeanwhile, the nodes are usually in sleep mode to preserve energy. The relationbetween the active time tact and the total period T (active + sleep mode) is calledduty cycle (see Equation 2.1).

    D = tactT

    ∗ 100 % (2.1)

    Wireless Sensor Networks increase in popularity due to their potential in a widerange of applications, such as environmental [4] and industrial monitoring [5],motion tracking [6] and health care [7]. Another reason for this trend can be seenin recent technological advances, resulting in decreased costs and component sizesand, thereby, increased usability and profitability.

    2.2 Energy harvesting

    The lifetime of individual nodes in a WSN has a substantial influence on thereliability and robustness of the network as a whole. Depending on its topology, asingle node’s failure may jeopardize the functionality of the entire network.

    In order to prevent this from happening, it has to be ensured that each nodereaches at least its projected lifetime. This can be done by maintaining the systemregularly, which involves charging or changing the battery, but this often contra-dicts the reason for using WSNs: the “deploy-and-forget” principle. In order todecrease the need for maintenance and prolong the lifetime of nodes, a number of

    5

  • 2 Theory

    actions can be taken. Energy efficient components with low power consumptionand different energy modes are beneficial on the node-level, while on the network-level the implementation of energy aware routing protocols will ensure an evendistribution of the communication workload and a low energy overhead [8]. How-ever, these measures will only prolong the lifetime of the nodes, but not preventthe node from ultimately running out of energy. The only way to do this is byincorporating an energy harvesting system.

    Energy harvesting systems convert energy from ambient sources into electricalenergy, which is made available to the sensor node. Common energy harvestingmethods and their power densities are listed in Table 2.1. The table shows thatamong the listed harvesting technologies, solar energy harvesting offers the highestenergy density. Furthermore, solar energy is largely predictable [9], which canincrease the reliability of the SEHS. These advantages make solar energy the mainsource for harvesting ambient energy for WSNs.

    Table 2.1: Power densities of harvesting technologies [10]

    Harvesting technology Power density

    Solar cells (outdoors at noon) 15 mW cm−2

    Piezoelectric (shoe inserts) 330 µW cm−2

    Vibration (small microwave oven) 116 µW cm−3

    Thermoelectric (10 ◦C gradient) 40 µW cm−3

    Acoustic noise (100 dB) 960 nW cm−3

    Figure 2.1 shows a typical structure of a SEHS that supplies a node in a WSN. Inthe following the individual components are explained.

    Solar energy harvesting system

    Solar panelHarvesting

    circuitEnergy storage

    DC/DC MCU

    Sensor

    Wireless transceiver

    Wireless sensor node

    Solarradiation

    Figure 2.1: Typical structure of a solar energy harvesting system

    2.2.1 Solar panel

    While other components in an SEHS may be optional, a solar panel is indispens-able. It is responsible for converting the solar energy from the sun into electrical

    6

  • Energy harvesting 2.2

    energy. This is a result of the photoelectric effect, which frees electron-hole pairswith the help of the photonic energy of the solar radiation (see Figure 2.2). Onesolar panel incorporates multiple solar cells. The number of parallel and serial con-nected solar cells defines the rated output voltage and power of the solar panel.

    Figure 2.2: Cross section of a solar cell1

    2.2.2 Harvesting circuit

    The harvesting circuit is responsible for passing the electrical energy to the storageor load of the system. In the simplest case, the harvesting circuit is a diode betweensolar panel and energy storage to prevent discharge of the energy storage in timesthe voltage across the solar panel is lower. But this system is only applicable, ifa supercapacitor is used as storage and if the nominal voltages of solar panel andsupercapacitor match. In other cases, there could be undesirable effects, such as alow energy efficiency and destroyed components.

    In such cases, a DC/DC converter is necessary to match the voltage to the nom-inal voltage of the energy storage. Furthermore, certain batteries like Li-Ion bat-teries need a protection circuit to ensure a safe charge and discharge process. Amethod that is often used to improve efficiency of the energy harvesting process isMaximum Power Point Tracking (MPPT).

    The goal of MPPT is, as the term implies, to find the point in the IV-curve of thesolar panel, at which the power extraction is the highest (see Figure 2.3). There arevarious techniques of different complexity and accuracy available. An evaluationof the main MPPT techniques can be found in [11].

    1https://www.redarc.com.au/how-do-solar-panels-work

    7

  • 2 Theory

    0 VMP VOC

    Voltage

    0

    PMAX

    IMP

    ISC

    Cur

    rent

    , Pow

    er

    IV-curve of a solar cell

    Figure 2.3: IV-curve of a solar panel

    2.2.3 Energy storage

    In order to save the harvested electrical energy an energy storage has to be used.There are only a few applications that make no use of any energy storage. Theseso-called harvest-use systems consume the generated power directly [12].

    Most systems, however, make use of the harvest-use-store architecture. Systemswith such an architecture store energy that exceeds the demanded energy for theusage in times, when the harvested energy is lower than the energy demand.

    The most common energy storages in SEHS and energy harvesting in generalare Electric Double-Layer Capacitors (EDLCs), also known as supercapacitors,and batteries like the Lithium-Ion (Li-Ion) battery. Table 2.2 shows a comparisonbetween these two components.

    The table illustrates why supercapacitors are so popular in SEHS. Their high cyclelife allows them to be undergo an extensive number of charge and discharge cycleswithout losing their function. This is important as these cycles occur on a dailybasis and an energy storage losing its functionality results in a decreased systemreliability and an increased demand for maintenance. Furthermore, EDLCs can

    8

  • Modeling techniques 2.3

    Table 2.2: Comparison between a supercapacitor and a Li-ion battery [13]

    Category Li-Ion battery Supercapacitor

    Manufacturer Emmerich SamwhaModel ICR-18650 NQ-JI28 GreenCap DSNominal voltage [V] 3.7 2.7Operational range [V] 3.0 to 4.2 0 to 2.7Temperature range [◦C]charge 0 to 45 −40 to 60discharge −20 to 60 −40 to 60

    Typical capacity 2600 mA h 50 FInternal resistance [mΩ] 150 15Cycle life 300 500,000

    operate in a higher temperature range and need a less complex circuitry, whileallowing a quicker discharge due to their higher specific power.

    Li-Ion batteries, however, provide a longer run-time for medium loads, as theyoutperform EDLCs in terms of energy density. Besides, they have a relativelystable output voltage throughout the operational range, whereas the voltage ofthe supercapacitor is linear to the state-of-charge.

    2.3 Modeling techniques

    Modeling can be described as the “representation, often mathematical, of a process,concept, or operation of a system, often implemented by a computer program”.2

    Modeling is an important step in the development of an electronic system as ithelps the developer to make sure that the designed system operates as desiredand meets the necessary requirements. There can be several models that describethe same system, each of which is designed to represent a certain behavior of thesystem. When thinking of modeling a car, it is possible to have separate modelsto simulate the car’s aerodynamic behavior and its motion.

    There are several methods to model a system. Which method is chosen largelydepends on the system and which behavior of the system one is interested in.In the following, two methods including examples of how they are used in themodeling of SEHS are presented.

    2http://www.dictionary.com/browse/modeling

    9

  • 2 Theory

    2.3.1 Equivalent circuit modeling

    An equivalent circuit is the theoretical representation of an electronic circuit thatcontains all relevant electrical characteristics of the real circuit. Figures 2.4, 2.5,and 2.6 show exemplary equivalent circuits for a few components in an SEHS: solarpanel, boost-converter, and supercapacitor.

    In [14], the authors show that a single-diode equivalent circuit (compare Figure 2.4)can model a solar panel with good accuracy. Equivalent circuit models of powerconverters, among others buck and boost converters like the one shown in Fig-ure 2.5, are presented in [15]. EDLC models have been in the focus of [16]. Theauthors do not only use the simple model shown in Figure 2.6, but also morecomplex models and their utilization for a range of components.

    D RSH

    RS

    Iph V

    ID ISH

    Figure 2.4: Single-diode equivalent circuit of a solar cell

    D

    RLVS

    IC

    C

    L

    S

    VO

    Figure 2.5: Equivalent circuit of a boost converter

    Various tools can be used to implement an equivalent circuit. One is to use thecircuit simulator Simulation Program with Integrated Circuit Emphasis (SPICE)or one of its adaptions, like PSPICE. Also several IC manufacturers have developedtheir own SPICE-based tools (e.g. TINA by Texas Instruments or LTspice byLinear Technology). The advantage of these tools is that often accurate componentmodels are provided by the manufacturer. Mathwork’s Simscape Power Systemsis another tool that offers component libraries. It provides, for example, a genericEDLC model3 that includes basic parameters such as the serial resistance andserial and parallel capacitance but also allows more complex settings.

    3http://mathworks.com/help/physmod/sps/examples/supercapacitor-model.html

    10

  • Modeling techniques 2.3

    ESR

    ISC

    C0 RP

    IC0

    ILeak

    Figure 2.6: Equivalent circuit of a supercapacitor

    Another modeling alternative is converting the equivalent circuit into a math-ematical model. Therefore, equations need to be extracted from the equivalentcircuit. Next, the model can be implemented in MATLAB Simulink. [17] presentsthe implementation of the single-diode model for a solar panel as a mathematicalmodel in MATLAB Simulink, which was also the tool of choice for implement-ing the converter models in [15]. Here, the authors point out the low simulationtime, something that was also mentioned in [18]. The latter study models a bat-tery/supercapacitor hybrid energy storage in Simulink.

    Which of these tools one chooses largely depends on the goal of the simulation.SPICE and Simscape Power Systems are exceptional for detailed transient analysis,whereas the mathematical models can often offer a lower simulation time.

    2.3.2 Artificial neural networks

    ANNs are a subdiscipline of machine learning and as such belong to the family ofartificial intelligence. The concept is derived from the biological neural network,which is a network of computational cells, so-called neurons. These neurons processsignals coming form their inputs (dendrites) to send a new signal over their outputs(axons) to other neurons.

    Figure 2.7 shows the structure of a neuron in an ANN. A possible limitless numberof signals is weighted individually and added up along with a bias value, before atransfer function defines the neuron’s output. The neuron’s output can be calcu-

    11

  • 2 Theory

    w1

    w2

    w3

    wn

    f(s)

    i1

    i2

    i3

    in

    b

    os

    Activation function

    Figure 2.7: Structure of a neuron in an artificial neural network

    lated as follows:

    output = f(n∑

    i=1(wn ∗ in) + b) (2.2)

    A network of such neurons forms an ANN. The example network in Figure 2.8has one input layer with two inputs and one output layer with one output. Thenumber of neurons in these layers corresponds to the number of inputs and outputs.Furthermore, there are two hidden layers. Each hidden layer contains a certainnumber of parallel neurons. The possible number of hidden layers and their neuronsis indefinite.

    Hidden layers Output layerInput layer

    Input 1

    Input 2

    Output

    Figure 2.8: Structure of an artificial neural network

    Just like the biological neural network, ANNs possess the ability to learn. Thatmeans that the weights and biases of each neuron can be set individually in orderto produce a certain network behavior. The process of updating the weights andbiases is called training.Necessary for the training is a training set. This is a set of data that contains allthe information that the network is supposed to learn. This data is presented to alearning algorithm, which uses this data to continuously update the weights and

    12

  • Modeling techniques 2.3

    biases in an optimization procedure.Artificial Neural Networks can be used to carry out various tasks. Their ability tosolve classification problems can be used in the medical sector to aid in the diag-nosis of breast cancer [19, 20]. Another application area for ANNs is the modelingof systems in order to understand their behavior or forecast events. [21] reviews51 hydrological ANN-models and comes to the conclusion that this method is wellsuited for that field, but standardization is needed to increase its feasibility. Alsostock market behavior has been suggested to be modeled through ANNs with anaccuracy that is similar to more complex methods [22].

    ANNs have also been used in the modeling of components in a Solar Energy Har-vesting System. [23] presents the modeling of the specific capacitance of a newly-developed Neem-based supercapacitor using an ANN. Their results are promisingand the authors suggest to increase the amount of model inputs in order to sta-bilize its performance. In [24] the authors use ann ANN-based model of a solarcell to predict the parameters of an equivalent circuit based on temperature andsolar irradiance. The results show that the ANN-aided model outperforms theconventional model in the prediction of the solar panel’s power-voltage-curves.

    Also electrical energy storages have been in the focus of research: An ANN com-bined with an extended Kalman filter was used in [25] for modeling Lithium-Ion batteries and estimating the state-of-charge. The authors of [26] show thatANN-models can predict the State of Charge (SoC) of batteries and battery-supercapacitor hybrids with good accuracy.

    In [27] an approach is presented that uses ANNs to model a solar energy harvestingsystem consisting of a solar panel and a supercapacitor. The results show promis-ing results for the given architecture. However, the authors recommend furtherstudies with different systems and an investigation of the influence of the ANN’sstructure.

    13

  • 3 Methodology

    The general concept of the SEHS-models in this work is shown in Figure 3.1. Themodels are designed in such a way that they will take the momentary values ofinput_current and output_voltage as model input to predict the next value ofoutput_voltage, which consequently will be, along with the next input_current-value, the next model input. input_current is the current that flows from thesolar panel of the SEHS to the harvesting controller, whereas output_voltage isthe voltage across the supercapacitor.

    output_voltage(t+1)

    Discharge Model

    Charge Model

    output_voltage(t)

    input_current(t)

    Sum

    Figure 3.1: Modeling concept

    As mentioned in Chapter 1, the training set for the ANN-modeling will be obtainedin a laboratory environment. This is due to the fact that the training set needsto include all necessary behaviors of the system that is to be modeled. Obtainingthis kind of data set in a real-world deployment is a long and possibly unsuccessfulprocess, as it is possible the data will only reflect the deployment’s environment.A measuring setup in the laboratory allows controlling the input to the systemand thereby the dimensions and form of the training set itself.

    However, this approach has a downside. Building an accurate setup for the gen-eration of a data set that shows the relationship between the solar radiation andthe supercapacitor’s voltage is either laborious or costly, as a fully-dimmable solarsimulator would be required, which is able to replicate the spectrum of the sunexactly. Therefore, we decided to use the current from the solar panel instead ofthe solar radiation as input to the model.

    Figure 3.1 also shows that there are separate models for charge and discharge.One could think that needing two separate models is a disadvantage, as it seems

    15

  • 3 Methodology

    to require more effort to create the individual models. But this additional step hasseveral positive aspects, such as creating the training set for the ANN-model is a loteasier if the focus is on the charging process alone. This is due to the need to showall possible cases to the ANN training algorithm. An ANN is good at interpolatingbetween known data, but is not able to extrapolate beyond that (think of thebehavior of a cubic function, which interpolates monotonically decreasing datapoints, outside the scope of the given data).

    Even in the simple case of a solar-powered sensor node with a constant load,which is an unrealistic scenario in a WSN, the amount of time needed to collectthe necessary data increases, as the charging process slows down. With an evenmore complex load, such as a schedule-triggered measurement/communication or,even more demanding, triggered by an external signal (node or event), the numberof cases that need to appear in the training set is too high and the effort to obtainthe data too great for that data acquisition to still be reasonable.

    Furthermore, even if we were able to obtain a complete training set for such con-ditions, this model would only apply to the specific system in question and couldnot easily be adapted to a slightly different system. This kind of flexibility canonly be archived with separate models for charge and discharge.

    In this work three different charge models are used, but the main focus lies onthe ANN-model, which will be compared against a lookup table model and anequivalent circuit that is implemented as mathematical model. The following stepsare necessary in this process:

    1. Designing the SEHS2. Generating artificial data3. Obtaining real-world data4. Implementing the ANN-model5. Implementing the reference models

    After designing the two SEHSs and testing their functionality, an experimentalsetup is built with the goal to generate the synthetic data set, which consists ofboth training and evaluation set.

    Furthermore, both systems will be installed in a real-world deployment to measureinput and output along with solar irradiance. This data set will later be used assimulation set to test all models on accuracy.

    16

  • Methodology 3

    Modeling

    Lab-generated data set (T=1s)

    Real-world data set (T=60s)

    Preprocessing & interpolation

    Preprocessing & interpolation

    Evaluation

    Simulation

    Simulation set (T=2s)

    Evaluation set (T=2s)

    Training set (T=2s)

    Figure 3.2: Modeling and simulation workflow for data-driven modeling methods

    17

  • 3 Methodology

    3.1 Artificial neural network model

    The generation of the ANN-model is done with the help of MATLAB and itsNeural Network Network Toolbox. The toolbox provides functions to create, trainand evaluate neural networks. Furthermore, it provides a graphical user interfacethat assists the user in the first steps without requiring detailed knowledge of thealgorithm. During the process of implementing custom ANNs, however, usage oflower-level functions is necessary.

    Figure 3.2 show the workflow of the ANN modeling. First, the synthetic trainingset is used to model the data, followed by an evaluation of the model with datathat has also been generated synthetically. Finally, the simulation tests the modelbehavior on real-world data.The ANN modeling process is a subprocess, which is pictured in Figure 3.3. First,the architecture of a ANN is defined. This includes the inputs and outputs, thenumber of layers and neurons, as well as the transfer function and the fundamentaltraining setting, such as the training algorithm. After that, the network’s weightsand biases are initialized. As the outcome of the training can vary strongly withdifferent initial values, multiple trials are run for the same architecture. This way,we can see how much the results fluctuate.

    When MATLAB trains the ANN, the training set is split into three sets: training,validation and testing. This is to avoid overfitting, an effect that occurs if anANN possesses low generalization and is, thus, unable to accurately predict valuesoutside the training set.1 The training data is used to iteratively update all weightsand biases. Meanwhile, the network is validated against the second part of the dataand the error is calculated. If this validation performance does not increase fivecalculations in a row, or if the gradient of the training is below a certain threshold,the training has reached its stop condition. In the following step, the ANN is testedwith the third fraction of the training set, the test set, by computing the error.In order to avoid overfitting it is important that the three sets are not identical,as the calculation results would not be conclusive in that case. In this work, whenthe term training set is used, it refers to the data, before MATLAB divides it intothe three parts.

    When MATLAB has run all trials, the models can be evaluated and simulated (seeSection 3.4).

    1https://de.mathworks.com/help/nnet/ug/improve-neural-network-generalization-and-avoid-overfitting.html

    18

  • Artificial neural network model 3.1

    Define ANN architecture

    Initialize weights & biases

    Train the ANN

    Calculate & store performance

    Restore best-performing ANN

    All trialstrained?

    No

    Yes

    Figure 3.3: ANN modeling workflow

    19

  • 3 Methodology

    3.2 Reference models

    Both the modeling by lookup table and the mathematical model is performed inMATLAB Simulink. MATLAB provides extensive functions for matrix calcula-tions, whose result can be used in Simulink blocks to create the lookup table. Thiscombination of tools is very convenient for this modeling.

    As for modeling the equivalent circuit, it would be possible to use the SPICE-adaptions LTspice (Linear Technology) and PSICE, as models for the harvestingICs that we used in this work are provided for theses tools. However, these modelsneed a tremendous amount of simulation time. For instance, the exemplary cir-cuit provided by Texas Instruments uses a 1 µV supercapacitor and is rated witha simulation time of 45 min for the transient simulation only. As the great accu-racy for the IC’s transient behavior is not necessary for this work, we decided toimplement the equivalent circuit as mathematical model in MATLAB Simulink.Before implementing the mathematical model the SEHS’s equivalent circuit willbe created. This is followed by the determination of the electrical characteristics,gathered from the components’ data sheets.

    3.3 Discharge models

    In order to model the discharge behavior of the two systems, a complete dischargecurve has been selected from real-world data for each model. The discharge curvescan be seen in Figure 3.4.

    The implementation of the discharge models depend on the method that has beenused for the charge model, as they need to complement each other. The dischargeof the ANN model will be represented by a regression, while the lookup tablemodel will use each one lookup table for charge and discharge. The equivalentcircuit models the discharge as Simulink blocks, which describe the behavior ofthe boost-converter and the resistor and which determine the discharge current.

    3.4 Performance determination

    Performance means the accuracy with which a model is able to predict the outputfor a given input. In other words, it is the difference between simulation and targetvalues. There are several ways to measure the performance. A few of the most

    20

  • Performance determination 3.4

    0 500 1000 1500 2000 2500

    Sampling intervals [1T=60s]

    0.8

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    Discharge curve BQ25504

    (a) BQ25504

    0 500 1000 1500 2000 2500 3000 3500 4000

    Sampling intervals [1T=60s]

    0.8

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    Discharge curve LTC3129

    (b) LTC3129

    Figure 3.4: Discharge curves

    common ones are the Mean Absolute Error (MAE), the Mean Square Error (MSE),and the Root Mean Square Error (RMSE).

    In this work the RMSE has been used for all performance determinations, bothfor the evaluation of the ANN-models and the simulation of all models. Its unitis the original unit of the values and compared to the MSE larger errors have ahigher influence on the performance (see Formula 3.1).

    RMSE =√√√√ 1n

    n∑i=1

    (Vtarget(i) − Vsim(i))2 (3.1)

    In order to be able to correctly use a model, it is important to harmonize the

    21

  • 3 Methodology

    sampling interval (the time between two data points in a time-series of data) of alldata streams that are used in the modeling process (see Figure 3.5). In the caseof the ANN-model this means that the time distance between two values in thetraining, evaluation and simulation set must have the same length. The definedsampling interval will always be between the sampling intervals of the artificialand the real-world data set.

    In order to do this harmonization, the sampling interval of the training set will beincreased by skipping the appropriate number of values, while the sampling intervalof the simulation set will be decreased by interpolating between two values.

    Defined sampling interval:

    Training set:

    Simulation set:

    T_model

    T_trainingSet

    T_simulationSet

    Figure 3.5: Harmonizing different sampling intervals

    22

  • 4 Representation of the SolarEnergy Harvesting Systems

    4.1 Solar harvesting design

    For the purpose of this project two SEHS have been designed. For both systems tobe comparable, they fulfill the same function: charging an EDLC with a rated volt-age of 2.7 V and a capacitance of 35 F by harvesting solar energy with a 1 W solarpanel with a nominal voltage of 5 V. Therefore, two ICs have been selected thatare developed for energy harvesting applications and match these specifications.

    Texas Instruments’ BQ255041 is an ultra power DC/DC boost converter with thecapability of charging supercapacitors and various kinds of batteries. The sameapplies to the LTC3129 by Linear Technology.2 Both components include a basicMPPT-functionality. This means that by connecting the appropriate pins to aresistor divider, the chips will control the input voltage to operate with improvedefficiency. The BQ25504 also allows for the MPPT to be implemented externallyto further improve the efficiency by using a more complex method.

    Throughout this work, the model number of the harvesting chip (BQ25504 orLTC3129) will be used to refer to the harvesting board that contains this chip.

    1http://www.ti.com/product/BQ255042http://www.linear.com/product/LTC3129

    23

  • 4 Representation of the Solar Energy Harvesting Systems

    Table 4.1: Configurations of the solar harvesting systems

    Module Implementation

    Solar panel POW111D2P, 80 mm × 100 mm, 1 W, 5 VHarvesting IC BQ25504 / LTC3129Energy storage Supercapacitor 2.7 V, 35 FBoost converter TPS61070Load 137.5 µA constant drainMonitor LTC2990

    The boost-converter TPS61070 by Texas Instruments is used to convert the voltageof the EDLC to a constant voltage of 3.3 V. It operates down to the minimuminput voltage of 0.9 V and is rated with an efficiency of 90 %. The output of thisboost-converter is the output of the SEHS.

    Table 4.1 shows all components of the harvesting board. The complete circuit isshown in Appendix A.

    4.1.1 Load emulation

    The harvesting board offers a load emulation to test different load scenarios with-out the need to attach a real sensor node. Therefore, three MOSFETs can beswitched individually to connect one resistor each to the output of the TPS61070boost-converter. This way, the user can assign each resistor to emulate a specifictask (e.g. sensing, communicating). Additionally, one fixed and non-switchable re-sistor can be installed to mimic a constant load. The latter has been made useof in this project. A resistance of 24 kΩ, which translates to a constant current of137.5 µA, is slowly discharging the supercapacitor.

    This constant load corresponds to a duty cycle of 0.64 % for the example of thecommercial wireless measurement system MICAz by Crossbow,3 which is a sys-tem created for embedded sensor networks and which is equipped with an IEEE802.15.4 transceiver. In this example the active current is defined by the consump-tion of an active microcontroller and the transceiver sending data with a powerlevel of −10 dB m, while in sleep mode both components are set to the lowestpossible energy mode.

    3http://www.openautomation.net/uploadsproductos/micaz_datasheet.pdf

    24

  • Deployment 4.2

    Knowing the currents in active mode and sleep mode and assuming that these areconstant, the duty cycle can be calculated with Equation 4.2.

    Iavg =Iactive ∗ tactive + Isleep ∗ (T − tactive)

    T(4.1)

    D = tactiveT

    = Iaverage − IsleepIactive − Isleep

    (4.2)

    4.1.2 On-board monitoring

    On the harvesting board the voltages across the solar panel and across the su-percapacitor as well as the input and charge current are monitored. This task isexecuted by the LTC2990 by Linear Technology.4 This IC is able to measure thevalues with an accuracy of 1 % and a resolution of 14 bit.

    4.2 Deployment

    The harvesting board has an interface to the SENTIO-em, a sensor platform de-veloped at Mid Sweden University [28]. Attached to the the sensor platform is anXBee 2.4GHz module that is running an IEEE 802.15.4 communication protocol.Furthermore, the Pyranometer 6450 Solar Radiation Sensor by Davis Instruments5

    is in place to measure the solar radiation.

    SENTIO-em(data collection)

    Raspberry Pi(data storage)

    Remote Computer

    CurrentsVoltages

    Irradiance

    Pyranometer6450

    SSH-connection

    LTC3129 system

    CurrentsVoltages

    Irradiance

    BQ25504 system

    CurrentsVoltages

    Figure 4.1: Real-world deployment of the solar energy harvesting systems

    4http://cds.linear.com/docs/en/datasheet/2990fd.pdf5http://www.davisnet.com/product_documents/weather/spec_sheets/6450_SS.pdf

    25

  • 4 Representation of the Solar Energy Harvesting Systems

    The ARM Cortex-M3 microcontroller on the SENTIO-em triggers the measure-ments of voltage, current and solar radiation with a sampling rate of 1/60 Hz, thatis one measurement every minute. After each measurement the data is sent overthe communication interface to a Raspberry Pi, which is responsible of storing alldata. The data can be accessed over an SSH-connection by a computer on thesame network.

    This setup has been placed in a permanent deployment in Sundsvall (Sweden) withthe solar panels orthogonal to the ground to prevent them from being covered aftersnowfall.

    4.3 Real-world data set

    Figure 4.2 shows segments from the real-world data set obtained using the BQ25504-system. The LTC3129-system collected the data segments shown in Figure 4.3. Foreach of the systems, two segments (one collected in summer and one in winter),have been chosen to serve as simulation set to determine the performance of eachmodel that is created later in the process (see Chapter 6 and 7).

    The Swedish winter is characterized by long periods of darkness, while the sun setsonly for a short time in summer. This is why there are two quite different curvesfor the supercapacitor voltage of each system.

    One phenomenon that stands out in the LTC3129 system is that the voltage acrossthe EDLC drops every time the input current rises after the night and when thestate of the harvesting system is supposed shift from discharging to charging. Thisbehavior is yet to be investigated.Remarkable is also that there is little difference in the level of the input currentwhen comparing the summer and winter segments for the LTC3129 system. Thisis caused by a current regulation within the IC, which will also be mentioned lateron in Chapter 5.

    26

  • Real-world data set 4.3

    0 500 1000 1500 2000 2500 3000

    Sampling intervals [T] (1T = 60s)

    0

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    Inpu

    t cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Inpu

    t vol

    tage

    [V]

    BQ25504 Simulation Data - Summer

    (a) Summer

    0 500 1000 1500 2000 2500 3000

    Sampling intervals [T] (1T = 60s)

    0

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    Inpu

    t cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Inpu

    t vol

    tage

    [V]

    BQ25504 Simulation Data - Winter

    (b) Winter

    Figure 4.2: Simulation data BQ25504

    27

  • 4 Representation of the Solar Energy Harvesting Systems

    0 500 1000 1500 2000 2500 3000

    Sampling intervals [T] (1T = 60s)

    0

    1

    2

    3

    4

    5

    6

    7

    8

    Inpu

    t cur

    rent

    [A]

    #10-3

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Inpu

    t vol

    tage

    [V]

    LTC3129 Simulation Data - Summer

    (a) Summer

    0 500 1000 1500 2000 2500 3000

    Sampling intervals [T] (1T = 60s)

    0

    1

    2

    3

    4

    5

    6

    7

    8

    Inpu

    t cur

    rent

    [A]

    #10-3

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Inpu

    t vol

    tage

    [V]

    LTC3129 Simulation Data - Winter

    (b) Winter

    Figure 4.3: Simulation data LTC3129

    28

  • 5 Synthetic Data Set Generation

    5.1 Setup

    Figure 5.1 shows the experimental setup that was used to obtain the syntheticdata set, which will be the basis for the ANN model.

    Voltmeter Agilent 34410a

    MATLABInstrument Control

    Harvesting Controller

    Current Source HM 8143

    Amperemeter Agilent 34410a EDLC

    Figure 5.1: Setup to generate ANN training data

    Two Agilent 34410a are used to measure the input current and supercapacitorvoltage. The Hameg HM8150 Arbitrary Function Generator is connected to bothof the multimeters’ external triggers to be able to trigger the measurements with asteady frequency. When measurements are triggered, the Agilent 34410a stores thevalues into the internal memory, which needs to be read out frequently to avoidmemory overflow and data loss. The values are stored with an accuracy of ninedigits.

    29

  • 5 Synthetic Data Set Generation

    The center of the setup is a computer running MATLAB R2016a that is connectedto all devices over USB interfaces. A MATLAB script controls the whole exper-imental setup by configuring the instruments, initiating the process, reading outthe memory of multimeters and storing the data.

    Starting with a discharged capacitor, the Hameg HM8143 is used as a currentsource to feed constant currents to the SEHS and, thus, mimic the solar panel.The input current and voltage across the EDLC are monitored over the completecharging process with a constant sampling interval defined by the user. This processis repeated in 1 mA-steps for the whole range of possible input currents, which isdefined by the power rating of the solar panel. This way the whole charging processis captured in a data set consisting of multiple time-series for both input currentand output voltage.

    This setup does not include any load, apart from the self-discharge of the super-capacitor during the charging process.

    5.2 Data sets

    The above described setup was used with the SEHSs presented in Chapter 4 togenerate two synthetic data sets that will be used as training sets for the ANN-modeling of the two systems. Each data set includes 200 charging cycles, from1 mA till 200 mA with a step size of 1 mA. The condition for ending one chargingcycle has been defined as follows: a linear regression of the past 10 values of thesupercapacitor voltage is conducted after each new measurement. If the slope ofthis regression was less than 1 µV, the MATLAB script stopped the charging cycle,discharged the supercapacitor and initiated the next cycle.

    Figure 5.2 shows the two obtained data sets. The first data set (IC: BQ25504)shows a very even distribution of the individual data points between the super-capacitor’s maximum voltage of 2.7 V and the current source’s maximum currentof 200 mA. It can also be observed that the low currents of 1 mA and 2 mA arenot able to fully charge the supercapacitor before reaching the cycle terminationpoint.

    The second system’s data set (IC: LTC3129) is not as evenly distributed as thepreviously described data set. This is due to the behavior of the charging IC, whichlimits the input current. The current increases with a rising supercapacitor voltage.If that voltage exceeds approximately 2.5 V, the input current drops rapidly, untilthe capacitor is fully charged.

    30

  • Limitations 5.3

    Figure 5.3 shows the input current against the supercapacitor voltage (note: thedense part of the data has been thinned out to make the figure more lightweight). Itillustrates the idea behind using a synthetic training set: many system states thatcould occur during the operation do not appear in the real-world data set, which,thereby, might only represent a fraction of the information needed if one strives tocreate a model that is valid for a broad range of applications and environments.

    The evaluation sets can be seen in Figure 5.4 and 5.5. All diagrams show thesupercapacitor voltage as a response to the defined input current curves, definedas follows:

    1. linear increasing current (5.4a and 5.5a)2. triangular waveform overlaid with a linear increasing current (5.4b and 5.5b)3. periodically increasing and decreasing current (5.4c and 5.5c)

    These evaluation sets emulate three hypothetical charging scenarios. It becomesclear that the two SEHSs react differently to the same settings of the constantcurrent source, which is because of how the two harvesting ICs work. While itcan be observed that the general course of the supercapacitor voltage is similar,the voltage of the LTC3129 system rises faster. Moreover, the LTC3129 harvestingICs utilizes an input current control, which could cause the current to be reducedthroughout the charging and which lets the current drop to a minimum, when theEDLC is fully charged (compare training set in Figure 5.2.

    5.3 Limitations

    This setup uses a constant current source as a replacement for the solar panel.However, a current source does not mimic the solar panel’s behavior perfectly, asthis is characterized by a unique non-linear IV-curve, which is defined by the opencircuit voltage VOC , the short circuit current ISC and a maximum power pointPMAX (see Figure 2.3). Using the constant current source together with a chargingIC that includes MPPT will make the IC maintain a power point, which is likelyto deviate from the solar panel’s maximum power point.

    31

  • 5 Synthetic Data Set Generation

    0 0.5 1 1.5 2 2.5 3

    Supercapacitor voltage [V]

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t cur

    rent

    [A]

    Training set BQ25504

    (a) BQ25505

    0 0.5 1 1.5 2 2.5 3

    Supercapacitor voltage [V]

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t cur

    rent

    [A]

    Training set LTC3129

    (b) LTC3129

    Figure 5.2: Synthetic training sets

    32

  • Limitations 5.3

    0 0.5 1 1.5 2 2.5 3

    Supercapacitor voltage [V]

    0

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    0.16

    0.18

    0.2

    Inpu

    t cur

    rent

    [A]

    BQ25504 real-world data distribution

    (a) BQ25505

    0 0.5 1 1.5 2 2.5 3

    Supercapacitor voltage [V]

    0

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    0.16

    0.18

    0.2

    Inpu

    t cur

    rent

    [A]

    LTC3129 real-world data distribution

    (b) LTC3129

    Figure 5.3: Real-world data distribution

    33

  • 5 Synthetic Data Set Generation

    0 20 40 60 80 100 120 140 160 180 200

    Sampling Intervals [T] (1T = 60s)

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t Cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    BQ25504 evaluation set 1

    (a) Evaluation set 1

    0 100 200 300 400 500 600 700

    Sampling Intervals [T] (1T = 60s)

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t Cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    BQ25504 evaluation set 2

    (b) Evaluation set 2

    0 100 200 300 400 500 600

    Sampling Intervals [T] (1T = 60s)

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t Cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    BQ25504 evaluation set 3

    (c) Evaluation set 3

    Figure 5.4: BQ25504 evaluation sets

    34

  • Limitations 5.3

    0 20 40 60 80 100 120 140 160 180 200

    Sampling Intervals [T] (1T = 60s)

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t Cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    LTC3129 evaluation set 1

    (a) Evaluation set 1

    0 100 200 300 400 500 600 700

    Sampling Intervals [T] (1T = 60s)

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t Cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    LTC3129 evaluation set 2

    (b) Evaluation set 2

    0 100 200 300 400 500 600

    Sampling Intervals [T] (1T = 60s)

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    Inpu

    t Cur

    rent

    [A]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    LTC3129 evaluation set 3

    (c) Evaluation set 3

    Figure 5.5: LTC3129 evaluation sets

    35

  • 6 Artificial Neural Network Model

    6.1 Implementation

    InputInput

    1

    InputInput

    1

    b

    W

    W

    Hidden 1Hidden 1

    10

    b

    W

    OutputOutput

    1

    OutputOutput

    1

    Figure 6.1: Structure of an artificial neural network in MATLAB

    Figure 6.1 shows the structure of the ANN that models the charge process. Eventhough this figure suggests that the output is not fed back to the input, it is.The feedback has been implemented manually and is, thus, not represented in thestructure of the ANN. This was necessary, because the output discharge model hasto be taken into account.

    The ANN in the figure has a single hidden layer with ten parallel neurons and anoutput layer. The neurons in both layers are, except for their number, identical.They all include a weight for each input, a bias input and a transfer function,which is implemented as log-sigmoid transfer function.

    This specific transfer function has been chosen because of the data normalizationthat has been used. The training data, as well as evaluation data and simulationdata, is scaled between 0 and 1, where 0 is the lowest and 1 is the highest valueof the training set. This promises a faster and possibly more precise training out-come [29]. For this normalization the log-sigmoid transfer function is well-suitedas the function’s output range and the normalization’s range match. Thereby, theANN’s output is automatically limited to this range.

    37

  • 6 Artificial Neural Network Model

    Before MATLAB trains an ANN, the weights and biases are set to random valuesbased on the state of the Random Number Generator (RNG). In order to be ableto reproduce training sessions, the RNG can be seeded prior to training. Thereby,it is set to a known state, which can be restored at any time. In these experiments,the RNG is always seeded according to the same pattern: the first trial is seededwith the value 1, the second with the value 2 and so forth.

    Table 6.1 displays the full list of settings of the training process.

    Table 6.1: MATLAB training settings

    Category Name MATLAB

    Training algorithm Levenberg-Marquardt backpropagation trainlmTransfer function Log-sigmoid logsigRatio train/val/test Interleaved data division divideint

    6.2 Discharge model

    The discharge model that supplements the ANN model is implemented as a fit-ting curve with a third-degree polynomial function, also know as cubic function(see Equation 6.1). Knowing the current supercapacitor voltage, it is possible tocompute the corresponding derivative for that value in the fitted discharge curve.

    y = p1 ∗ x3 + p2 ∗ x2 + p3 ∗ x+ p4 (6.1)

    The outputs of the charge and discharge model are determined simultaneously,with one exception. If the input current is lower than the minimum input cur-rent of the training set, the charge model is not taken into account. The reasonis that at times, when the EDLC should clearly discharge, the ANN model regu-larly predicted values that outweigh the influence of the discharge model, whichresulted in a never discharging capacitor in the simulation. This behavior is shownin Figure 6.2.

    38

  • Discharge model 6.2

    0 1 2 3 4 5 6 7 8

    Sampling intervals [T] (1T = 5s) #104

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    BQ25504 simulation without low-current filter

    Real dataSimulation output

    (a) Without low-current filter

    0 1 2 3 4 5 6 7 8

    Sampling intervals [T] (1T = 5s) #104

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    BQ25504 simulation with low-current filter

    Real dataSimulation output

    (b) With low-current filter

    Figure 6.2: Comparison between models with and without low-current filter

    39

  • 6 Artificial Neural Network Model

    6.3 Results

    6.3.1 Comparing different architectures

    In the first experiment the architecture of the ANNs has been varied and itsinfluence on the simulation performance investigated. The sampling interval forall networks was T = 1 s and all charging cycles have been used in the training.For each architecture four trials with different initial weights and biases have beentrained and tested with the real-world simulation set.

    1 5 10 15 20 1:1 5:5 10:10 15:15 20:20 1:1:1 5:5:5 10:10:10 15:15:15 20:20:20

    Architecture [neurons for each layer]

    0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    RM

    SE

    [V]

    BQ25504 performance diagram for different ANN architectures (summer)

    (a) Summer

    1 5 10 15 20 1:1 5:5 10:10 15:15 20:20 1:1:1 5:5:5 10:10:10 15:15:15 20:20:20

    Architecture [neurons for each layer]

    0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    RM

    SE

    [V]

    BQ25504 performance diagram for different ANN architectures (winter)

    (b) Winter

    Figure 6.3: BQ25505 performance diagram for different ANN architectures

    Figure 6.3 and 6.4 show the mean RMSE of the four trials for each architecture withthe minimum and maximum error indicated. The notation on the x-axis illustrates

    40

  • Results 6.3

    1 5 10 15 20 1:1 5:5 10:10 15:15 20:20 1:1:1 5:5:5 10:10:10 15:15:15 20:20:20

    Architecture [neurons for each layer]

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    1.8

    RM

    SE

    [V]

    LTC3129 performance diagram for different ANN architectures (summer)

    (a) Summer

    1 5 10 15 20 1:1 5:5 10:10 15:15 20:20 1:1:1 5:5:5 10:10:10 15:15:15 20:20:20

    Architecture [neurons for each layer]

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    1.8

    RM

    SE

    [V]

    LTC3129 performance diagram for different ANN architectures (winter)

    (b) Winter

    Figure 6.4: LTC3129 performance diagram for different ANN architectures

    the ANN’s architecture; 10 stands for a single hidden layer with 10 neurons, while5:5:5 symbolizes an ANN that has 3 hidden layer with 5 neurons each.

    The two systems show very different results. With a higher ANN complexity, theBQ25504 simulations improve and seem to reach saturation, whereas the mean per-formance of the LTC3129 models tendentially decreases, when using more layersand neurons. Also, the range of possible performances increases with the complex-ity. A low range is an important aspect for ANNmodeling, because big performancevariations between trials with the same settings produce an uncertainty whetheror not these settings are appropriate.

    41

  • 6 Artificial Neural Network Model

    6.3.2 Varying the sampling interval

    When varying the sampling interval, the ANNs for both systems had three hiddenlayers with ten neurons each and were trained with 50 % of the charging cycles inthe training set. Four models haven been created with different initial weights andbiases. The models were tested with the real-world simulation set.

    1 2 5 10 20 30 60

    Sampling interval T [s]

    0

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    0.16

    0.18

    0.2

    RM

    SE

    [V]

    BQ25504 performance diagram for different sampling intervals (summer)

    (a) Summer

    1 2 5 10 20 30 60

    Sampling interval T [s]

    0

    0.02

    0.04

    0.06

    0.08

    0.1

    0.12

    0.14

    0.16

    0.18

    0.2

    RM

    SE

    [V]

    BQ25504 performance diagram for different sampling intervals (winter)

    (b) Winter

    Figure 6.5: BQ25504 performance diagram for different sampling intervals

    The results in Figure 6.5 show that changing the sampling interval makes littledifference when modeling the BQ25504 system. The mean RMSE rises slightlywith a nearly constant range of values. The LTC3129 system on the other handseems to react better to a higher sampling interval. The performance for intervalsof 20 s, 30 s and 60 s is nearly the same and different trials have little variation. As

    42

  • Results 6.3

    1 2 5 10 20 30 60

    Sampling interval T [s]

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    1.8

    2

    RM

    SE

    [V]

    LTC3129 performance diagram for different sampling intervals (summer)

    (a) Summer

    1 2 5 10 20 30 60

    Sampling interval T [s]

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    1.8

    2

    RM

    SE

    [V]

    LTC3129 performance diagram for different sampling intervals (winter)

    (b) Winter

    Figure 6.6: LTC3129 performance diagram for different sampling intervals

    mentioned before, a low sampling interval reduces both training and simulationtime.

    6.3.3 Varying the input currents in the training set

    For the next experiment the number of charging cycles that was presented to thelearning algorithm was changed. For that, the ANN that modeled the BQ25504system had three hidden layers with ten neurons each and a sampling interval ofT = 2 s. A simple architecture of two neurons in a single hidden layer along witha sampling interval of T = 20 s was chosen for the LTC3129 model. These settings

    43

  • 6 Artificial Neural Network Model

    provided promising results in the previous experiments (see Figure 6.3, 6.4, 6.5,and 6.6.

    The first charging cycle, which was created with an input current of 1 mA, wasalways used in the training set. From there on, every 2nd, 3rd, 5th, 7th, 10th, 15th,20th, 25th or every charging cycle was presented to the learning algorithm. Thesestep sizes translate to the percentages of the total number of charging cycles onthe x-axis.Again, the real-world simulation set was used to test the models.

    100% 50% 33.3% 20% 14.3% 10% 6.67% 5% 4%

    Number of charging cycles used for training

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    RM

    SE

    [V]

    BQ25504 performance diagram for various numbers of input currents (summer)

    (a) Summer

    100% 50% 33.3% 20% 14.3% 10% 6.67% 5% 4%

    Number of charging cycles used for training

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    RM

    SE

    [V]

    BQ25504 performance diagram for various numbers of input currents (winter)

    (b) Winter

    Figure 6.7: BQ25504 performance diagram for different numbers of charging cyclesin the training set

    Both systems show the same behavior in the simulation (see Figures 6.7 and 6.8).As long as the amount of charging cycles in the training set is higher than a certain

    44

  • Results 6.3

    100% 50% 33.3% 20% 14.3% 10% 6.67% 5% 4%

    Number of charging cycles used for training

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    RM

    SE

    [V]

    LTC3129 performance diagram for various numbers of input currents (summer)

    (a) Summer

    100% 50% 33.3% 20% 14.3% 10% 6.67% 5% 4%

    Number of charging cycles used for training

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    1.4

    1.6

    RM

    SE

    [V]

    LTC3129 performance diagram for various numbers of input currents (winter)

    (b) Winter

    Figure 6.8: LTC3129 performance diagram for different numbers of charging cyclesin the training set

    level (BQ25504: 6.67 percent, LTC3129: 10 percent), the performance is low withlittle divergence. Reducing the number of charging cycles can reduce training time,but has no influence on the simulation time.

    6.3.4 Correlation between evaluation and simulation error

    In order to determine, whether or not the evaluation sets can be used to predictthe performance of the trained ANN on the simulation set, the RMSE in thesummer simulation has been plotted against the RMSE in the three evaluations.

    45

  • 6 Artificial Neural Network Model

    A correlation would be helpful in finding an accurate model without the need toapply the model on real-world data.

    RMSE of Evaluation

    RM

    SE

    of S

    imul

    atio

    n

    Correlation between evaluation & simulation performance

    0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.450

    0.1

    0.2

    0.3

    0.4

    0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.450

    0.1

    0.2

    0.3

    0.4

    0 0.05 0.1 0.15 0.2 0.25 0.30

    0.1

    0.2

    0.3

    0.4

    (a) BQ25504

    RMSE of Evaluation

    RM

    SE

    of S

    imul

    atio

    n

    Correlation between evaluation & simulation performance

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.60

    0.5

    1

    1.5

    2

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.60

    0.5

    1

    1.5

    2

    0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.60

    0.5

    1

    1.5

    2

    (b) LTC3129

    Figure 6.9: Relationship between evaluation and simulation performance

    Figure 6.9 shows the results, which indicate that no correlation between theseevaluation runs and the simulation could be found. This result, however, is oflimited value, as the evaluation sets (see Figure 5.4 and 5.4) are not very extensive.So evaluation set 3 does not include a complete charge cycle of the EDLC and,thus, does not include all relevant system states.

    46

  • Results 6.3

    6.3.5 Normalized vs. unnormalized data

    Figure 6.10 and 6.11 show the impact of data normalization on the duration oftraining and simulation and the change in simulation performance in the exampleof the BQ25504 system. All models have been trained with a sampling interval ofT = 1 s and 50 % of the training set.

    It can be observed that normalization can reduce training time in many configura-tions and trials, especially in regard to the configurations that are to be expectedto predict the output of the BQ25504 system with a higher accuracy, i.e. complexANNs that demand a higher training duration. The simulations with normalizeddata also takes less time than the simulations with unnormalized data, but thiseffect is not as significant as the reduction in training duration. Comparing theimpact of normalization on the simulation accuracy, reveals no major differencesfor the complex, well-performing models. However, it can be observed that normal-ization could have a negative impact on this system, specifically on the simulationaccuracy of ANNs with one hidden layer.

    1 5 10 1:1 5:5 10:10 1:1:1 5:5:5 10:10:10

    Structure of the artificial neural network (neurons per layer)

    0

    200

    400

    600

    800

    1000

    1200

    Tim

    e [s

    ]

    Normalized vs. unnormalized data: Training duration

    UnnormalizedNormalized

    (a) Training duration

    1 5 10 1:1 5:5 10:10 1:1:1 5:5:5 10:10:10

    Structure of the artificial neural network (neurons per layer)

    0

    100

    200

    300

    400

    500

    600

    700

    800

    Tim

    e [s

    ]

    Normalized vs. unnormalized data: Simulation duration

    UnnormalizedNormalized

    (b) Simulation duration

    Figure 6.10: BQ25505 modeling duration

    1 5 10 1:1 5:5 10:10 1:1:1 5:5:5 10:10:10

    Structure of the artificial neural network (neurons per layer)

    0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    RM

    SE

    [V]

    Normalized vs. unnormalized data: Accuracy

    UnnormalizedNormalized

    Figure 6.11: BQ25505 modeling performance

    47

  • 6 Artificial Neural Network Model

    6.3.6 Best models

    Figure 6.12 and Figure 6.13 present the two ANNs that perform best in terms ofpredicting the simulation set. These ANNs have been trained with the configura-tions in Table 6.2.

    Table 6.2: Configurations of best performing ANN models

    Configuration BQ25504 LTC3129

    Architecture 10:10:10 2Sampling interval 1 s 20 sAmount of input currents 50 % 50 %

    The BQ25504 model has an RMSE of 0.0894 V and 0.0493 V for summer andwinter, respectively. The RMSEs of the LTC3129 simulation are 0.0791 V and0.1012 V. Both BQ25504 simulations show an offset between the simulation dataand the simulation output. The reason for this is hardware tolerances between theboard that has been used for the acquisition of the synthetic training set and theone that has been used in the real-world deployment. An offset is also produced bythe LTC3129 model. This, however, can not be explained by hardware tolerancealone, as the raw simulation data reveal the maximum possible ANN output hasnot been reached. Therefore, the reason is likely to be within the ANN and yet tobe discovered.

    An effect that is explained by the behavior of the physical SEHS is the prematurecharge in the LTC3129 simulation, which is caused by the effect that the superca-pacitor voltage drops when the input current rises after a discharge period. Thisbehavior is not captured by the training set and can therefore not appear in thesimulation.

    Also, the plots show that all simulations start discharging too early. This is abyproduct of the low-current filter that has been applied in the simulations tomake the discharge process visible (see Section 6.2). The effects of this low-currentfilter on the simulation result can be seen in more detail in Figure 6.14. As soon asthe solar current is beneath the threshold of 1 mA, the model ignores the currentand initiates the discharge process. This leads to the premature decrease of thesupercapacitor voltage in the model.

    48

  • Results 6.3

    0 0.5 1 1.5 2 2.5 3 3.5

    Sampling intervals [T] (1T = 1s) #105

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    Simulation with best performing BQ25504 model (summer)

    Real dataSimulation output

    (a) Summer

    0 0.5 1 1.5 2 2.5 3 3.5

    Sampling intervals [T] (1T = 1s) #105

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    Simulation with best performing BQ25504 model (winter)

    Real dataSimulation output

    (b) Winter

    Figure 6.12: Simulation with the best performing BQ25504 model

    49

  • 6 Artificial Neural Network Model

    0 2000 4000 6000 8000 10000 12000 14000 16000 18000

    Sampling intervals [T] (1T = 5s)

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    Simulation with best performing LTC3129 model (summer)

    Real dataSimulation output

    (a) Summer

    0 2000 4000 6000 8000 10000 12000 14000 16000 18000

    Sampling intervals [T] (1T = 5s)

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    Simulation with best performing LTC3129 model (winter)

    Real dataSimulation output

    (b) Winter

    Figure 6.13: Simulation with the best performing LTC3129 model

    50

  • Results 6.3

    1.1 1.15 1.2 1.25 1.3 1.35

    Sampling intervals [T] (1T = 1s) #105

    2.4

    2.45

    2.5

    2.55

    2.6

    2.65

    2.7

    2.75

    2.8

    Sup

    erca

    paci

    tor

    volta

    ge [V

    ]

    0

    0.5

    1

    1.5

    2

    2.5

    3

    3.5

    4

    Sol

    ar C

    urre

    nt [A

    ]

    #10-3Zoom on discharge behaviour of best performing BQ25504 model (summer)

    Real dataSimulation outputSolar currentLow-current filter

    Figure 6.14: Zoom in on the discharge behavior to show the influence of the low-current filter

    51

  • 7 Reference Models

    7.1 Equivalent circuit

    7.1.1 Implementation

    Figure 7.1 shows the implementation of the equivalent circuit as a mathematicalmodel in MATLAB Simulink. The model has two inputs, namely the solar currentand solar voltage. Based on these values, the EDLC voltage is computed and savedinto the workspace variable edlc_voltage_prediction. The supercapacitor voltagefrom the simulation set appears in the model for a visual comparison between thereal-world data and the simulation.

    Scope1Solar Current 3

    EDLC Voltage Real2Solar Voltage

    VL IL

    Load

    Memory

    Isolar

    Vsolar

    Vsc

    Icharge

    Simplified Harvesting IC

    Isc Vsc

    Supercapacitor

    edlc_voltage_prediction

    To Workspace

    Vin

    Iout

    Vout

    Iin

    Boost Converter

    Figure 7.1: Equivalent circuit model

    The submodel of the harvesting IC, which is shown in Figure 7.2, has been im-plemented by its energy conversion efficiency. Thus, the charge current (=outputcurrent) is calculated by Equation 7.1 and thereby depends on the system’s inputvoltage and input current, as well as on the supercapacitor voltage, which is theoutput voltage of the harvesting IC. Additionally, the IC’s efficiency, provided bythe component’s data sheet, is taken into account. The submodel’s output is setto zero as soon as Vmax, which is the maximum capacitor voltage, is reached. Vmax

    53

  • 7 Reference Models

    1Isolar

    1Icharge

    2Vsolar

    3Vsc

    n

    Efficiency

  • Equivalent circuit 7.1

    V_ESR

    V_C0I_C0

    ESR

    Serial Resistance

    Memory

    1Vsc

    1/C

    Rated Capacity

    1Isc

    K Tsz-1

    Discrete-TimeIntegrator

    V0

    Initial Voltage

    Ileak/V0

    1/Rleak

    Figure 7.3: Equivalent circuit: Supercapacitor

    The submodel of the boost-converter (Figure 7.4) takes the supercapacitor’s volt-age and the current of the load as input in order to calculate its input current,while maintaining a constant output voltage. This is due to the nature of a boost-converter that demands a higher input current, when the input voltage drops andthe output voltage and current are constant.

    Iout = ηn ∗Vout ∗ ILVin

    (7.5)

    >= Vmin

    Minimum Voltage

    Vout

    Constant11

    Vout

    1Vin

    2Iin2

    Iout

    n1

    Efficiency1

    Divide1

    n2

    Efficiency2

  • 7 Reference Models

    1IL

    1VL

    1/R

    Gain

    Figure 7.5: Equivalent circuit: Load

    The load (see Figure 7.5) is implemented as a plain gain that converts the voltageacross the load into the load current.

    7.1.2 Results

    The simulation in Simulink has been executed with a fixed step-size of 1 s. There-fore, prior to the simulation, the real-world data have been interpolated accordinglyto match this interval. Only the first supercapacitor value has been presented tothe model as default SoC. All other values have only been used to determine theperformance of the model and to have a visual comparison.

    Figure 7.6 shows the simulation results for the BQ25504-system. While the perfor-mance on the winter data is noticeably better, the RMSEs does not support thisobservation to the full extent (RMSE summer: 0.0642 V, RMSE winter: 0.0617 V).This, however, is due to the fact that the fully-charged state of the EDLC in sum-mer is more than five times as long as in winter. The fully-charged EDLC is a statethat can be predicted with high accuracy.

    It can also be noted that the simulation’s discharge in summer starts earlier thanthe real discharge does. This behavior is absent in the winter simulation. Also, thecharging process seems to start too late in summer.

    The LTC3129 simulation (Figure 7.7) produces an RMSE of 0.0414 V in summerand 0.0551 V in winter. Here, the discharge in the simulation begins too early,both in summer and in winter. It is no surprise that there is a big gap between thereal and simulated charging process. This is due to the behavior of this harvestingboard that causes the EDLC voltage to drop when the input current rises in themorning.

    The results of both simulations seem to suggest that these effects go hand-in-hand:if a model starts discharging too late, it will start charging too early. Conversely,a model that discharges too early will begin to charge too late.

    56

  • Equivalent circuit 7.1

    0 0.5 1 1.5 2 2.5 3 3.5

    Sampling intervals [T] (1T = 1s) #105

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Out

    put v

    olta

    ge [V

    ]

    Equivalent circuit simulation BQ25504 - summer

    Real dataSimulation output

    (a) Summer

    0 0.5 1 1.5 2 2.5 3 3.5

    Sampling intervals [T] (1T = 1s) #105

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Out

    put v

    olta

    ge [V

    ]

    Equivalent circuit simulation BQ25504 - winter

    Real dataSimulation output

    (b) Winter

    Figure 7.6: Equivalent circuit simulation BQ25504

    57

  • 7 Reference Models

    0 0.5 1 1.5 2 2.5 3 3.5

    Sampling intervals [T] (1T = 1s) #105

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Out

    put v

    olta

    ge [V

    ]

    Equivalent circuit simulation LTC3129 - summer

    Real dataSimulation output

    (a) Summer

    0 0.5 1 1.5 2 2.5 3 3.5

    Sampling intervals [T] (1T = 1s) #105

    1

    1.2

    1.4

    1.6

    1.8

    2

    2.2

    2.4

    2.6

    2.8

    3

    Out

    put v

    olta

    ge [V

    ]

    Equivalent circuit simulation LTC3129 - winter

    Real dataSimulation output

    (b) Winter

    Figure 7.7: Equivalent circuit simulation LTC3129

    58

  • Lookup table 7.2

    7.2 Lookup table

    7.2.1 Implementation

    The lookup table model is another data-driven modeling technique and relies onthe same training set as the ANN-model.

    The charge model is implemented as a two-dimensional lookup table. The numberof dimensions refers to the number of inputs that are used to determine the out-put. The model uses the solar current and the current EDLC voltage as input tocalculate how much the voltage will rise during the next sampling interval. Thisvoltage difference is added up with the current voltage and the impact of the sys-tem’s discharge (see next section) to calculate the next EDLC voltage, which, inturn, is fed back as the new input.

    1Solar Current Real

    EDLC Voltage 2

    EDLC Voltage Real

    Feedback

    1-D T(u)

    LUT discharge

    2-D T(u)u1

    u2

    LUT charge

    edlc_voltage

    To Workspace

    EDLC Voltage

    Figure 7.8: Lookup table model

    Table 7.1 shows an excerpt from the BQ25504 lookup table. Before creating thedata for the lookup table, the table’s breakpoints must be defined. The inputcurrent from 0 mA to 200 mA in 1 mA-steps and the full range of the supercapacitorvoltage in 200 steps define the breakpoints for both systems. For all combinationsof these points, the corresponding values for the EDLC voltage difference to thenext sample is determined by interpolating the training set.

    In the process of creating the lookup table, it was ensured that all values forthe highest voltage (here: 2.645 V) are either 0 or negative. This way, the chargeprocess is stopped, if the maximum capacitor voltage is reached. The first value

    59

  • 7 Reference Models

    of the simulation set is used as the initial SoC of the supercapacitor, which is setin the Simulink feedback block. The simulation output is stored in a workspacevariable to be able to compare it against the real-world data and determine themodel’s performance.

    Table 7.1: Excerpt from the BQ25504 lookup tableHHHH

    HHmAV 0 0.0134 0.0268 0.0403 ... 2.645 2.658 2.645

    0 0 0 0