# Fault Diagnosis in Partially Observable Petri Nets with Quantum Bayesian Learning
## 2 The Problem of Quantum Bayesian Fault Diagnosis for Partially Observable Petri Nets
### Problem of Fault Diagnosis  
In this paper, the main function of the fault diagnosis algorithm based on quantum Bayes and Petri nets is to judge whether the transitions of the unobservable part of Petri nets produces faults. The conditions of the fault diagnosis algorithm present the following assumptions:  
The network \(\text{POPN}\ \ =\ \ (S,T_{o},T_{u},\text{Pre},\text{Post},M_{0})\) and the identification of the initial marketing \(M_{0}\) create the system. The labels associated with the transition \(t_{i}\in T_{o}\) are observable. There is no cyclic firing on the unobservable part of POPN, and it is acyclic. Assumptions 1 and 2 show the knowledge level of the system. Assumption 3 is the common assumption in the field of fault detection based on PN model: That forbid the unobservable cycle. In the POPN, given a transition \(t_{i}\) and its corresponding probability \(Pr_{i}\) of firing conditions, the transition probability pair is \((t_{i},Pr_{i})\). Its corresponding quantum probability amplitude is determined by Equation (1):  
\[Pr_{i}=\left|e^{i\theta_{i}}q_{i}\right|^{2}\rightarrow\varphi_{i}=e^{i\theta _{i}}\sqrt{Pr_{i}} \tag{1}\]  
The introduction of an interference term resulted in a probability estimation value greater than 1, so this value need to be standardized by adding a normalization factor. The quantum probability table of all transitions in the POPN is \(\psi=\{(t_{i},\varphi_{i})|t_{i}\in T\}\). Given a OLPS \(\sigma_{o}\in\left(L\times\text{K}\right)^{*}\), its corresponding probability transition sequence set is:  
\[Q(\sigma_{o})= \begin{cases}\sigma\in\left(T\times\text{K}\right)^{*}|M_{0}[ \sigma\rangle M,L(\sigma)=\sigma_{o},\\ t\in T:M[t\,,Pr_{t}(M_{o},\sigma)>0)\end{cases} \]\(\varphi_{t}(M_{0},\sigma)\) is the quantum firing probability of the probability transition sequence \(\sigma\) as the initial marking \(M_{0}\) at the point of unobservable transition \(t\). Marking \(M\) can make it enabled under the condition that the transition is observable and the firing probability is \(Pr_{eh}\). **Definition 6**. : _Given an OLPS \(\sigma_{o}\in(L\times\mathrm{K})^{*}\), its corresponding marking set is_  
\[C(\sigma_{o})=\{\,M\in N^{m}|M_{0}[\sigma\,\rangle\,M,\sigma\in Q(\sigma_{o})\}\]  
**Definition 7**. : _Given an OLPS \(\sigma_{o}\in(L\times\mathrm{K})^{*}\), its corresponding state set is_  
\[S(\sigma_{o})=\{M_{h+1},\phi|M_{h+1}\in C(\sigma_{o})\}\]  
In the formula, \(\phi=\{0\leq Pr_{i}\leq 1\}:t_{i}\in A(M_{i})\). **Theorem 1**. : _Given a OLPS \(\sigma_{o}\in(L\times\mathrm{K})^{*}\), probability tables \(\phi\) of transitions, fault class and system fault threshold \(\rho\). A fault function is defined: \(T_{f}^{i}=\left\{t_{f}^{1},t_{f}^{2},\cdots,t_{f}^{k}\right\}\)_  
\[W:L\times\mathrm{K}\times\{T_{f}^{1},T_{f}^{2},\cdots,T_{f}^{i}\}\to\{N,F\}\]  
\(T_{f}^{i}\subseteq T_{u}\) is the fault class and belongs to the unobservable transition set. The fault classes may be actuator fault, improper system structure maintenance, environmental interference, etc. \(t_{f}^{k}\) corresponds to specific transitions caused by the fault. 1. When fault transition \(t_{f}^{k}\) does not exist in all TPS, the system state is faultless. 2. When the fault transition \(t_{f}^{k}\) may exist in TPS, the system is in uncertain diagnosis and the fault incidence needs to be further determined. The fault probability of the system is \[Pr(\sigma_{o},\psi,T_{f}^{i})=\max_{i}Pr(t_{f}^{i}|t_{1},t_{2},\cdots,t_{n})\] if \(Pr(\sigma_{o},\psi,T_{f}^{i})>\rho\) the system state is fault, else the system state is faultless. 3. When the fault transition \(t_{f}^{k}\) exists in all TPS, the system state is fault. **Proof of Theorem 1:**  
1. If \(\exists\sigma\in Q(\sigma_{o})\), \(\exists t_{f}^{i}\in T_{f}^{i}\) satisfying \(t_{f}^{i}\
otin\sigma\) So the fault \(t_{f}^{k}\) cannot be fired, and any TPS \(\sigma\) does not contain fault transitions. \[Pr(\sigma_{o},\psi,T_{f}^{i})=0,\;W\Big{(}\sigma_{o},\phi,T_{f}^{i},\rho\Big{)}=N\]
2.