# A Switching Observer for State-of-Charge Estimation of Reconfigurable Supercapacitors
## 3 Observer Design for Switching Systems
### System Properties  
Before delving into observer design, it is essential to understand the fundamental properties of our switching system, which are crucial for observer construction. These properties encompass continuity, state differentiability, and the controllability and observability of each subsystem. **Lemma 1**. : _Consider the switched system described by the state-space Equation (8), where the input current \(i\) is piecewise continuous. Then, the system's state (SOC) is continuous due to its differentiability._ \begin{table}
\begin{tabular}{l c c c} \hline  & **Initial SOC (\%)** & **Final SOC (\%)** & **Charging Stop Time (s)** \\ \hline
**True Value** & 30.12 & 100.03 & 293.164 \\ \hline
**Open-loop Observer** & 30.12 & 93.62 & 293.164 \\ \hline \end{tabular}
\end{table} 
Table 1: Open-loop estimation performance under capacitance changes. Figure 4: Comparison of SOC estimation performance during dynamic charging with capacitance variations. (**a**) SOC estimation with 10% capacitance variations. (**b**) SOC estimation with 10% capacitance variations. Proof. : To prove the continuity of the state, we need to demonstrate its differentiability. This involves establishing the existence and uniqueness of solutions for the state-space Equation (8) and showing that the equation itself is continuous. From Equation (8), we can derive the following differential equation:  
\[\text{SOC}= f(t,\text{SOC},\lambda) \tag{14}\]  
Here, \(\lambda\) represents the system parameters, including \(r\), \(C\), \(R\), and \(s\), while \(i(t)\) is a piecewise continuous function of time. Let us define \(T=\{t_{l}\}_{l=1}^{\infty}\) as the sequence of switching instants. We assume that \(i(t)\) remains continuous within each time interval \((t_{l},t_{l+1})\) and that the system is Zeno-free, meaning that it does not exhibit infinitely fast switching. Consequently, within each interval \((t_{l},t_{l+1})\), the impact of switching remains bounded. Now, we invoke a mathematical principle: if a function remains bounded within a finite time interval, both its left-hand and right-hand limits must exist at every point within that interval. Proof of the Principle. : The principle clearly holds for points where the function is continuous. Let us focus on discontinuities. Consider approaching a point \(t\) from the left, denoted as \(t\to t_{l-}\). Due to the function's boundedness in the interval \([t_{0},t_{l}]\), any sequence \(t_{n}\) approaching \(t_{l}\) from the left (\(t_{n}<t_{l}\) and \(t_{n}\to t_{l}\)) will result in a bounded sequence \(g(t_{n})\). This implies the existence of a finite limit \(L_{l}\) such that \(\lim_{t\to t_{l-}}g(t)=L_{l}\). Similarly, approaching \(t\) from the right (\(t\to t_{l+}\)) leads to the existence of a finite right-hand limit \(L_{r}\) such that \(\lim_{t\to t_{l+}}g(t)=L_{r}\). Therefore, at any jump point \(t=t_{l}\), both the left-hand and right-hand limits of \(g(t)\) exist. This allows for discontinuities of the first kind, where the function takes a finite jump. Consequently, we can conclude that \(f(t,SOC,\lambda)\) is piecewise continuous in \(t\), as discontinuities of the first kind do not disrupt the function's continuity at other points. Next, let us examine the Lipschitz constant of \(f\) with respect to SOC:  
\[\frac{\big{|}f(t,\text{SOC}_{x},\lambda)-f(t,\text{SOC}_{y},\lambda)\big{|} }{\big{|}\text{SOC}_{x}-\text{SOC}_{y}\big{|}}\leq L \tag{15}\]  
Since \(f\) is independent of SOC, the left-hand side of the inequality is always zero. Therefore, the inequality holds true for any value of \(L\), including \(L=0\), regardless of whether \(s=0\) or \(s=1\). Lemma 2.: _The switching system represented by Equation (8) maintains observability regardless of the switch state._  
Proof.