# Conceiving a Digital Twin for a Flexible Manufacturing System
## 3 Results and Discussion  
After carrying out the steps described in the previous section, which include creating work centers and workstations, inserting the equipment and digital components into the layout facilities module, and creating and releasing manufacturing orders, the DT is fully developed and able to simulate, in real time, all the manufacturing steps performed by the FMS, as shown in Figure 6.  
After the manufacturing order is released and the FMS goes into operation, the DT shows, in a synchronized way, the movement of the pallets on the conveyor, the movement of the robotic arms and respective end-effectors. The status of the CNC machines is updated when they are loaded and in material removal operation. Once the first part is completely produced, the DT begins to update system information such as production rate (units/hour), production cost, queue management, cycle time per workstation, as well as the status of each station (idle or busy). This information is passed on through specific dialog boxes contained in the software and can be accessed locally or remotely, as can be seen in Figure 7.  
With this information, the production control and planning staff have an overview, in real time, of the behavior of the FMS in terms of production levels. Additionally, the maintenance staff can obtain information regarding the operating status of a certain component or equipment. Once the production and simulation of a pilot batch of five parts  
Figure 6: Created DT running real time production simulation. Figure 7: System status report. was completed, cycle time information from each workstation was captured and compared to the cycle times of actual FMS operation, as described in the previous section. These data are shown in Figure 8.  
The results show that the times simulated by the DT are only about 5% higher than the real operating cycle times of the FMS. This is mainly due to the fact that special attention was paid to filling in all the information in the facilities layout module, according to what was actually found. For example, the lengths of the conveyors had a tolerance of less than 2 mm. Once the average of five parts was used, information such as the average speed of the robots, for example, was very close to what was expected by the simulation with the DT. There was also a fast response regarding the information update by the system, showing that the data collected by the sensors are quickly and precisely passed on by the network to update the digital entity. For example, Figure 9 shows the exact moment of queuing, by the pallets, at the lathe station. The arithmetic mean roughness (\(R_{a}\)) obtained in the processed parts was 0.25 \(\upmu\)m, highlighting the excellent surface finish that can be achieved with the proposed level of equipment and automation, in accordance with the tolerance degree of ISO IT2-IT3. Figure 10 shows a manufactured (turned) part at the FMS. The contribution of the created DT consists in providing, in a quick and precise way, important relevant information about the physical entity at the levels of production management as well as maintenance. The architecture used, based on ISO, is efficient and, since a good part of the solution is embedded in the layout, the costs of developing the solution were reduced. With regard to previous research works, the results of this work move one step ahead, since it provides a solution for an FMS (i.e., a manufacturing system with two or more pieces of equipment), as discussed by [PERSON] et al. [36] and [PERSON] [39]. Still, the proposed reference architecture for DTs described here is easier to use due to its lower complexity, compared with proposals presented by [PERSON] et al. [3], for example, and its application may be carried out more easily by companies. Figure 8: FMS manufacturing and DT simulation time. It should be noticed that the objectives achieved in this work are just the initial step towards building a metaverse representing the FMS.