# Research on Plant Disease and Pest Diagnosis Model Based on Generalized Stochastic Petri Net
## 3 Generalized Random Petri Net Model for Plant Pest and Disease Spread Diagnosis
### Generalized Stochastic Petri Net  
Petri nets are a mathematical modeling tool initially proposed by [PERSON] in the 1960s to describe and analyze the behavior of information transmission systems and other dynamic systems. The basic Petri net consists of places, transitions, and directed arcs. Places represent the states of the system, transitions represent the transitions between states, and directed arcs specify the relationships between places and transitions. In a Petri net, the state is changed by placing or removing tokens in the places, which allows the simulation of various dynamic behaviors of the system. The GSPN is an extension of the standard Petri net that introduces the concepts of time and randomness, enabling the model to more accurately reflect the uncertainty and time-dependence found in real-world systems [21]. In the process of plant pest and disease spread, time is a key parameter for disease development and control effectiveness. Therefore, this study introduces the generalized stochastic Petri net into the plant pest and disease spread diagnosis model. 1. In GSPN, the system is described as a directed graph consisting of six basic elements, denoted as \(\mathrm{PN}=(\mathrm{P},\mathrm{T},\mathrm{F},\mathrm{W},\mathrm{M},\mathrm{ \Lambda})\)[22]. These elements are specifically defined as follows:
2. \(\mathrm{P}=\{\mathrm{P}_{1},\mathrm{P}_{2},\dots,\mathrm{P}_{n}\}\) is the set of places, representing the various states or conditions in the system. In the plant pest and disease spread diagnosis model, places represent the key states and factors designed in the spread process, such as moisture factor \(\mathrm{E}_{\mathrm{a}}\), fertilizer factor \(\mathrm{A}_{\mathrm{b}}\), and so on. Here, \(\mathrm{n}>0\) denotes the number of elements. 3. \(\mathrm{T}=\mathrm{T}_{\mathrm{i}}\cup\mathrm{T}_{\mathrm{j}}\big{(}\mathrm{T }_{\mathrm{i}}\cap\mathrm{T}_{\mathrm{j}}=\varnothing\big{)}\) is the set of transitions, triggered based on the conditions defined in \(\mathrm{D}_{\mathrm{ij}}\). This set includes two types of transitions: Time transitions \(\mathrm{T}_{\mathrm{i}}=\{\mathrm{t}_{1},\mathrm{t}_{2},\dots,\mathrm{t}_{k}\}\),which simulate activities with delays, such as the disease development stages. Instantaneous transitions \(\mathrm{T}_{\mathrm{j}}=\{\mathrm{t}_{k+1},\mathrm{t}_{k+2},\dots,\mathrm{t}_{ m}\}\), \(\mathrm{m}>0\), used to represent immediate events, such as the rapid diagnosis of a disease. 4. \(\mathrm{F}\subseteq\mathrm{a}^{+}\cup\mathrm{a}^{-}\) is the set of directed arcs, connecting places and transitions, determining the flow of tokens. \(\mathrm{a}^{-}\subseteq\mathrm{P}\times\mathrm{T}\) represents the input arcs of transitions in the Petri net; \(\mathrm{a}^{+}\subseteq\mathrm{T}\times\mathrm{P}\) represents the output arcs of transitions in the Petri net. The association matrix in the Petri net is defined as \(\mathrm{a}=\mathrm{a}^{+}-\mathrm{a}^{-}\). Set F has direction, representing the path through which pests and diseases transition from one state to another. \(\mathrm{W}:\mathrm{F}\rightarrow\mathrm{N}^{+}\) is the arc weight function vector, where \(\mathrm{N}^{+}=\{1,2,\dots,\mathrm{m}\}\), \(\mathrm{m}>0\) represents the capacity of each system transition. 5. \(\mathrm{M}:\mathrm{P}\rightarrow\mathrm{N}\) is the state-marking vector of the Petri net, which represents the possible states of the pest and disease spread system during its dynamic operation by defining the number of tokens in each place. \(\mathrm{M}_{0}\) represents the initial marking of the system. If there is no function defined on an arc, the default weight is 1. 6. \(\lambda=\{\lambda_{1},\lambda_{2},\dots,\lambda_{m}\}\) represents the average triggering frequency associated with time transitions [23]. Each \(\lambda_{\mathrm{i}}\) is an exponential distribution parameter used to describe the average time interval between the triggers of the corresponding time transition.