Manufacturing operational management modeling using interpreted Petri nets

: The dynamics of the interaction between different levels in production system is the study of many research groups to seek a better understanding of the complex nature of such systems to propose an effective and efficiency from rational use of available resources and required inputs. Demand for products increasingly customized by a dynamic and competitive market has reduced considerably the life cycle of such products and flexibility of production processes has become essential for companies. Flexibility is not only one attribute, but a set of attributes that provides the flexibility for production systems. The interactions between the flexible sub-systems are sources of waste and rework, causing high costs in the production process. In this sense, the concept of Lean Manufacturing has promoted a restructuring of some processes of the MES (Manufacturing Execution Systems), responsible for managing the activities of production, integrate data from the ERP (Enterprise Resource Planning) and synchronize production tasks the flow of materials, making them oriented by the demand. One other important aspect in the industrial context is the new future vision promoted by Industry 4.0 paradigm that is envisioned a complete decentralization of control of the production system by autonomous and intelligent devices interconnected by a communication system, that contribute to the global goals of the enterprise. The ANSI/ISA S95 presents a conceptual model that may contribute to the implementation of the industry 4.0 concept. The objective of this study is to present a proposal for modeling of objects in level 3 of the S95 standard using interpreted Petri nets.


Introduction
The evolution of production systems is associated with the development of new automation and information technologies. The application of these new technologies is determinant in the performance of companies to meet the demands of a dynamic and competitive market for products with reduced and increasingly customized life cycles (Nakamoto, 2008). The development of new products through the rational use of resources and inputs requires that concepts as flexibility and agility are intrinsic in all activities developed by the company.
The business model of an industrial company has at least three levels: planning, execution and control. The sequence of production orders is at the planning level. The execution level must receive the production orders and send information about the progress of the works (Vanderlei et al., 2009). The control level or Manufacturing Execution System (MES), responsible for managing production activities, integrate ERP system data and synchronize production tasks with the material flow, making them demand-driven. One of the instances fed by the MES is the planning system whose function is to schedule the production considering what was actually produced and how it was produced, comparing the results with the information of what was planned and, in case of non coincidence, allow the corrective actions (Meyer et al., 2009).
In a real production environment, each company deploys management software that best fits their operational needs. But when there is a need for integrations between different management software or between different applications, they show the difficulties of integrating these systems (Pessoa, 2015). The implementation and integration of factory floor management systems is a complex problem, making it difficult to impose a desired dynamic behavior on indeterminism in relation to the time and sequence of occurrence of system events (Santos, 2000). Modeling according to the company needs, how is not always positive, because during the adaptation of the management software, companies are forced to make structural changes or to redefine processes to fit the standard system modules, being necessary the customization to meet the needs of the company (Grilo et al., 2008).
The objective of the present work is to present a proposal for modeling the objects in level 3 of the ANSI / ISA S95 standard (ISA, 2013) using a methodology of control systems applied in the modeling of control of flexible productive systems (Miyagi, 1996;Santos, 2000;Matsusaki, 2004;Nakamoto et al., 2009;Asato, 2015;Kubo et al., 2016), which results in the modeling in interpreted Petri nets (Peterson, 1981;Reisig, 1985;Murata, 1989).

Flexible productive systems
The foundations of the evolution of the production processes are the new automation technologies integrated by information systems, and the application of these new technologies is determinant in the productive performance of the companies for the development of new products in order to meet the demands of a dynamic and competitive market (Nakamoto, 2008). Flexible Productive Systems are systems that execute multiple processes simultaneously with intense sharing of the same finite set of resources. The greatest challenge is the planning and control that guarantee of process flows and results in production established by production planning (Santos, 2000). Another important aspect is the productivity of Flexible Productive Systems it is related to the efficient use of available resources (Nakamoto et al., 2009;Asato, 2015;Kubo et al., 2016). According to Nakamoto et al. (2009), the imposition of a desired dynamic behavior to the system requires, from the point of view of control a single process, the guarantee of the sequential execution of all the activities of the controlled process, being this sufficient. But when viewed from the perspective of the overall process of the system, that is, when there are multiple processes in execution, the sequencing of process activities is lost for sharing of resources and / or process information. In this context, the simultaneous and parallel execution of the processes generates a high degree of difficulty in the modeling of Flexible Productive Systems behavior, characteristic of a complex system. Complexity is an attribute of the system in which the representation of global behavior is impossible to formulate in a purely sequential, even knowing the individual parts or components of the system (Santos, 2000;Nakamoto, 2008). The ability to identify and distinguish the various types of processes performed by the system, changing operating instructions and physical configurations according to the available resources, are some characteristics necessary for a productive system to be considered flexible (Groover, 2007).

Industry 4.0 -The fourth industrial revolution
The fourth industrial revolution, Industry 4.0, is considered the new paradigm of production. The new technologies must be used to integrate machines and humans into value chains by composing a network of entities located in geographically distributed positions to meet a demand for products of high level of customization (Silva et al., 2015). Industry 4.0 involves the use of intelligent sensors and actuators on the factory floor, creating autonomous entities with a certain degree of freedom to decisions. Devices must provide services and products autonomously (Jay Lee et al., 2014). But in order to use the potential of new technologies in this integrated way, it is necessary to break traditional methods of designing and analyzing control systems and to develop new systems design methodologies (Da Silva et al., 2016). Greater integration between processes allows the acquisition of accurate information that promotes better communication between customers and suppliers. The improvement in the communication between the hierarchical levels is fundamental to improve the performance and results of the company, Figure 1 illustrates the sharing of the information through a database centralized between the hierarchical levels (Brettel et al., 2014).
The control model proposed in this paper contribute to the proposal of industry 4.0 in order to propose an adequate methodology for integrating the management systems with the factory floor based on the ANSI / ISA S95 standard (Harjunkoski et al., 2009;Khedher et al., 2011).  (Brettel et al., 2014).

Modeling tools
The following modeling tools are adopted in this paper: (i) Petri nets (RdP) (Peterson, 1981;Reisig, 1985;Murata, 1989); (ii) Enhanced Mark Flow Graph -E-MFG (Santos, 2000;Miyagi, 1996;Nakamoto, 2008) and (iii) Production Flow Schema -PFS (Miyagi, 1996). The reason for the adoption is the behavior of the MES belongs to the class of Dynamic Systems to Discrete Events (Ho, 1989;Cassandras & Lafortune, 2008), that is, the evolution of the states in this class of system occurs asynchronous from the occurrence of events that because an instantaneous transition of states. The other reason is standards defined by the International Electrotechnical Commission for Programmable Logic Controllers (CLP), as IEC 61163 standardizing hardware and software and IEC 61499 standard that standardizes the functional blocks with a focus on discrete distributed control (Fonseca et al., 2008), allow the integration between the models elaborated in this paper and the control models of the manufacturing processes (Nakamoto, 2008).

Enhanced mark flow graph with communicators
The Mark Flow Graph (MFG) is an interpreted network derived from RdP developed for the modeling and control of systems (Miyagi, 1996). In the process of Productive System modeling, the boxes represent the conditions, operations or tasks associated with the devices and the transitions represent the beginning and end of a process. The dynamic behavior of the system is indicated by the evolution of the marks in the graph according to a predefined trigger rule of the transitions, which correspond to the flow of items, materials and / or information in the real system. The Enhanced Mark Flow Graph (E-MFG) is an evolution of the MFG that allows the manipulation of individual brands with attributes, being able to model and control changes of brands flow and selection of tasks associated with the boxes (Santos, 2000). Matsusaki (2004) proposed the incorporation of communicating elements into the E-MFG, allowing the communication between the E-MFG networks using an industrial network, as illustrate in Figure 2.

ANSI/ISA-S95 standard
The integration of the levels that establish the company's business strategies with the productive system is a fundamental factor so that the company can act in a dynamic and competitive market in an agile way (Nakamoto, 2008). The American National Standards Institute (ANSI) and the ISA (International Society of Automation) created the committee and initiated the ISA95 project to develop the ANSI / ISA95 standard.
• Need to identify the interactions involved; • Need to distinguish between business processes and manufacturing processes; • Need for independence between business systems and manufacturing systems.
The complex integration between ERP, MES and business systems is a challenging problem. This is due to two fundamental factors (Nakamoto, 2008): (i) the amount of information that is acquired, stored, processed and distributed; (ii) and the semantic distinction in the different levels of the productive system. In this sense, the ANSI / ISA S95 standard assists in the development of information management models. The main entities of the production process and flow information exchange between the level of management and the factory floor is represented in Figure 3 (ISA, 2010). The ANSI / ISA S95 standard is a production model system that extrapole the limits of process control and includes operational management and integration with other management systems, defines a hierarchical functional model of activities that applies to the operational manufacturing management and contains several specialized levels with characteristic response times presented in Figure 4 (ISA, 2013).
• Level 0 defines the real physical process; • Level 1 defines the activities involved in the monitoring and manipulation of physical processes, operating typically inside time windows of seconds or even smaller time measurements; • Level 2 defines the activities of monitoring and local control of physical processes, operating inside time windows of minutes, seconds or its divisions. Level 2 typically operates equipment inside a center of work, according to the hierarchy proposed by the norm; • Level 3 defines the activities that perform the progress of process to generate the final products. It includes activities of maintenance of registers and coordination of processes. Level 3 operates typically inside time windows of days, shifts, hours, minutes and seconds; • Level 4 defines the activities of the business, which are necessary to generate the organization of the manufacture. Among the activities described with the manufacturing are the establishment of the main agenda of the plant, determination of inventory levels and the certainty that materials are liberated correctly for the production.

Requirements definition
The Level 3 of the ANSI / ISA S95 standard defines the functional generic model applicable in the manufacturing operational management. It is necessary to detail the conceptual models and define the functional requirements of the manufacturing execution system.

Manufacturing operations management
In the production control model proposed in the Figure 5 by ANSI / ISA S95 standard, which shows the functions and the communications between the blocks. The limits between MES systems and ERP is represented by the dotted line. However, may have variations due to the nature of the product and the process carried out by the company. An important fact to note is that the production schedule is exactly at this border and is dependent on the other typical MES functions. Manufacturing operations management activities are those activities that coordinate personnel, equipment and material in the conversion of raw material into components or finished products and include activities that can be carried out by equipment, human effort or information systems controlled by schedule, use, capacity, definition, history, and resource status. The structure of the model does not reflect an organizational structure of business within a company, but a conceptual model of activities (ISA, 2010). The generic model ( Figure 6) defines a general request-response cycle that starts with requests or schedules, converts them into a detailed schedule, dispatches work according to the detailed schedule, executes the work, collects data, and converts the collected data back into responses (ISA, 2010). Represented in Figure 6 by the dotted line of the activity blocks considered in this article, the model defines a cycle of general requests and responses that is not intended to represent a real implementation of an information system in production. The blocks considered and their activities are: • Detailed production scheduling: Receives the master production program and performs the necessary checks to generate the detailed schedules; • Production dispatching: Receive detailed planning information and send production lists and materials; • Production resource management: Performs the verification of resources, personnel and material; • Production tracking: Receives the production information and updates the databases with production status, this information is used in the detailed planning and to generate performance and capacity indicators, in this work it was considered that these activities are carried out through the MES and ERP; • Production data collection: Performs the data collection of the production, in this work it was considered that this activity is performed by the MES; • Production execution: Sends and receives the operational command responses to the shop floor.
The Product definition activity was not considered because it works with specific engineering information and is atualized directly in the ERP database to consult of others departments. Production analysis was not considered because each company use specific performance indicators.

Production resource management
Production resource management is the collection of activities that manage the information about resources required by production operations. These resources include machines, tools, labor (with specific skill sets), materials, and energy (ISA, 2004). Figure 7 illustrates some of the interfaces to production resource management. Direct control of these resources in order to meet production requirements is performed in other activities, such as production dispatching and production execution. The scope of the production resource management activities may be at a site level, area level, or at work center levels (ISA, 2004).
Information about resources needed for a segment of production must be maintained and provided on the available, committed, and unattainable capacity for specific periods of time of specified resources. The following requeriments are defined in the production resource management: Personnel, Equipment, Material.

Detailed production scheduling
An activity of manufacturing operations includes local planning and scheduling of production and resources. Enterprise-level planning systems often do not have the detailed information required to schedule specific work centers, work center elements, or personnel. Detailed production scheduling is sended by level 4 and takes into account local situations and resource availability (ISA, 2004).
The level 4 is responsible by detailed production scheduling takes the production schedule and determines the optimal use of local resources to meet the schedule requirements. This can include ordering the requests for minimal equipment setup or cleaning, merging requests for optimal use of equipment, and splitting requests when required because of batch sizes or limited production rates. Figure 8 represents the detailed production scheduling activity model interfaces (ISA, 2004).
A detailed production schedule is a collection of production work orders and their sequencing involved in production of one or more products, organized as required for manufacturing. It may define the generation of intermediate material that may not be included as part of higher level scheduling definitions. A detailed production schedule ties physical and/or chemical production steps to specific production equipment or classes of production equipment, with specific starting times or starting events, through production work orders (ISA, 2004). The following requirements are defined in the detailed production schedule activity model: Product Roadmap and Production Status.

Production dispatching
A dispatch list is the set of production work orders that are ready to be executed. They define the specific production activities to be performed at production lines, production units, process cells, or storage zones. Each dispatch list includes the time or event to start the activity that is specified in the detailed production schedule (ISA, 2004).
A dispatch list may take multiple forms; including batch lists, operating directives, line schedules, setup times, or process flow specifications. The dispatch list correlates equipment to detailed production elements and makes this information available to production data collection and production tracking activities. Figure 9 illustrates some of the interfaces to production dispatching (ISA, 2004). The following requirement is defined: Quality.

Production execution
Production execution (Figure 10) is the set of activities that direct the production performance, as specified by the contents of the dispatch list elements. The production execution activity takes care of selecting, starting and moving those units of work (for example lots, sublots, or batches) through the appropriate sequence of operations to physically produce the product. The actual work (manual or automatic) is part of the Level 2 functions (ISA, 2010). The following requirement is defined: Process.

Proposed model control
A PFS control model was proposed for the manufacturing operations management according to ANSI / ISA S95 part 3, presented in Figure 11. The model is defined in the following items: • Production Program: is defined by the production planning and control based on sales and company strategy at level 4; • Check Priority and Optimize: receives the production program and performs the organization by unifying or dividing in lots according to the productive capacity to optimize production and following the priority defined by the PCP; • Requirements Detail: details the production sequence and performs all checks to meet the program; • Check Requirements and Separate Schedules: Performs sequencing of activities by verifying that all requirements for opening the production order are released for use and divides the order into two detailed production and material schedules; • Reprogram Production: If there is a strategic change or any requirement to meet the production program, the model returns to check the priority and optimize; • Send Production Orders: Send two lists, one for the Detail Manufacturing Process with the production schedule to be detailed the specific process information and another for logistics with the detailed schedule of materials and supplies that must be delivered in the units of production. (lots or sublots) in the correct sequence to physically produce the product; • Detailed Manufacturing Process: Receive the detailed production schedule and consult the specific process information for manufacturing the product; • Operational Command: Send and receive the operational commands to meet the production schedule according to the detailed schedule and confirmation of delivery of the materials through the logistics; • Reorder FIFO Priority: Rearranges production orders, if they are unified by the priority schedule, by dividing the quantities produced for the specific production orders and informing the ERP; • Check Priority: If exist any production reschedule, the operational command checks if the priority changed by planning, which can maintain or change the production order; • Logistics: Receives the detailed schedule of production materials to delivery in the correct sequence for production in the correct quantity; • Factory Floor: Execute the production orders according to the standard level 1 and 2 functions.
The exchange of information between the management systems and the shop floor is managed through databases provide technical information of the equipment and processes, product definition management, and a database for production data collection that receives the specific information of the equipment and processes and distributes it to the specific addresses for analysis.
Based on the generic control model ( Figure 11) and requirements mapped on the ANSI / ISA S95 standard, the MFG model of control is presented in Figure 12.  (Guirro, 2017) Following the methodology proposed by Matsusaki (2004), the activities of the processes were detailed through the E-MFG model with communicators, to control the production process with the ISA communication rules and functionalities of the MES and ERP management systems, describing the sequence of production stages to be performed by the manufacturing operations management, represented in Figure 13.
The exchange of information between the MES and ERP is done considering that all the materials released in the systems are approved for quality and ready for use, if there is a history of failure of the material by quality in the databases, the management systems should inform the restriction. It is also considered that the logistics area follows the detailed schedule of materials and supplies without delivery delays in the correct sequence, physically making the material available for production in the correct quantity.

Priority module
The first module receives the production schedule sent by the planning through the ERP system, carries out the organization, unifying or dividing in batches according to the productive capacity, to optimize the production and to execute it following the priority defined by the PCP in Box controller BCT1.
This module is dynamic and may suffer changes of orders, increase or decrease of quantities. This module communicates directly with the detailing of the production program and production execution if there is any abnormality on the shop floor, it should check the priority to verify if there were no changes made by the PCP, in this case it is not necessary detailing production order and the response returns directly to the production execution level.

Detailing module
The priority module sends the optimized production orders to the production detailing module that initiates the requirements checks to open the production order.
The requirements are checked simultaneously in the databases of the management systems, represented in Figure 12, production status is queried in the database of the MES by Box controller BCT2, verifying the products in production, with process started and finalized. The requirement for the availability personnel is consulted in the MES database by the BCT3 Controller Box, verifies if the personnel is available, with no holiday or vacation, quality check if there are quality restrictions for the production of the product in the data from the MES by the Box controller BCT4, availability equipament is check in the database of the MES by Box controller BCT5 if in the period of time requested the equipment will be released without prediction of stops. The production roadmap is consulted in the ERP database by the BCT6 Controller Box, the operations and steps required to produce the product are verified, this information is directly by the engineering sector. Availability of material in the ERP database by BCT7 Controller Box if all materials and components are released for use in the total quantity for order production.
With information on the requirements to open production orders, the Box BCT8 controller, shown in Figure 12, compiles the information of a certain number of orders into the list and makes a decision based on the responses to return to the priority module at the end with status of waiting, or if all requirements are approved and released, two lists are generated, one detailed production and another detailed material. The list of materials is sent to logistics with a detailed delivery schedule of materials that must be made available for production and another list of the detailed production schedule that is sent for the production execution with the description of the product, schedule and equipament that should be manufactured.

Execution module
The production execution module receives the information of the detailing module, the information about the detailed manufacturing process is queried in the ERP database, which is directly by the engineering, and sends the information to a Box BCT9 controller, indicated in Figure 13, which coordinates the sending of the production orders to the equipment on the shop floor to execute the order. During the order-making process, the information is collected by the MES, and the databases with real-time information from the shop floor, this information is received by the BCT10 Controller Box, indicated in Figure 13, which determines if the order was answered in the correct quantity, if negative the MES database is informed that the order is still open and the priority module is consulted; if it does not change the order can return directly to the production execution or wait at the end of the priority module, if the order is met the MES database is informed that the order has been closed, the FIFO recive the parts until they are requested by the ERP.

Conclusions
In this work is proposed for design and modeling of the operational management of the manufacturing, resulting in a modular model based on the functional requirements of activities mapped in the activity models of the strategic levels with the level 3 factory floor of the operational management of the manufacturing, as established by ANSI / ISA S95. For this, a systematic modeling of production planning and control is presented considering the minimum requirements for effective information sharing of production. The resulting model considers the technological evolution of equipment and management systems, which are being widely used by the industry to carry out the control of the factory floor and the strategic variables, allowing greater flexibility to meet the needs of each company and the possibility of integration with the other systems that border ANSI / ISA S95 level 3.