Next Article in Journal
Low Current Ripple Parameter-Free MPCC of Grid-Connected Inverters for PV Systems
Previous Article in Journal
A Study of the Field Test Method for the Adhesive Performance Evaluation of Self-Adhesive Waterproofing Sheets
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Cyber–Physical Systems-Based Double-Layer Mapping Petri Net Model for Factory Process Flow Control

Faculty of Electronic Information and Electrical Engineering, Dalian University of Technology, Dalian 116024, China
*
Author to whom correspondence should be addressed.
Appl. Sci. 2023, 13(15), 8975; https://doi.org/10.3390/app13158975
Submission received: 25 June 2023 / Revised: 1 August 2023 / Accepted: 3 August 2023 / Published: 4 August 2023
(This article belongs to the Section Applied Industrial Technologies)

Abstract

:
This study is concerned with the imperfect virtual-reality mapping relationship in cyber–physical systems (CPSs) and the challenge faced in knowledge-based decisions. Regarding those problems, a double-layer mapping Petri net (DMPN) model is proposed. By deploying the programmable automation gateway PAG200, combining the CPS technology with the principle of Petri net and establishing the monitoring Petri net in the cyber space, this model realizes mapping between the physical entity and the digital object. Meanwhile, the knowledge-based decision problem in CPS is defined as a Petri net conflict. In accordance with this, a control network for resolving the conflict is established. Finally, through a practical case, the workflow of DMPN is illustrated and a task allocation algorithm and a quality decision algorithm are proposed to resolve Petri net conflicts. Consequently, it is proven that DMPN is feasible in solving actual production process flow control. At the same time, it also provides a solution for enterprise workflow analysis.

1. Introduction

With the development of modern science and technology, the transformation from traditional manufacturing to intelligent manufacturing is an inevitable trend [1,2,3]. Correspondingly, in order to reduce the waste in the production process and improve quality while reducing costs, the production mode under the function subdivision needs to strictly monitor and control the manufacturing process. For this purpose, efficient monitoring requires physical devices to have mapping information that can be manipulated in cyber space: that is, it is necessary to complete virtual–real mapping from the physical entity to the digital object of information and achieve effective control.
In the process of enterprise development, the realization of virtual-reality mapping and knowledge-based decision has become an urgent problem to be solved [4,5,6]. The virtual-reality mapping function needs to realize the mapping, feedback, interaction, linkage and other activities between physical entities (people, equipment, materials, technological process/methods, environment, etc.) in the whole manufacturing process [7,8]. Under this requirement, cyber–physical systems (CPSs) stand out [9]. The functions of CPSs include four functional domains: business domain, fusion domain, support domain and security domain, as shown in Figure 1 (based on GB/T 40020-2021 “Cyber physics systems—Reference architecture”). Among them, the fusion domain, as the core of a CPS, realizes the fusion application of cyber space and physical space. In the fusion domain, the intelligent factory realizes the high interaction and integration between the production information and the manufacturing environment through the closed-loop function system of perception, analysis, decision-making and execution, including the virtual–real mapping between the physical entity and the information digital object. This virtual–real mapping function is an important guarantee for a CPS to effectively realize production monitoring, dynamic exception handling and decision optimization. At the same time, a CPS should also be able to process multi-source information resources such as data resources, algorithm resources and model resources and to assist in optimizing decisions at the commercial, organizational and operational levels.
In response to the problem of virtual–real mapping, many scholars have conducted in-depth exploration. The concept of DT shopfloor (DTS) was put forward in [10], and its four key components were discussed. Further, not only were the operation mechanism and implementation method of DTS studied but also the key technologies and challenges. In [11], the authors paid special attention to sensor networks, manipulators and power systems and summarize several typical distributed algorithms based on Kalman real-time monitoring. A digital-twin-based cyber–physical production system (DT-CPPS) based on DT was established in [12], and the configuration mechanism, operation mechanism and real-time data-driven job control of DT-CPPS were discussed in detail. Ref. [13] introduced in detail the DT framework of a robotic dual-arm cooperation system based on Petri net and transformed the loose DT metaphor into strict comprehensive practice in an industrial field, which made positive and effective exploration for the development of DT and CPS. The above scholars have given some solutions to virtual–real mapping, but there are also some problems such as too much theoretical research, less practical operation, narrow scopes of application and so on.
In summary, the problems addressed in this study are as follows:
1.
The virtual-reality mapping between the cyber layer and physical layer in CPS (namely the DT function in the system operation);
2.
The problem generalization of knowledge-based decision processes and the implementation of solutions.
The contribution of this study lies in the design of a double-layer mapping Petri net (DMPN), which splits the information feedback and decision into two networks to carry monitoring and control, solves the problem of virtual–real mapping and describes the event flow. DMPN provides a Petri net conflict resolution approach to the selection of Petri net branches, which ensures the orderly operation of the monitoring network. Meanwhile, it is clarified that DMPN is the actual production that inspires the control network: the control network affects the monitoring network, and the actual production state is reflected in the monitoring network. The limitation of this method is that the degree of automation of model generation needs to be improved.
By solving these problems, this study provides innovative ideas and methods for the research of virtual-reality mapping and knowledge-based decision in CPS. At the same time, the research results of this study have important practical significance to promote the development of the intelligent manufacturing field and to improve the production efficiency and competitiveness of manufacturing enterprises.
The rest of this study is organized as follows: In Section 2, the reason why Petri net is chosen as the modeling method and the literature studies related to this paper are introduced. Then, Section 3 presents the overall architecture of the DMPN model, followed by a description of the network-building approach in Section 4. A concrete case study to implement the DMPN model is given in Section 5, and the summary is placed in Section 6.

2. Related Work

This section mainly discusses and compares the advantages of Petri net modeling in CPS as well as the problems that may be encountered in the modeling process.

2.1. Advantages of Petri Net in CPS Modeling

In practical applications, most developers prefer to use 3D visualization to achieve the virtual–real mapping of intelligent factories. However, this belongs to the user-oriented upper user interface, while for the underlying running logic it is difficult to have a standard mathematical representation. It is necessary to find a suitable mathematical model that can represent asynchronous concurrency to describe the virtual–real mapping running logic. To describe the system, we first need to model it. It can be known that the manufacturing system under CPS is a discrete-event system [14]. There are many modeling methods for this system, such as automata [15], queuing theory [16], Petri net [17,18] and so on. Although the automaton also uses graphics, they only play the role of auxiliary descriptions, whereas mathematical methods are mainly used to describe the system. Queuing theory is mainly a mathematical descriptive tool and rarely controls the changeable behavior of the system. Petri net is used to describe the manufacturing process, and the modeling process of Petri net is introduced in detail in [19]. The advantage of Petri net is the ability to describe asynchronous concurrency and graphical representation [20], and this advantage makes Petri net widely used in the field of industrial manufacturing. Similarly, this characteristic comes from the partial order generated by the mesh structure, which makes it possible to describe asynchronous concurrency, while the graphic representation is more consistent with the reality of asynchronous concurrency [21,22]. Refs. [23,24,25] all used Petri net as a tool to improve the performance of CPS. To sum up, the modeling of a Petri net has better expression and mathematical analysis advantages than other tools in completing the CPS function. Therefore, this study uses a Petri net to describe the low-level behavior logic of virtual-reality integration with high concurrency in CPS.

2.2. Comparison between Petri Net and Generalized Net

In recent years, generalized net, as an important extension of Petri net, has been widely used in the modeling of general-information physical systems and service systems. Generalized net allows more flexible and comprehensive description of asynchronous concurrency and resource sharing in complex systems so that each service system can be represented as a generalized net and can thus be represented as a Petri net. Compared with traditional Petri net, generalized net has more powerful representation ability in constructing conceptual, mathematical and information models [26]. In particular, there is a generalized net model of flexible manufacturing systems based on intuitionistic fuzzy pairs [27]. In recent research, ref. [28] proposed a generalized net model for domestic wastewater treatment. In [29], a generalized net device was used to model the production process of commercial diesel oil in an oil refinery. The generalized net queuing model has been used to describe the queuing mechanism in a telecommunication system [30] and so on.
Although the generalized net has significant advantages in service system modeling compared with the traditional Petri net, the construction of a Petri net model is simpler and more intuitive, and it is easier to apply to complex manufacturing systems [19,26]. In particular, for plant process flow-control modeling, the advantage of Petri net is that it allows conceptual, mathematical and information models to be constructed more easily, thus realizing the effective combination of monitoring and control. Therefore, this study chooses Petri net as the modeling tool to solve the problem of virtual–real mapping in the actual production process. At the same time, we should not ignore the more powerful modeling capabilities brought by extensions such as generalized net. Future research can deeply explore the application potential of Petri net and generalized net in different fields so as to provide more choices for intelligent development and optimization of decision-making in the manufacturing industry.

2.3. Stability of Petri Net

In most industrial production processes, stable operation is the premise of normal production. Therefore, the stability of Petri net modeling cannot be ignored. In a Petri net, stability refers to whether there is a certain identification state in all potentially enabled transitions so that all enabled transitions are no longer enabled, so that the system is in a stable state and does not change. To judge the stability of a Petri net system, we can use a marking method or transition rule method. The marking method refers to finding an identification vector in the state space of the Petri net so that all enabled transitions are no longer enabled. The transition rule method describes the properties of the system by establishing transition protocols, such as T-protocol, S-protocol, R-protocol and so on.
The concept of exponential stability of a Petri net system was proposed in [31]. When a Petri net system goes through a series of state transitions, if its state shows an exponential decay or growth trend with the passage of time, rather than divergence or shock, then we can say that the Petri net system has exponential stability. You usually need to use the Lyapunov function to make the judgment. Exponential stability is a subset of stability. If a Petri net is exponentially stable, then it must be stable because the exponential stability condition ensures that the incidence of transition in the system is bounded, thus avoiding infinite growth or attenuation of the system.
According to the different modeling objects, the requirements for the stability of the model are different. For example, in disturbed control systems, communication systems that provide efficient services, and economic models in economics, systems with stability are needed. In non-real-time systems or analog mapping systems, the requirement of modeling stability is not high. So whether to consider the stability of the system depends on the specific application scenarios and system requirements.

2.4. Conflict Problems and Solutions in Petri Net

In the manufacturing system, the process of decision-making, planning, scheduling, management or operation of a limited number of options is a knowledge-based decision tree (multi-tree). The result is to choose a feasible, correct or optimal branch to proceed, which is very consistent with the Petri net conflict selection problem, as manifested in Figure 2. Unfortunately, Petri net also has some theoretical problems to be solved. When there is more than one transition in the post-set of one place, the conflict of free choice occurs. Correspondingly, the conflict phenomenon is equivalent to the problems to be determined in the system, such as task scheduling, intelligent decisions, etc. Therefore, solving the knowledge-based decision problem in the actual production operation process of the factory is equivalent to solving the Petri net free-choice conflict phenomenon. Many scholars have studied the conflict of a Petri net. Starting with the influence of the directed loop of a Petri net on structural activity, the structural activity of a conflict-free Petri net was analyzed and determined in [32]. Further, the relevant conditions and conclusions of the methods for determining the structural activity of this kind of Petri net were studied, and it was concluded that a conflict-free Petri net is a necessary and sufficient condition to satisfy the structural activity.
In the case of conflict, the choice of which transition is enabled is completely uncertain, and the enablement of either transition is possible. At the same time, the enablement of one transition makes other transitions impossible. In the timed Petri net model, there are several kinds of simple strategies that can be applied:
1.
The first is to set priorities and determine the priority of transition enablement. In this case, transitions with high priority can be enabled, while transitions with low priority cannot be enabled. For example, in the PIPE v4.3.0 version of the Petri net simulation tool, this method is applied to resolve conflicts. In addition, ref. [33] proposed a hybrid timed Petri net modeling method with test arcs to solve the problem of resource conflict between time and space in distributed systems. Additionally, it uses the priority function to determine the order of conflict transitions so as to achieve the purpose of resolving conflicts in the distributed shunting system of train stations.
2.
The second method depends on the firing time of the transition. In this case, if the post-set consists of an immediate transition and a time transition, the immediate transition is enabled while the time transition is not enabled. Further, if all options are time transitions, the transition that has the shortest firing time is enabled.
3.
The third method is to change the network structure, such as upgrading Petri nets to advanced net systems: predicate/transition systems or colored net systems [34]. In this case, transitions that satisfy the enabled condition’s predicate or color requirements can be enabled. However, the existence of an advanced network increases the complexity of the network and makes readability worse.
The above strategies can better solve the conflict problem in an environment with strict order. With the deepening of research, there are many methods of conflict detection and resolution. Ref. [35] extended the UML activity graph and used the method of graph simplification to reduce the model to an appropriate scale, thus realizing a conflict detection algorithm. At the same time, by analyzing the causes of various conflicts, corresponding conflict resolution schemes were given. In [36], behavior modeling based on Petri net was introduced, and a multi-domain hierarchical mapping model of a complex technology system was constructed by using the decomposition mapping method of top-down and bottom-up. Afterwards, conflicts were located with the help of Petri-net-related tools and were resolved by applying TRIZ. Two methods of global resolution based on a genetic algorithm and local resolution based on Petri net were proposed in [37] to deal with different types of resource conflicts.

2.5. Application Progress of Petri Net in Process Modeling

With the development of Petri net technology, it has also been used to model processes. In [38], aiming at PLC-based systems with low computing power, a fault-diagnosis problem was modeled by Petri net, an integer linear programming (ILP) problem was defined and solved, and a fault diagnosis algorithm was developed. Compared with other ILP-based methods, this algorithm had higher computational efficiency. In order to verify the modeling ability of logical Petri net (LPN), a systematic LPN synthesis approach for cooperative systems was proposed in [39]. At last, an e-commerce system was constructed to verify the effectiveness of the method.
All the above studies have put forward some effective methods to solve the conflict problem of Petri net, but the network operation logic is not clear: the logic is confusing as to how the decision-making method is implemented in the network—whether the decision of the actual production is reflected in the network or the decision in the Petri net affects the actual production. This study focuses on this problem in the following sections.

3. Overall Architecture of DMPN

We relied on DUT Computer Control Engineering Co., Ltd. (DCCE; DUT represents Dalian University of Technology), which is located in Lvshun District, Dalian, Liaoning Province, China. This manufacturer uses its independently developed programmable automation gateway PAG series as a physical-layer PLC to provide machine agent services and performs unified management and programming in the PLC_Config v2.11.8 software [40]. Figure 3 depicts the overall architecture of the proposed model. In the lower part of the picture is the physical layer, and manufacturing resources can be monitored through RFID, sensors or code scanners. After the real-time status is transmitted to the PAG controller by a wired or wireless network, it is preprocessed, and the processed data is transmitted to the monitoring network of the cyber layer through the network. There is a double-layer extended deterministic and stochastic Petri net (EDSPN) in the upper cyber layer in Figure 3, which is the monitoring network and the control network. The network part is developed in the host computer’s DView v2.6.7.05191 software. Herein, the monitoring network is mainly responsible for mapping the information of physical entities to digital signals for real-time display. The control network extracts the conflicting places and their pre-sets and post-sets to establish the main control subnet. Then, through comparison between the operation of the double-layer network and the data captured, the control network completes the functions of task scheduling, intelligent decision-making and network analysis.

3.1. Virtual-Reality Mapping

The PAG gateway is placed in the industrial field as a machine agent and is connected to the field equipment to form the field control system. Through the application of advanced internet of things technology (such as RFID, pressure sensors, cameras, etc.), PAG can independently capture real-time manufacturing information, store all kinds of field data in PAG memory variables, complete virtual-reality mapping, and process some simple data and logic. The connectors of the PAG200 are shown in Figure 4.
Among them, V+, V-, EV+ and EV- are power connectors; ETHn (n is the order; the same nomenclature follows) are Ethernet ports; Tn+ and Tn- are serial ports; In are digital input connectors; Qn are digital output connectors; COM is the common port; the DIP switch can be combined to create more configurations. The digital input and output connectors can be extended by means of EIO modules, and the analog input and output connectors can be extended with EA modules. Thus, the higher number of expansion connectors ensures that the PAG200 has the possibility to capture field data as a gateway.
The PAG200 usually uses an Ethernet link to connect to the host computer. As shown in Figure 5, this is implemented in the upper-level computer software Dview: add the machine agent of the corresponding gateway and enter the correct IP and other parameters to complete the mapping of field devices in the cyber layer.

3.1.1. Data Capture

All the functions of the cyber-layer monitoring system are directly or indirectly based on data acquisition, so data acquisition runs through the life cycle of the whole system. The collected data can be roughly divided into system data and dynamic data. System data refer to the fixed parameters in the production process, such as equipment parameters, communication parameters, operation parameters and so on. Dynamic data refer to the parameters that are constantly changing in the production process, and this part of the parameters is real-time data.
According to the mode of communication, industrial field equipment can be divided into Ethernet equipment and serial port equipment. PAG has two-channel Ethernet and three-way RS485, which supports both Ethernet communication and serial communication. Each PAG and Ethernet device has a unique IP address, which can be accessed by any device in the network through the IP address. PAG sends EPA messages to devices with the corresponding IP addresses through EPA communication function block NETR to obtain variable data for each variable area of the equipment. At the same time, PAG can connect the field devices as slave devices by serial communication, and serial communication instructions can map the variable areas of the slave devices that are found by the controller.

3.1.2. Variable Management

There is a large amount of data in the industrial field. In real-time data services, in order to receive and process a large amount of data better, we need to manage the variables bound to the data and choose a more appropriate way to store the variables so as to reduce the waste of memory and make it easier to find the data. As an edge-side machine agent, PAG can map resources to devices by configuring slave devices. PAG provides three resource-mapping modes: simple mode, full mode and custom mode. Among them, simple mode can only automatically map the I/O data of the slave device to the corresponding variable area of the master controller, complete mode can map other internal variable areas, and custom mode needs to be configured manually. According to the situation of the extended device, we can set the mapping of input and output parameters. By setting the resource mapping parameters, the equipment variable area can be mapped to the corresponding variable area of the PAG: from the equipment analog input variable AI area to the PAG extended analog input variable PAI area, from the equipment analog output variable AQ area to the PAG extended analog input variable PAQ area and so on for other I/O parameter mappings so as to realize data exchange between devices. After mapping the variable areas, part of the real-time control can be carried out on the edge side, which can shorten the delay time and achieve fast response.

3.2. The Operational Principle of Monitoring and Control Networks

The principle of DMPN is quite different from that of hierarchical Petri nets. A hierarchical Petri net mainly deals with readability. Because a complex process is reflected in the Petri net, there is more state space, which makes the network structure more complex and difficult to understand. For researchers who do not need to pay attention to specific processes, these accurately described processes become redundant, and the method of hierarchical decomposition can be used to solve this problem. Additionally, hierarchical Petri net can decompose some complex workflows into subnets, and complex processes in subnets can continue to be decomposed into subnets. For people who want to understand the differing complexities of the network, they can choose network-level selectively. On the other hand, DMPN does not function in this way. Actually, it solves the real-time mapping problem between Petri net processes and device entities. For Petri net, it is more used for post-analysis. If the network satisfies the transition firing conditions, it can generate tokens in the post-set. However, for engineering practice, the transition firing conditions satisfied by Petri net are only the most important conditions, and there are some conditions or emergencies that cannot be easily added to the network, such as missing materials, machine damage or network disconnection. Therefore, the on-site situation cannot always run according to the established logic of a Petri net. Conversely, in DMPN, the monitoring network is a network that can represent the status of the scene in real time. The transition time, which is different from the traditional Petri net, is calculated later. Further, the control network is a copy of the monitoring network and mainly uses the subnet information, composed of the conflict places and its pre-sets and post-sets, to complete the control function, and the bearing function determines the direction of the branches of the Petri net.
The monitoring network Σ m n t and the control network Σ c t are two parts of DMPN: neither part can be omitted. A Petri net is mainly a description of the process; however, there is no clear description of how the Petri net reflects and influences the field devices mathematically. As described, mapping the field devices is the main reason for the functional distinction. In the industrial field, monitoring tasks and control devices usually belong to different departments, and the behavior of control and decision making have a greater impact on the whole process. Wrong operations and decisions may bring huge losses to enterprises. Therefore, in the whole process, it is not conducive to personnel responsible to describe feedback-based monitoring behavior and operational behavior with significant impact on one network when it is not in line with the actual situation.
In order not to break its original rules and definitions and to embody the original advantages of Petri net in the CPS architecture, Σ c t is established on the basis of Σ m n t . After that, Σ c t is equivalent to the power source of Σ m n t , while Σ m n t mainly receives on-site data for reflecting the presentation and operates according to the conventional Petri net rules. The double networks work together to realize the function of virtual-reality mapping. Further, in the latter case description, it can also be reflected that Σ c t is separated, and  Σ m n t can better describe the product production process.
There is cooperation with scripts to write double-net control logic in the HMI of Dview. In the physical layer, there are objects such as field devices, which correspond to the machine agents in the PAG gateway, thus completing the virtual-reality mapping. In the cyber layer, there is monitoring network and a control network, which are, respectively, responsible for displaying the running status of field equipment and controlling it. The running logic of DMPN is shown in Figure 6. In the partition with the label l o o p , the field device constantly updates its status; the monitoring network obtains the device status through g e t S t a t e s ( ) , and the preceding “*” indicates iteration. However, once it is found that a conflict place has obtained the token, the system enters the a l t conditional execution partition, and the conflict place P is passed to the monitoring network through the c o n f l i c t ( P ) function.Then, the monitoring network transfers the conflict place P and related parameters a r g s to the control network through t h r o w ( P , a r g s ) . In addition, the control network calls the selection function P r to resolve the conflict, and the corresponding site may be task scheduling, decision making, etc. After the conflict resolution is completed, the control network sends the r e s u l t s to the monitoring network and the field devices so that the site can proceed further in an orderly manner, and the new status is captured by the monitoring network through g e t S t a t e s ( ) to complete the proofreading of the processing results of the control network. In other words, it is p r o o f ( c t r l S t a t e , d e v S t a t e ) , among them, where c t r l S t a t e is the control state and d e v S t a t e is the device state.

4. The Establishment of Networks

The establishment of a network needs to be based on whether it is built one-to-one for each unit according to the actual needs. Networks that are too complex cause problems such as too many states, poor readability and so on. On the contrary, advanced network systems or over-simplified networks may poorly reflect the actual operating state. For this reason, the network built in this study needs to reflect the running state of each unit, so it is necessary to establish unit-level modeling for one-to-one mapping.

4.1. Monitoring Network

Definition 1.
The main function of the monitoring network is to reflect the entity state and to adopt unit-level modeling. It is usually a six-tuple EDSPN model
Σ m n t :
Σ m n t = ( P , T ; F , W , M 0 , λ ) .
Remark 1.
P = { p 1 , p 2 , , p a } is the place set. DMPN divides states and resources into places. When a place represents a resource place, the number of black dots indicates the number of such resources, which are called tokens. T = T i T t = { t 1 , t 2 , , t m } { t 1 , t 2 , , t n } is the transition set. Among them, T i is the immediate transition, T t is the time transition, and τ n represents the firing time of transition t n . Two different states are transformed by some kinds of changes and are divided into transitions. F is the flow relationship, which is represented by an ordered pair such as ( p 1 , t 1 ) means from p 1 to t 1 . The place set and the transition set are the basic components of the directed network from which the flow relation is constructed. Therefore, the semicolon “;” is used to separate “ S , T ”. The system behavior of Petri net is represented by the change of state or the flow of resources. This change or flow is reflected by the flow relationship and is represented by arcs. W is the weight function on Σ m n t , which represents the number of tokens required when the transition occurs. By default, it is 1 when not marked. M 0 is the initial marking on Σ m n t . It shows the tokens distribution of Petri net in the initial state. λ = { λ 1 , λ 2 , , λ n } is the set of average firing rates of transitions. It means the average number of firings per unit time when enabled. The unit is the number of times per unit time.
The following is the method of establishing a monitoring network part:
  • Mapping places: A variable table X P L C is maintained in PLC, and the principle of establishing the table is: All the Boolean variables X m n t needed to establish the model, the intermediate variables X P t e m p needed by X m n t and the variables X d p that need to be displayed and monitored by the host computer are calculated. Then, all the variables in X PLC are imported into the DView variable table to become X DView . At this point, the same table as in PLC is maintained in the host computer software DView: that is, X PLC = X DView . The functions of the two tables are different. In particular, the variables in X PLC are data sources, mainly from the field environment, while the variables in X DView are mainly used to monitor and control the system. It is worth noticing that x DView X m n t is the place of Σ m n t ; that is, X m n t = P . At last, all variables are imported in DView and variable groups are divided according to the actual situation. The imported variables are in DView.
  • The relationship of the state transition is analyzed from the actual operation condition, and the flow relationship is temporarily from place-to-place. For this purpose, some scholars have researched how to map the state relationship automatically: for example, using log-mining technology to describe the state [41,42] and so on. Nevertheless, this study does not discuss this in depth because this is not the point in question.
  • Obtain transitions and the rates of time transitions: In Petri net, it is stipulated that a place cannot flow to a place but can only flow to a transition. Thus, transitions need to be inserted between places. The principles for inserting transition are: The immediate transition is inserted between two places with no practical meaning, and the time transition is inserted between places that have actual actions that can be defined. Afterwards, there are two ways to obtain the firing rate, and one is by calculating the recorded time τ i . Because the transition represents an action, some actions are recorded for a value of time: for example, a pressure test requires recording of the holding time. Thus, this formula is used to calculate λ i :
    λ i = 1 τ i , i = 1 , 2 , , n .
    The other is that the transition action without recording the time value obtains τ i according to the time stamp t i m e ( x ) of the state before and after the transition, where x X m n t x X P t e m p , and its calculation method is as follows:
    τ i = t i m e ( M I N ( t i ) ) t i m e ( M A X ( t i ) ) .
    Among them, t i represents the post-set of t i , and similarly, t i represents the pre-set of t i .
  • Mapping the tokens of M 0 state: Similar to places, tokens are divided into state tokens and resource tokens. Status tokens are represented or automatically generated by the network according to the actual situation. Correspondingly, resource tokens need to be certified to enter the network. As an example, products and operators need to scan the code into the network.

4.2. Control Network

The main function of the control network is to solve the conflict of Σ m n t . Therefore, the control network needs to add a set of selection functions P r on the basis of Σ m n t . The relevant definitions are as follows.
Definition 2.
For p i P , | p i | > 1 p i P c f l . On the contrary, | p i | 1 p i P n c f l . Among them, P c f l is the conflict place set, and P n c f l is the non-conflict place set.
Definition 3.
P r : P c T . If p i P c , P r ( p i ) means that the conflict selection is made at the location of the conflict place p i , and the result of the selection is no longer random, but t j p i is enabled after being constrained by the function P r .
Definition 4.
The EDSPN model Σ c t of the control network is defined as:
Σ c t = ( Σ m n t , P r ) .
Definition 5.
The workpiece belongs to the individual who flows in the net and is represented as a token in Petri net. Thus, define the token set as D and individual token d D . Further, define the following forms: d p indicates that token d is in place p. Tokens have attributes in the form:
d ( t y p e , i t e m 1 , i t e m 2 , , i t e m n , n N + ) .
where d . t y p e represents the artifact type, d . t y p e . i t e m represents other attributes of the artifact, and n is the order of concerned attributes of the workpiece, which is limited.
Definition 6.
As illustrated in Figure 7, define working group in the form of class, which is a virtual class that has its own properties and methods, such as G r o u p ( t i ) means to retrieve the working group instance where t i is located and return it. Define the mathematical form of the working group as:
G r o u p ( S t a t e A n d O p e r a t e , O p e r a t o r , M a c h i n e , ) .
Among them, “…” indicates the class members that are dispensable to readers, while not means infinity, and Figure 7 is the same.
The following is the method of establishing a control network part:
  • Get the mapping of set places, transitions and tokens from Σ m n t . At the same time, a variable table X H M I in the human–machine interaction component of DView is maintained. This table mainly provides temporary variables during control as well as variables that need to be displayed in the interface but do not need to exist in the PLC.
  • Select the conflict places p i P c f l and set P r ( p i ) . In order to allow tokens to choose the expected transition flow, the function of P r ( p i ) can be the choice of station, product quality decision, etc.
  • For a fully automated network, set the control options for the transition, such as start and stop, to prevent the workpiece from being processed into scrap, etc., when an exception occurs.

5. Control Network Algorithm

Typical task-scheduling algorithms are divided into the following broad categories.
1.
First-come-first-served (FCFS) scheduling algorithm: The characteristic of this method is that each scheduling selects one of the ready tokens that are the first to enter the p 1 or p 47 and assigns the processor to put it into operation.
2.
Short-job (process)-first (SJ(P)F) scheduling algorithm: This selects a token with the shortest scheduling time for priority scheduling.
3.
Highest-priority-first (HPF) scheduling algorithm: This algorithm selects the token with the highest priority. Additionally, it can be divided into preemptive or non-preemptive.
4.
Round-robin (RR) scheduling algorithm. In this method, all ready tokens are queued according to the principle of FCFS, and each token from the head of the queue to the end of the queue can be allocated a time slice of execution time in turn.
For a small factory, there are no more than 100 tokens to be processed at the same time. In addition, the task-scheduling algorithm takes milliseconds and the manufacturing or testing of a product is seconds, so the time-consumption of the algorithm is almost ignored. In the above algorithms, SJ(P)F, FPF and RR are proposed for the time-consuming cost of the algorithms and are not suitable for the working conditions of decision-making of small production processes. Additionally, in practice, simple, stable and reliable are the first requirements of the system, so FCFS is chosen to design the algorithm. In actual work, each operator has his own machine for which he/she is responsible. Since the salary system does not mean more work equals more pay, the principle is equal distribution. Products have their own quality standards, which are qualified if the index is met. According to this principle, the following two algorithms are given.
Algorithm 1 gives the method of task allocation. First, different workstations have their own product pressure test projects. Therefore, it is necessary to carry out type-matching first, and the stations that meet the requirements enter the selected set in line 2 of Algorithm 1. Then, we judge whether the machines of each working group are ready and whether the operators are in place. According to the result, we remove those that do not meet the requirements in the selected set in line 7 of Algorithm 1. Last, according to the working hours of operators in the working group to which t i belongs, t i is sorted from small to large, and the t i output with the smallest working hours is selected in line 12 of Algorithm 1.
Algorithm 1 Load-balancing method of distribution according to work.
Require: 
d p P c f l
Input: 
d
Output: 
t p
1:
functionTaskScheduling(d)
2:
    for each  t i in p  do
3:
        if  d . t y p e t i . t y p e  then
4:
            T o . a d d ( t i )                                                                 ▹ T o is the selected set
5:
        end if
6:
    end foreach
7:
    for each  t i in T o  do
8:
        if  M ( G r o u p ( t i ) . M e c h i n e ) < 1 M ( G r o u p ( t i ) . O p e r a t o r ) < 1  then
9:
            T o . r e m o v e ( t i )
10:
        end if
11:
    end foreach
12:
    sort( T o , T o . O p e r a t o r . t o t a l T i m e )                         ▹ sort is an ordering method
13:
    if  T o Φ  then
14:
        return  T o [ 0 ]
15:
    else
16:
        TaskScheduling(d)
17:
    end if
18:
end function
Algorithm 2 gives a simple quality-decision algorithm. When several items required of the workpiece tested are qualified, the workpiece is qualified. As a result, when the workpiece is qualified, it returns to transition t o k , while it returns to transition t n o when unqualified. Among them, t o k is the branch trend that has been proven to be qualified in the actual process, while t n o is unqualified.
Algorithm 2 Quality decision.
Require: 
d p P c f l
Input: 
d
Output: 
t p
1:
function QualityDecision(d)
2:
    for each  i t e m i in d do
3:
        if  i t e m i d . t y p e . i t e m  then
4:
            i t e m i . c h e c k = t r u e
5:
        end if
6:
    end foreach
7:
    if  d . i t e m 1 . c h e c k d . i t e m 2 . c h e c k d . i t e m 3 . c h e c k d . i t e m 4 . c h e c k = t r u e  then
8:
        return  t o k
9:
    else
10:
        return  t n o
11:
    end if
12:
end function

6. Case Study

Here, the proposed DMPN is demonstrated by the pressure-test process of valve and hydrant at Dalian Reliable Metal Co., Ltd. (DRM) (Dalian, China). DRM mainly produces metal valve and hydrant products and now produces DN-series gate valves. Various specifications of gate valves from DN40 to DN600 have formed a complete production chain from casting, machining, rubberizing, spraying, quality inspection and so on. The quality inspection, namely pressure test, is one of the most important sub-processes in the whole metal-product production process, and the final presentation of product performance depends on the pressure test data report formed by this process.

6.1. System Composition

The object of this CPS transformation is the quality inspection pressure test process of valves and hydrants at DRM. The pressing area of the pressure test system reformed by CPS is subdivided into four parts: large area, medium area, small area and additional area. Among them, the large area only works for hydrant products, and the medium area, small area and additional area work for the valve products. The small area is the area where the latest quality inspection equipment has been deployed, and the equipment in the medium area and additional area is relatively old, but it can carry out pressure test for medium- and large-valve products. The front part is the assembling area, which is responsible for transporting the parts to the pressing area for pressure test after assembly, and the back part is the packing area, which is responsible for packing and storing the qualified products after the pressure test.
The specific process is exhibited in Figure 8. The type and quantity of products planned by the production department are coded and made into bar codes every day. The production sequence is as follows: The raw materials are assembled to form the basic workpiece. After the workpiece is assembled, data are recorded. At the same time, the workpiece is transferred to the pressing area for recording of data and to check whether the workpiece is qualified. After the pressing is finished, the workpiece is transferred to the packing area to complete the final inspection of the product.
DView series software is used in the upper computer to program the human–machine interface. DView is a data monitoring system development platform developed by DCCE for the field of industrial automation.

6.2. Establishment of Monitoring Network

The pressure test system consists of three subsystems: assembling, pressing and packing. Because of the complexity and representativeness of the pressing link, the pressing subsystem is described as representative. Using the method provided in Section 4.1, the EDSPN model of a monitoring network can be generated.
  • Create a table X PLC of PLC variates. Next, export all variables directly in PLC_Config software, and then, import all variables in Dview and divide variable groups according to the actual situation. Last, map X m in the variable group to the place, and the work of mapping is complete.
  • Establish the state-transition relationship of the place. Because the state-transition relationship cannot be generated directly by PLC for the time being, the state-transition relationship is defined manually according to the actual situation. The status is revealed in Table 1. Among them, for example, p 2 , p 7 , p 10 , p 15 , p 20 , p 23 , p 28 , p 31 , p 36 , p 39 , p 44 indicates the one-side sealing test completion state of different stations. There are a total of 11 stations, and the pressure test process of each station is the same, so the transitions in Table 2 are the same.
  • Insert transitions between adjacent states. The meanings of transitions are revealed in Table 2. As different workstations may test different products, the last transition time is displayed in the software as a reference. Finally, the resulting Petri net is demonstrated in Figure 9.
  • Map tokens in the initial marking. Code the station, operator and workpiece respectively and make a bar code. Briefly, the station and operator are coded sequentially according to the serial number. The station code consists of three characters. The first character represents the machine, and the second and third characters are serial numbers. For example: M01 represents the machine of Station 1. The operator code is similar to the station and consists of four characters. The first character represents the company code, and the second, third and fourth characters are serial numbers; for example, R001 represents worker Wenhui Liu. As for workpiece coding, it is more complex, as illustrated in Figure 10. It consists of 13 characters, in which the first 3 characters are serial numbers, the 4th and 5th characters are product type codes, the 6th and 7th characters are the model code and pressure-level code, respectively, then, the last 6 characters represent the production date. The monitoring network for monitoring the status of the node is thus completed.

6.3. Establishment of Control Network

The control network can be established according to the method in Section 4.2.
  • According to (1) and (4), Σ c t inherits all the structures and attributes of Σ m n t and maintains a table X H M I in the HMI of the host computer software DView, which is used to display or control the intermediate variables in the interface.
  • Filter the places p c f l P c f l of | p i | > 1 according to the structure of the place set, as exhibit in Table 3.
    Set P r ( p 1 ) and P r ( p 47 ) functions, where P r ( p 1 ) is the rule-based task allocation algorithm and P r ( p 47 ) is the quality decision algorithm. According to (5), D . t y p e represents the type of workpiece, and d . t y p e . i t e m represents the set of projects for which the workpiece needs to be pressure tested. Further, the number of concerned attributes of the workpieces is four, and d . i t e m 1 , d . i t e m 2 , d . i t e m 3 and d . i t e m 4 represent the one-side sealing test, other-side sealing test, shell-strength test and low-pressure test, respectively. Among them, we use true or false in d . i t e m i . c h e c k to denote the qualification of each item. The specific pressure test is determined by the pressure test standard table maintained by the host computer. Individual attributes are only used for algorithm description and do not need to be reflected in the network. The division of the working group is based on operators, so the system is divided into six working group instances, as shown in Table 4 according to (6):
    The DRM plant involved in the renovation has only 11 pressure test stations, and there is less task flow. In addition, DRM products have their own quality standards and maintain a product pressure test index in the database, which is qualified if the index is met. According to this principle, we replace the condition in Algorithm 1, namely P r ( p 1 ) : Require, d p 1 ; Input, d; Output, t p 1 = { t 1 , t 5 , t 9 , t 13 , t 17 , t 21 , t 25 , t 29 , t 33 , t 37 , t 41 } . After putting the condition in Algorithm 1, we have a method of task allocation, and the t i output with the smallest working hours is selected. Further, we substitute the condition into Algorithm 2, namely P r ( p 47 ) : Require, d p 47 ; Input, d; Output, t p 47 = { t 45 , t 46 } . A qualified workpiece is output as t 45 , and an unqualified workpiece is output as t 46 .
  • Because the system is not fully automatic and it is dangerous for the control center to operate the machine without knowing the situation on the spot, it is not necessary to intervene in the factory site, and the upper computer is not designed to control the machine on the spot.

6.4. Monitor and Control Process

By communicating with the person in charge of DRM, this paper demonstrates the arrival of three workpieces after assembly, namely, an IPS socket gate valve, Italian gate valve and SPS hydrant. The pressure test parameters are shown in Table 5.
As shown in Figure 11, the host computer can monitor the full state of the pressure test process at any time. The left side of the interface provides the relevant functions, and the right side gives the detection network status and node attributes of the current state.
The three workpiece numbers are 001AEGA220514, 002AAHA220514 and 003FBKB220514 in sequence, and they have all been scanned into the network. On that day, all the workers on duty are ready to scan the code and enter the network, and the machines are running normally without failure and are numbered M01–M12. The operation process is as follows: scan the code for each individual workpiece, query the specific type of workpiece, and guide the next part of the pressure test. At the same time, perform P r ( p 1 ) to assign tasks so that workers know the corresponding station that each workpiece needs to enter. Then, after all the projects that carry out the pressure test according to the workpiece pressing standard are completed, the test process data are returned to the control network, and the qualification of each item is calculated for storage. Further, P r ( p 47 ) is executed to let the host computer make quality decisions. Finally, according to the different decision results, the product is selected to enter either the qualified or unqualified transition. During this period, the monitoring network always collects on-site data and displays them, while the control network is responsible for solving problems, and the two networks work together. Essentially, the coordinated operation of the monitoring network and the control network makes the workpiece flow clear and the system run stably.
After the pressure test, Figure 12 demonstrates the state-transition diagram of the three workpieces. Since the M01–M03 machines are the exclusive site for testing hydrant products, 003FBKB220514 is assigned to machine M01, while the remaining 001AEGA220514 and 002AAHA220514 products are respectively assigned to machines M04 and M06 mainly according to the working hours of the workers. In addition, different items are tested according to the product type: 001AEGA220514 and 002AAHA220514 were subjected to three pressure tests on one side seal, the other side seal and shell strength in the assigned station, while 003FBKB220514 was subjected to one side seal, shell strength and low-pressure tests. Furthermore, the state-transition sequence of the three workpieces is exhibited in Table 6.
After the completion of the construction of the system, it passed the acceptance smoothly. DRM responded that it can improve production efficiency to some extent because each workpiece has evidence to rely on and can be traced back. Because the system can accurately record acceptance and rejection, the delivery rate of accepted units also greatly improved, and customer satisfaction is very high. Most importantly, the system facilitates the supervision of the status of the workshop by the upper management.

7. Conclusions

In this study, a double-layer mapping Petri net DMPN is designed to solve the problem of virtual–real mapping in the system operation and the implementation of the solution. In the DMPN, the monitoring network is responsible for the integration of the physical layer and the cyber layer, establishing the mapping relationship, describing the process progress, and representing the process easily without destroying the original semantics of Petri net. The processing method is placed in a control network for dealing with system network conflicts, and the control network provides a downward “driving force” for the monitoring network. At the same time, it is embodied in knowledge-based decisions in the physical space. Further, a task allocation algorithm and a quality decision algorithm are designed to solve the problem of distribution according to work time and a quality test report in a case. To sum up, the DMPN is a feasible modeling method in CPS to achieve virtual–real mapping and solves the challenges faced by CPS in virtual-reality integration and knowledge-based decision. The direction of future work is that the method of system modeling should be more streamlined and expert experience should be programmed so as to realize automation of the whole process and reduce labor cost.

Author Contributions

Conceptualization, Y.Y., X.L. and W.L.; methodology, Y.Y.; software, Y.Y.; validation, X.L. and W.L.; formal analysis, W.L.; investigation, Y.Y.; resources, W.L.; data curation, Y.Y.; writing—original draft preparation, Y.Y.; writing—review and editing, Y.Y., X.L. and W.L.; visualization, Y.Y.; supervision, X.L. and W.L.; project administration, X.L. and W.L.; funding acquisition, W.L. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the National Natural Science Foundation of China grant numbers 62073056 and 61876029; the Applied Basic Research Project of Liaoning Province grant number 2023JH2/101300207; the Dalian Key Field Innovation Team Project grant number 2021RT14.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Frank, A.G.; Dalenogare, L.S.; Ayala, N.F. Industry 4.0 technologies: Implementation patterns in manufacturing companies. Int. J. Prod. Econ. 2019, 210, 15–26. [Google Scholar] [CrossRef]
  2. Mittal, S.; Khan, M.A.; Romero, D.; Wuest, T. Smart manufacturing: Characteristics, technologies and enabling factors. Proc. Inst. Mech. Eng. Part B J. Eng. Manuf. 2019, 233, 1342–1361. [Google Scholar] [CrossRef] [Green Version]
  3. Hsieh, F.S. A Theoretical Foundation for Context-Aware Cyber-Physical Production Systems. Appl. Sci. 2022, 12, 5129. [Google Scholar] [CrossRef]
  4. Uhlemann, T.H.J.; Lehmann, C.; Steinhilper, R. The digital twin: Realizing the cyber-physical production system for industry 4.0. In In Proceedings of the 24th CIRP Conference on Life Cycle Engineering (CIRP LCE), Kamakura, Japan, 8–10 March 2017; Voume 61, pp. 335–340. [Google Scholar]
  5. Wollschlaeger, M.; Sauter, T.; Jasperneite, J. The future of industrial communication: Automation networks in the era of the internet of things and industry 4.0. IEEE Ind. Electron. Mag. 2017, 11, 17–27. [Google Scholar] [CrossRef]
  6. Moin, A.; Challenger, M.; Badii, A.; Guennemann, S. A model-driven approach to machine learning and software modeling for the IoT Generating full source code for smart Internet of Things (IoT) services and cyber-physical systems (CPS). Softw. Syst. Model. 2022, 21, 987–1014. [Google Scholar] [CrossRef]
  7. Jing, X.; Yao, X.F. Towards social cyber-physical production systems. Acta Autom. Sin. 2019, 45, 637–656. [Google Scholar] [CrossRef]
  8. Liu, Y.K.; Ong, S.K.; Nee, A.Y.C. State-of-the-art survey on digital twin implementations. Adv. Manuf. 2022, 10, 375. [Google Scholar] [CrossRef]
  9. Li, H.Y.; Wei, M.H.; Huang, J.; Qiu, B.H.; Zhao, Y.; Luo, W.C.; He, X.; He, X. Survey on cyber-physical systems. Acta Autom. Sin. 2019, 45, 37–50. [Google Scholar] [CrossRef]
  10. Tao, F.; Zhang, M. Digital twin shop-floor: A new shop-floor paradigm towards smart manufacturing. IEEE Access 2017, 5, 20418–20427. [Google Scholar] [CrossRef]
  11. Ding, D.; Han, Q.L.; Wang, Z.; Ge, X. A survey on model-based distributed control and filtering for industrial cyber-physical systems. IEEE Trans. Ind. Inform. 2019, 15, 2483–2499. [Google Scholar] [CrossRef] [Green Version]
  12. Ding, K.; Chan, F.T.S.; Zhang, X.; Zhou, G.; Zhang, F. Defining a digital twin-based cyber-physical production system for autonomous manufacturing in smart shop floors. Int. J. Prod. Res. 2019, 57, 6315–6334. [Google Scholar] [CrossRef] [Green Version]
  13. Hu, F.; Wang, W.; Zhou, J. Petri nets-based digital twin drives dual-arm cooperative manipulation. Comput. Ind. 2023, 147, 103880. [Google Scholar] [CrossRef]
  14. Liu, J.; Zhou, Z.; Wang, Z. Online fault diagnosis in discrete event systems with partially observed Petri nets. Int. J. Control Autom. Syst. 2018, 16, 217–224. [Google Scholar] [CrossRef]
  15. Alves, L.; Pena, P.N. Secure recovery procedure for manufacturing systems using synchronizing automata and supervisory control theory. IEEE Trans. Autom. Sci. Eng. 2022, 19, 486–496. [Google Scholar] [CrossRef]
  16. Zhou, J.Z.; Jin, L.; Wang, X.; Sun, D.F. Resilient UAV traffic congestion control using fluid queuing models. IEEE Trans. Intell. Transp. Syst. 2021, 22, 7561–7572. [Google Scholar] [CrossRef]
  17. Petri, C.A. Kommunikation Mit Automaten. Ph.D. Thesis, University of Bonn, Bonn, Germany, 1962. [Google Scholar]
  18. Brinkrolf, C.; Ochel, L.; Hofestädt, R. VANESA: An open-source hybrid functional Petri net modeling and simulation environment in systems biology. Biosystems 2021, 210, 104531. [Google Scholar] [CrossRef]
  19. van der Aalst, W.; Stahl, C. A Petri Net-Oriented Approach; The MIT Press: Cambridge, MA, USA, 2011. [Google Scholar]
  20. Murata, T. Petri nets: Properties, analysis and applications. Proc. IEEE 1989, 77, 541–580. [Google Scholar] [CrossRef]
  21. Lin, Y.N.; Wang, S.K.; Chiou, G.J.; Yang, C.Y.; Shen, V.R.L.; Juang, T.T.Y.; Huang, T.J. Novel deadlock control for smartphone manufacturing systems using Petri nets. Int. J. Control Autom. Syst. 2022, 20, 877–887. [Google Scholar] [CrossRef]
  22. Gomez, A.; Rodriguez, R.J.; Cambronero, M.E.; Valero, V. Profiling the publish/subscribe paradigm for automated analysis using colored Petri nets. Softw. Syst. Model. 2019, 18, 2973–3003. [Google Scholar] [CrossRef] [Green Version]
  23. Zhang, Y.; Wang, W.; Wu, N.; Qian, C. IoT-enabled real-time production performance analysis and exception diagnosis model. IEEE Trans. Autom. Sci. Eng. 2016, 13, 1318–1332. [Google Scholar] [CrossRef]
  24. Zhang, Y.; Wang, W.; Du, W.; Qian, C.; Yang, H. Coloured Petri net-based active sensing system of real-time and multi-source manufacturing information for smart factory. Int. J. Adv. Manuf. Technol. 2018, 94, 3427–3439. [Google Scholar] [CrossRef]
  25. Guo, Z.; Zhang, Y.; Zhao, X.; Song, X. A timed colored petri net simulation-based self-adaptive collaboration method for production-logistics systems. Appl. Sci. 2017, 7, 235. [Google Scholar] [CrossRef] [Green Version]
  26. Krawczak, M.; Krawczak, M. Basics of Generalized Nets. In Multilayer Neural Networks: A Generalized Net Perspective; Springer: Berlin/Heidelberg, Germany, 2013; pp. 15–30. [Google Scholar]
  27. Andonov, V.; Poryazov, S.; Saranova, E. Generalized Net Model of a Serial Composition of Services with Intuitionistic Fuzzy Estimations of Uncertainty. In Proceedings of the 4th International Conference on Intelligent and Fuzzy Systems (INFUS), Bornova, Turkey, 19–21 July 2022; Kahraman, C., Tolga, A.C., Onar, S.C., Cebi, S., Oztaysi, B., Sari, I.U., Eds.; Volume 504, pp. 616–623. [Google Scholar]
  28. Georgieva, V.; Yovcheva, P.; Sotirova, E.; Mersinkova, Y. Generalized Net Model of Waste from Wastewater plants for Domestic Wastewater Treatment. In Proceedings of the 2022 IEEE 11th International Conference on Intelligent Systems (IS), Warsaw, Poland, 12–14 October 2022; pp. 1–4. [Google Scholar]
  29. Stratiev, D.D.; Stratiev, D.; Atanassov, K. Modelling the Process of Production of Diesel Fuels by the Use of Generalized Nets. Mathematics 2021, 9, 2351. [Google Scholar] [CrossRef]
  30. Andonov, V.; Poryazov, S.; Saranova, E. Generalized Net Model of Overall Telecommunication System with Queuing. In Proceedings of IWIFSGN-2019—Eighteenth International Workshop on Intuitionistic Fuzzy Sets and Generalized Nets, Warsaw, Poland, 24–25 October 2019; Springer: Berlin/Heidelberg, Germany, 2021; pp. 254–279. [Google Scholar] [CrossRef]
  31. Foroozanfar, M.; Doustmohammadi, A.; Nikravesh, S. Exponential stability of Petri net systems. In Proceedings of the 6th International Conference on Electrical Engineering ICEENG 2008, Cairo, Egypt, 27–29 May 2008; Volume 6, pp. 1–9. [Google Scholar]
  32. Xu, Y.; Ma, B. Research on structural liveness determination of conflict-free Petri net. Comput. Eng. 2021, 47, 296–300. [Google Scholar]
  33. Song, H.; Guo, J.; Li, Y. Distributed system conflict checking and resolution based on Petri net. Comput. Eng. Des. 2013, 34, 1351–1355. [Google Scholar]
  34. Zhang, S. Research on Service Conflict Resolution Mechanism in the Integrated IoT Environment. Ph.D. Thesis, Dalian University of Technology, Dalian, China, 2021. [Google Scholar]
  35. Zhang, T. Conflict resolution of process modeling based on extended UML diagram reduction. Comput. Eng. Des. 2012, 33, 3877–3881. [Google Scholar]
  36. Zhao, R.K.; Zhang, J.H.; Wang, X.R.; Zhang, W.M. Solving multiple conflicts of systems with complex technologies based on Petri net and TRIZ. J. Mach. Des. 2020, 37, 29–37. [Google Scholar]
  37. Liu, X. Research on the Resolution Method of Resource Conflicts in Multi-Projects. Ph.D. Thesis, Dalian University of Technology, Dalian, China, 2018. [Google Scholar]
  38. Li, Y.; Wang, Y.; Zhu, G.; Yin, L.; Zhang, H. Fault diagnosis of PLC-based discrete event systems using Petri nets. Meas. Control. 2022, 55, 960–973. [Google Scholar] [CrossRef]
  39. Luan, W.; Qi, L.; Zhao, Z.; Liu, J.; Du, Y. Logic Petri Net Synthesis for Cooperative Systems. IEEE Access 2019, 7, 161937–161948. [Google Scholar] [CrossRef]
  40. Zhong, C.; Chen, C. Protocol description and optimization scheduling for multi-fieldbus integration system. ISA Trans. 2015, 59, 457–470. [Google Scholar] [CrossRef]
  41. Huang, X.; Wang, J.; Qiao, J.; Zheng, L.; Zhang, J.; Wong, R.K. Performance and replica consistency simulation for quorum-based NoSQL system Cassandra. In Proceedings of the 38th International Conference on Application and Theory of Petri Nets and Concurrency (Petri Nets), Zaragoza, Spain, 25–30 June 2017; Volume 10258, pp. 78–98. [Google Scholar]
  42. Huang, X.; Wang, J.; Yu, P.S.; Bai, J.; Zhang, J. An experimental study on tuning the consistency of NoSQL systems. Concurr. Comput. Pract. Exp. 2017, 29, e4129. [Google Scholar] [CrossRef]
Figure 1. The operation mode of a CPS (fusion domain).
Figure 1. The operation mode of a CPS (fusion domain).
Applsci 13 08975 g001
Figure 2. Decision tree and Petri net.
Figure 2. Decision tree and Petri net.
Applsci 13 08975 g002
Figure 3. Overall architecture.
Figure 3. Overall architecture.
Applsci 13 08975 g003
Figure 4. Connectors of PAG200.
Figure 4. Connectors of PAG200.
Applsci 13 08975 g004
Figure 5. Adding mappings in Dview.
Figure 5. Adding mappings in Dview.
Applsci 13 08975 g005
Figure 6. Monitoring and control logic of DMPN.
Figure 6. Monitoring and control logic of DMPN.
Applsci 13 08975 g006
Figure 7. Definition of the working group.
Figure 7. Definition of the working group.
Applsci 13 08975 g007
Figure 8. Operation process.
Figure 8. Operation process.
Applsci 13 08975 g008
Figure 9. The Petri net model of pressing area.
Figure 9. The Petri net model of pressing area.
Applsci 13 08975 g009
Figure 10. The meaning of product codes.
Figure 10. The meaning of product codes.
Applsci 13 08975 g010
Figure 11. Monitoring interface.
Figure 11. Monitoring interface.
Applsci 13 08975 g011
Figure 12. State-transition.
Figure 12. State-transition.
Applsci 13 08975 g012
Table 1. Definition of place.
Table 1. Definition of place.
StateMeaning
p 1 Assembly completion state
p 2 , p 7 , p 10 , p 15 , p 20 , p 23 , p 28 , p 31 , p 36 , p 39 , p 44 One-side sealing completion state
p 3 , p 8 , p 11 , p 16 , p 21 , p 24 , p 29 , p 32 , p 37 , p 40 , p 45 Other-side sealing completion state
p 4 , p 9 , p 12 , p 17 , p 22 , p 25 , p 30 , p 33 , p 38 , p 41 , p 46 Shell-strength completion state
p 5 , p 13 , p 18 , p 26 , p 34 , p 42 Equipment resources
p 6 , p 14 , p 19 , p 27 , p 35 , p 43 Manpower resources
p 47 Low-pressure test completion state
p 48 Qualified state
p 49 Unqualified state
Table 2. Definition of transition.
Table 2. Definition of transition.
TransitionMeaning
t 1 , t 5 , t 9 , t 13 , t 17 , t 21 , t 25 , t 29 , t 33 , t 37 , t 41 One-side sealing test
t 2 , t 6 , t 10 , t 14 , t 18 , t 22 , t 26 , t 30 , t 34 , t 38 , t 42 Other-side sealing test
t 3 , t 7 , t 11 , t 15 , t 19 , t 23 , t 27 , t 31 , t 35 , t 39 , t 43 Shell-strength test
t 4 , t 8 , t 12 , t 16 , t 20 , t 24 , t 28 , t 32 , t 36 , t 40 , t 44 Low-pressure test
t 45 Qualified
t 46 Unqualified
Table 3. Conflicting places.
Table 3. Conflicting places.
Conflict Place p cfl Post-Set of Place p i
p 1 t 1 , t 5 , t 9 , t 13 , t 17 , t 21 , t 25 , t 29 , t 33 , t 37 , t 41
p 47 t 45 , t 46
Table 4. Division of working groups.
Table 4. Division of working groups.
GroupStateAndOperateOperatorMachine
Group1 t 1 , t 2 , t 3 , t 4 , t 5 , t 6 , t 7 , t 8 , p 2 , p 3 , p 4 , p 7 , p 8 , p 9 p 5 p 6
Group2 t 9 , t 10 , t 11 , t 12 , p 10 , p 11 , p 12 p 13 p 14
Group3 t 13 , t 14 , t 15 , t 16 , t 17 , t 18 , t 19 , t 20 , p 15 , p 16 , p 17 , p 18 , p 19 , p 20 p 18 p 19
Group4 t 21 , t 22 , t 23 , t 24 , t 25 , t 26 , t 27 , t 28 , p 23 , p 24 , p 25 , p 28 , p 29 , p 30 p 26 p 27
Group5 t 29 , t 30 , t 31 , t 32 , t 33 , t 34 , t 35 , t 36 , p 31 , p 32 , p 33 , p 36 , p 37 , p 38 p 34 p 35
Group6 t 37 , t 38 , t 39 , t 40 , t 41 , t 42 , t 43 , t 44 , p 39 , p 40 , p 41 , p 44 , p 45 , p 46 p 42 p 43
Table 5. Product type.
Table 5. Product type.
Serial Number123
Product typeIPS socket gate valveItalian gate valveSPS hydrant
ModelDN50DN60DN100
Pressure gradePN10PN10PN16
one-side sealing306060
other-side sealing30600
shell strength3060180
low-pressure test0060
Operating time454545
Total time135225345
Table 6. The sequence of place and transition.
Table 6. The sequence of place and transition.
Product TypeProduct CodePlace and Transition Sequence
IPS socket gate valve001AEGA220514 p 1 t 21 p 23 t 22 p 24 t 23 p 25 t 24 p 47 t 45 p 48
Italian gate valve002AAHA220514 p 1 t 13 p 15 t 14 p 16 t 15 p 17 t 16 p 47 t 45 p 48
SPS hydrant003FBKB220514 p 1 t 1 p 2 t 2 p 3 t 3 p 4 t 4 p 47 t 45 p 48
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Yang, Y.; Liu, X.; Lu, W. A Cyber–Physical Systems-Based Double-Layer Mapping Petri Net Model for Factory Process Flow Control. Appl. Sci. 2023, 13, 8975. https://doi.org/10.3390/app13158975

AMA Style

Yang Y, Liu X, Lu W. A Cyber–Physical Systems-Based Double-Layer Mapping Petri Net Model for Factory Process Flow Control. Applied Sciences. 2023; 13(15):8975. https://doi.org/10.3390/app13158975

Chicago/Turabian Style

Yang, Yuhai, Xiaodong Liu, and Wei Lu. 2023. "A Cyber–Physical Systems-Based Double-Layer Mapping Petri Net Model for Factory Process Flow Control" Applied Sciences 13, no. 15: 8975. https://doi.org/10.3390/app13158975

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop