# A Stackelberg Game Approach for Price Response Coordination of Thermostatically Controlled Loads
## 2 Problem Formulation
### Energy Demand of TCLs  
At the start time \(t_{k}\) of any time horizon, each TCL user chooses a set-point temperature \(\widehat{\theta_{i}}\) according to the broadcast price \(p\). Then, each TCL needs to consume some energy to make its current internal temperature \(\theta_{i}(t_{k})\) reach the set-point temperature \(\widehat{\theta_{i}}\). Denote this energy demand by \(u_{i}\equiv f_{i}(\widehat{\theta_{i}})\) which is a function of \(\widehat{\theta_{i}}\). In this section, we derive the relationship between \(\widehat{\theta_{i}}\) and \(u_{i}\) based on the dynamics of TCLs.  
**Remark 2**.: _In this paper, we consider a 15-minute time horizon (\(T=15\) min), which is small enough to neglect the variation of \(\theta_{a,i}(t)\) within \(\mathcal{T}\). That is, \(\theta_{a,i}(t)\equiv\theta_{a,i}(t_{k})\), for all \(t\in\mathcal{T}\)[29]._  
As the cooling thermal power \(P_{i}\) is a preknown parameter of TCL \(i\), the energy demand to reach \(\widehat{\theta}_{i}\) from the current \(\theta_{i}(t_{k})\) within \(\mathcal{T}\) can be expressed as the following form:  
\[u_{i}=T_{on,i}P_{i},\quad T_{on,i}\in[0,T]. \tag{4}\]  
Recall that \(T_{on,i}\) is the time length that the \"on\" state of TCL \(i\) lasts during one time horizon \([t_{k},t_{k+1}]\), as shown in Figure 2.  
Since the maximum value of \(T_{on,i}\) is \(T\), the maximum energy demand is \(\beta_{i}^{+}\equiv TP_{i}\). Then,  
\[0\leq u_{i}\leq\beta_{i}^{+}. \tag{5}\]  
The feasible set of \(u_{i}\) is denoted by \(\mathcal{U}_{i}\) such that,  
\[\mathcal{U}_{i}\triangleq\left[0,\beta_{i}^{+}\right],\quad\forall i\in \mathcal{N}. \tag{6}\]  
By (3), \(W_{i}(t)\) remains unchanged over \(\mathcal{T}\) if the internal temperature \(\theta_{i}(t),t\in\mathcal{T}\) always lies in the dead-band. And \(W_{i}(t)\) changes only if \(\theta_{i}(t)\) hits the limits of the dead-band \(\theta_{i}^{-}\) or \(\theta_{i}^{+}\) for some \(t\in\mathcal{T}\). Then by (1), after the first change of \(W_{i}(t)\), \(\theta_{i}(t)\) will need some certain time to reach the limit \(\theta_{i}^{-}\) or \(\theta_{i}^{+}\). Therefore, if given appropriate parameters in (1), \(\theta_{i}(t)\) will not hit the boundary of dead-band twice within \(\mathcal{T}\). Then, we have the following assumption in this paper.  
**Assumption 1**.: _The switch state \(W_{i}(t)\) of each TCL \(i\) changes no more than once over \(\mathcal{T}\)._  
Based upon Assumption 1, the operation process of TCL \(i\) in \(\mathcal{T}\) can be divided into two cases w.r.t. \(W_{i}(t_{k})\).  
* Case 1 (\(W_{i}(t_{k})=1\)): By (1), we have the internal temperature at time \(t_{k}+T_{on,i}\), such that, \[\theta_{i}(t_{k}+T_{on,i})=(\theta_{a,i}(t_{k})-P_{i}R_{i})(1-e^{-T_{on,i}/\tau _{i}})+\theta_{i}(t_{k})e^{-T_{on,i}/\tau_{i}}.\] (7) Combining (2a) and (3), it gives \[\theta_{i}(t_{k}+T_{on,i})=\widehat{\theta}_{i}-\delta/2.\] (8) Then by (4), (7) and (8), the relationship between \(u_{i}\) and \(\widehat{\theta}_{i}\) is \[u_{i}=\tau_{i}P_{i}\ln\frac{\theta_{i}(t_{k})+P_{i}R_{i}-\theta_{a,i}(t_{k})} {\widehat{\theta}_{i}+P_{i}R_{i}-\theta_{a,i}(t_{k})-\delta/2}.\] (9)
* Case 2 (\(W_{i}(t_{k})=0\)): Similar with Case 1, by (1)-(4), we have: \[u_{i}=TP_{i}-\tau_{i}P_{i}\ln\frac{\theta_{a,i}(t_{k})-\theta_{i}(t_{k})}{ \theta_{a,i}(t_{k})-\widehat{\theta}_{i}-\delta/2}.\] (10)In summary, we obtain the relationship between the energy demand \(u_{i}\) and the set-point temperature \(\widehat{\theta}_{i}\) such that  
\[u_{i}=f_{i}(\widehat{\theta}_{i})=\begin{cases}\tau_{i}P_{i}\ln\frac{\theta_{i} (t_{k})+P_{i}R_{i}-\theta_{ij}(t_{k})}{\theta_{i}+P_{i}R_{i}-\theta_{adj}(t_{k })-\delta/2},&\text{in case }W_{i}(t_{k})=1\\ TP_{i}-\tau_{i}P_{i}\ln\frac{\theta_{adj}(t_{k})-\theta_{ij}(t_{k})}{\theta_{ adj}(t_{k})-\theta_{i}-\delta/2},&\text{in case }W_{i}(t_{k})=0\end{cases} \tag{11}\]