# Improved Temporal Fuzzy Reasoning Spiking Neural P Systems for Power System Fault Diagnosis
## 2 ITFRSNP System
### Model Parameters of the General Fault Diagnosis Model  
The parameters of the general fault diagnosis model according to the propositions and reasoning rules of the neurons are as follows.  
1. The input matrices \(\mathbf{U}_{1}\) and \(\mathbf{U}_{2}\), and the output matrix \(\mathbf{V}\) of the general fault diagnosis model are as follows: \[\mathbf{U}_{1}=\begin{bmatrix}\mathbf{I}_{6\times 6}&\mathbf{O}_{6\times 1}\\ \mathbf{O}_{4\times 6}&\mathbf{O}_{4\times 1}\end{bmatrix}\] (22) \[\mathbf{U}_{2}=\begin{bmatrix}\mathbf{O}_{6\times 6}&\mathbf{O}_{6\times 1}\\ \mathbf{O}_{3\times 6}&\mathbf{E}_{3\times 1}\\ \mathbf{O}_{1\times 6}&\mathbf{O}_{1\times 1}\end{bmatrix}\] (23) \[\mathbf{V}=\begin{bmatrix}\mathbf{O}_{7\times 3}&\mathbf{I}_{7\times 7}\end{bmatrix}\] (24) where \(\mathbf{I}\) is the unit matrix, \(\mathbf{O}\) is the zero matrix, and \(\mathbf{E}\) is the matrix with all the elements equal to 1.
2. Considering the uncertainty of the alarm messages, the spike values of PRs and CBs with alarm messages are listed in Table 1, and the spike values of PRs and CBs without alarm messages are 0.2 [21]. The spike values of the proposition and rule neurons in the other layers are 0.
3. If the PR/CB operation time is \(t_{0}\), the time-point constraint of the related proposition neuron is \([t_{0},t_{0}]\). For PR/CB without an alarm message, the time-point constraint of the related proposition neuron is \(\varnothing\).
4. The time-distance constraints for the bus PR, main PR, near backup PR, and remote backup PR are \([10,40]\) ms, \([10,40]\) ms, \([310,340]\) ms, and \([510,540]\) ms relative to the fault time, respectively. The time-distance constraint for the CB is \([20,40]\) ms relative to the protection operation time. Therefore, the vector \(\mathbf{D}_{r}\) of the general fault diagnosis model is as follows: \[\mathbf{D}_{r}=[[20,40],[20,40],[20,40],[10,40],[310,340],[510,540],\varnothing]^{ \mathrm{T}}\] (25)
5. The spike numbers of the proposition neurons in the PR and CB layers are set to 1, and the spike numbers of the other neurons are set to zero to ensure that spikes from proposition neurons can be delivered to rule neurons. Therefore, the vectors \(\mathbf{\theta}_{p}\) and \(\mathbf{\theta}_{r}\) of the general fault diagnosis model are as follows: \[\left\{\begin{array}{l}\mathbf{\theta}_{p}=[1,1,1,1,1,0,0,0,0]^{T}\\ \mathbf{\theta}_{r}=[0,0,0,0,0,0]^{T}\end{array}\right.\] (26)
6. Because the PR layer neurons need to obtain spikes from the CB layer neurons to fire, the spike number thresholds of all proposition neurons in the PR layer are set to two, and the spike number thresholds of other proposition neurons are set to one. Rule neurons must obtain spikes from all input proposition neurons to fire; therefore, their spike number thresholds are equal to the number of their input proposition neurons. Therefore, the vectors \(\mathbf{\lambda}_{p}\) and \(\mathbf{\lambda}_{r}\) of the general fault diagnosis model are as follows: \[\left\{\begin{array}{l}\mathbf{\lambda}_{p}=[1,1,1,2,2,2,1,1,1,1]^{\mathrm{T}} \\ \mathbf{\lambda}_{r}=[1,1,1,1,1,1,3]^{\mathrm{T}}\end{array}\right.\] (27)