Reducing the Standard Deviation When Integrating Process Planning ...

10 downloads 0 Views 501KB Size Report
Abstract. The main objective of this work is the reduction of the standard deviation generated through the routing of production orders in manufacturing resources ...
Reducing the Standard Deviation When Integrating Process Planning and Production Scheduling Through the Use of Expert Systems in an Agent-based Environment Izabel Cristina Zattar a , Joao Carlos Espindola Ferreira b,1 and Paulo Eduardo de Albuquerque Botura c a b c

Ph.D. Student, Universidade Federal de Santa Catarina, Departamento de Engenharia Mecânica. GRIMA/GRUCON, Brazil. Lecturer, Universidade Federal de Santa Catarina, Departamento de Engenharia Mecânica. GRIMA/GRUCON, Brazil. Undergraduate Student, Universidade Federal de Santa Catarina, Departamento de Engenharia Mecânica. GRIMA/GRUCON, Brazil.

Abstract. The main objective of this work is the reduction of the standard deviation generated through the routing of production orders in manufacturing resources in a job shop environment. This reduction is obtained through the suggestion of the best machining route for each job order in a simulation, based upon historic simulation data (base of facts) and a set of rules. In order to generate these routes, an expert agent and the expert system were developed. This agent is responsible for processing the information and controlling the rule engine, whereas the expert system code is responsible for the rules that will be chosen to be loaded and applied by the agent. Keywords. Multiagent systems, Expert systems, Routing, Scheduling, Manufacturing

1 Introduction In dynamic environments, a great obstacle for the integration between process planning and production scheduling is the lack of flexibility for the analysis of alternative resources during the allocation of the jobs on the shop floor. In this phase the process plan is treated as fixed, that is, scheduling does not consider all the possible manufacturing combinations. According to Shen et al. [1], the integration problem of manufacturing process planning and scheduling becomes even more complex when both process planning and manufacturing scheduling are to be done at the same time. 1

Universidade Federal de Santa Catarina, Departamento de Engenharia Mecânica. GRIMA/GRUCON, Caixa Postal 476, 88040-900, Florianopolis, SC, Brazil. Tel.: +55(48) 3721-9387 extension 212; Fax: +55(48) 3721-7615; E-mail: [email protected]

306

I. C. Zattar, J. C. E. Ferreira and P. E. de A. Botura

In order to solve this problem, it was proposed and developed a multiagent system that enables the use of process plans with on-line alternatives, besides helping real time decision-making about part routes in flexible job shop (functional) layout environments. After implementing the system, a large number of tests were carried out, resulting in a database with more than twelve thousand simulations. By analyzing the results, it was observed that despite shorter makespan and flow times were attained, the standard deviation was high when comparing with other approaches found in the literature. As the problem is significantly complex, involving many parts, resources and alternative plans, an expert agent based on the JESS language (Java Expert System Shell) [2] was implemented which, through the application of rules, filters the information in the database of simulations and provides the system with an adequate suggestion of the route to be executed.

2 Characteristics of the System The developed system is composed by a simulation model [3] developed in the Java language, according to the FIPA standard [4], using the JADE platform for agent development [5], the Eclipse development environment [6], and the MySQL database [7]. Firstly the simulation model generates data related to the makespan, flow time, and queue time, based on the simulation results for sets of pre-determined production orders [8]. These data are stored in a database developed in MySQL. Table 1 shows the 24 types of production orders and the parts that compose them. The expert agent uses the acquired knowledge along these simulations to indicate to the production orders which is the best resource to be hired in the first round of negotiations between parts and resources during the following simulation. A detailed description of the negotiation protocol applied between the agents is given in [3]. The code developed in JESS is an interface between the expert agent, which runs in the Java memory domain, and the expert system and its rules, which in turn runs in the JESS memory domain. In order for a routing suggestion to be generated, initially the user should select the parts to be analyzed, and their respective times to set up (machine and fixturing). Then this information is sent to the expert agent responsible for the interface with the expert system. Based on the chosen parameters, the database is searched for simulations that have similar number of parts, set ups and amounts. In this work the MySQL database located in a local server, but it could be stored anywhere, in a distributed way.

Reducing the Standard Deviation When Integrating Process Planning

307

Table 1. Orders used in the simulation model [8] Orders 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

Parts 1, 2, 3, 10, 11, 12 4, 5, 6, 13, 14, 15 7, 8, 9, 16, 17, 18 1, 4, 7, 10, 13, 16 2, 5, 8, 11, 14, 17 3, 6, 9, 12, 15, 18 1, 4, 8, 12, 15, 17 2, 6, 7, 10, 14, 18 3, 5, 9, 11, 13, 16 1, 2, 3, 5, 6, 10, 11, 12, 15 4, 7, 8, 9, 13, 14, 16, 17, 18 1, 4, 5, 7, 8, 10, 13, 14, 16 2, 3, 6, 9, 11, 12, 15, 17, 18 1, 2, 4, 7, 8, 12, 15, 17, 18 3, 5, 6, 9, 10, 11, 13, 14, 16 1, 2, 3, 4, 5, 6, 10, 11, 12, 13, 14, 15 4, 5, 6, 7, 8, 9, 13, 14, 15, 16, 17, 18 1, 2, 4, 5, 7, 8, 10, 11, 13, 14, 16, 17 2, 3, 5, 6, 8, 9, 11, 12, 14, 15, 17, 18 1, 2, 4, 6, 7, 8, 10, 12, 14, 15, 17, 18 2, 3, 5, 6, 7, 9, 10, 11, 13, 14, 16, 18 2, 3, 4, 5, 6, 8, 9, 10, 11, 12, 13, 14, 16, 17, 18 1, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, 15, 16, 17, 18 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18

2.1 Implementation The structure for entering and recovering information from the expert system code is based on the use of static functions implemented in Java, whereas the rules that are applied and the logic of the expert system were implemented in JESS. In this way, the expert system can be used by the simulation program, and interfacing takes place by including the class that contains the static functions in the Eclipse project. Static functions are portions of code that can be executed without belonging to any instantiated object, and can be run by any object that has access to the class that owns this function. For instance, supposing that there is a class called "Utility", with implemented static functions "Save" and "Send", an object of a given class called "Agent" can execute the functions "Save" and "Send" if the “Utility” class is visible to it. In this work it is necessary that the expert agent executes a static function, passing a vector of simulations as a parameter. The output of this function will be the best simulation result. The criterion for choosing what will be considered as the best simulation is based on a pre-established parameter, such as the shortest makespan for the manufacture of a given group of parts.

308

I. C. Zattar, J. C. E. Ferreira and P. E. de A. Botura

Thereafter the vector of simulations is swept in a programming loop included in the code of the static function, and in this way every selected simulation is added to the memory of the expert agent's active facts. Along this sweep, the enabled rule (or rules) are applied, selecting the best simulation to be considered. It is important to remember that when instantiating a simulation object as a fact in the memory of the expert agent, the object and the fact become two different entities, but with the possibility of one being associated with the other. Also, it is important to note that when instantiating a fact in the JESS memory from a Java object, a pointer is created with which the fact can be recovered. This occurs, because, through such instantiation, a reference to this object is kept as a pointer, and when this fact returns to the Java program, it is possible to recover the agent which it is related to. The expert agent executes a function whose output is the reference to the object that represents the best simulation, and this is supplied by the expert system. Thus, the chosen object Simulation is passed to the Server Agent (described in detail in [3]), which suggests a route for the production orders.

3 Functioning of the System 3.1 Shortest Makespan Rule This rule seeks to suggest the route for a given group of orders through the use of the shortest makespan found in its database of facts. As mentioned previously, for a rule to be implemented, it is necessary to instantiate Java objects as facts in the knowledge base of the expert agent, besides instantiating the Java objects from the facts in the knowledge base of this agent. These two instantiations allow a two-way communication between the Java memory and the JESS memory. Figure 1 shows the shortest makespan rule and its life cycle.

Figure 1. Rule based on the shortest makespan

Reducing the Standard Deviation When Integrating Process Planning

309

Firstly the static function smallerMakespan is executed by the Server Agent, which composes the simulation model developed in the JADE platform [3]. This function is responsible for sending to the Expert Agent the attributes of the simulation that are to be queried, such as the parts, amounts, and set up times. Besides, this function identifies which standard deviation control rule (or rules) should be used among the three that were implemented, namely shortest makespan, shortest flow time, or shortest queue time. After this selection, the Expert Agent loads the selected rules in the JESS memory through the command setRules, beginning to search the database for all the simulations similar to the one that is to be controlled, adding one by one to the JESS memory, instantiating them as facts, through the includeSimulation function. In the JESS memory, the rules defined above are applied to each added fact, selecting the best simulation in each loop called applyRules. After finishing the addition of all the recovered simulations, the best simulation, i.e. the one with the shortest makespan for the requested parameters, is made available in the JESS memory, through the object called bestSimulation. Finally, the Expert Agent executes a function whose output is a reference to the bestSimulation object, which is sent to the Server Agent, and then the JESS memory is cleaned and prepared to the next search. An example of the functioning of the proposed system is given as follows: consider that simulation 11, composed by the production orders related to parts 1, 5 and 7, with machine set up time of 30%, and fixturing set up time of 10%, and batch size equal to one, has makespan equal to 200 minutes. With these same parameters, simulation 15 has makespan equal to 180 minutes. Both simulations are stored in the MySQL database. During the loop of the function includeSimulation, both simulations 11 and 15, and all the other simulations that have similar parameters are recovered from the database and instantiated as facts, but when selecting the simulation that outputs the best makespan, only simulation 15 will return to the Expert Agent. 3.2 Queue Time Rule In this rule the objective is to obtain the simulation where a certain part has the shortest queue time, supposing a scenario in which the user wants to manufacture only a certain part with the smallest possible queue. Although this rule works similarly to the previous one, it is more complex in its implementation. Besides the simulation parameters that the Server Agent should supply to the Expert Agent, it is necessary to send the identification of the part whose queue time one wishes to optimize. This identification is made through its PartID, which is stored in a MySQL database. Figure 2 shows the shortest queue time rule and its life cycle. Then, when the static function bestQueueTime is executed by the Server Agent, beside the attributes of the simulation that one wants to query, the identification of the chosen part is also sent. Thereafter the Expert Agent loads the selected rules into the JESS memory through the command setRules, beginning the search in the database for all the simulations similar to what one wants to control, adding one by one to the JESS memory, instantiating them as facts, through the function includeSimulation.

310

I. C. Zattar, J. C. E. Ferreira and P. E. de A. Botura

At this point, when beginning the sweep of the vector to insert each Simulation object in the JESS memory, the rule includeJobs is fired in order to add all the parts with PartID, besides associating them with each Simulation object in it.

Figure 2. Rule based on the shortest queue time

Up to this point all the orders were stored in the database with all the jobs that compose each of them. Thus, it is necessary to filter only the chosen part PartID to be optimized, and to remove the remaining pieces of information from the JESS memory. That is done through the firing of the rule FilterPartID. Thereafter the best simulation, i.e. the one with the shortest queue time for the requested parameters, will be made available in the JESS memory, through the bestSimulation object. Finally, the Expert Agent executes a function whose output is a reference to the bestSimulation, which is sent to the Server Agent, and then the JESS memory is cleaned and prepared for the next search.

4 Obtained Results The standard deviation decreased significantly in all the groups of parts simulated when compared with the simulations carried out without the routing suggestion in the first negotiation. Table 2 shows the simulation values obtained for a group

Reducing the Standard Deviation When Integrating Process Planning

311

composed by 18 pieces and 15 different resources, with batch size equal to one. Each makespan in this table is a result of 20 replications, with machine set up times varying between 0% and 70%, and fixturing set up time equal to 10%. It is observed that for the machine set up time of 30%, and the fixturing set up time of 10%, the average found for makespan and standard deviation was equal to 527.52 minutes and 15.40 respectively. Table 2. Results without the use of expert system without the shortest makespan rule set up_ 0%_0%

set up_10%_10%

set up_30%_10%

set up_50%_10%

set up_70%_10%

Makespan

534.14

Standard deviation

16.57

Makespan

527.40

Standard deviation

17.74

Makespan

527.52

Standard deviation

15.40

Makespan

531.68

Standard deviation

19.84

Makespan

533.18

Standard deviation

20.28

The same group of 15 parts and 18 resources, with a batch equal to one, was then submitted to the Expert Agent. In order to demonstrate the reliability of the expert system, table 3 shows the results obtained for 5 replications. Table 3. Results with the use of expert system with shortest makespan rule



set up_0%_0%

set up_10%_10%

set up_30%_10%

set up_50%_10% set up_70%_10%

Makespan

Makespan

Makespan

Makespan

Makespan

Replic. 1

501.38

439.59

437.66

439.53

441.25

Replic. 2

501.31

439.62

437.50

467.56

441.25

Replic. 3

501.31

440.59

434.50

440.62

441.25

Replic. 4

505.31

440.59

434.50

439.53

429.25

Replic. 5

505.31

439.78

434.53

444.72

441.25

Mean

502.93

440.03

435.74

448.11

438.85

St. Dev.

2.18

0.51

1.68

13.16

5.37

By analyzing again the group composed by the machine and fixturing set up times of 70% and 10% respectively, it is now observed that the values obtained for the average and standard deviation decrease to 438.85 minutes and 5.37

312

I. C. Zattar, J. C. E. Ferreira and P. E. de A. Botura

respectively. This occurs because the expert agent does not work with the average of the replications of the simulation model, but with the best result obtained for a given set of parameters. The developed system was run on a Pentium IV 1.6 GHz computer, with 1 GB RAM under Microsoft XP operating System.

5 Conclusions This work proposed the integration of an expert system developed in JESS with a simulation model developed in Java, in order to reduce the standard deviation generated during the routing of parts in a job shop manufacturing environment. The model allows the use of a large number of rules, and the increase of its complexity in order to optimize the routing of orders, and the effectiveness of the order sequence is evaluated through the makespan, flow time, and queue time. The optimization degree allowed by the expert system depends mainly on: (a) the amount of available data; (b) the quality of the rules; and (c) how they can reflect the empiric knowledge of the process planners. For future works, in order to improve even more the obtained results, it is intended to add other artificial intelligence tools to the system, such as reinforcement learning and neural networks.

6 References [1] Shen W, Wang L, Hao Q. Agent-Based Distributed Manufacturing Process Planning and Scheduling: A State-of-Art Survey, IEEE Transactions on Systems, Man and Cybernetics – Part C: Applications and Reviews 2006; 36: 563-571. [2] JESS, the Rule Engine for the Java. Available in . Accessed on: Dec. 13th 2007. [3] Zattar IC; Ferrreira JCE; Rodrigues JGGG; Sousa CHB. Integration between Process Planning and Scheduling Using Feature-Based Time-Extended Negotiation Protocols in a Multi-Agent System. To appear in International Journal of Services Operations and Informatics, 2008. [4] Foundation for Intelligent Physical Agents (FIPA) Available at: . Accessed on: Mar. 13th 2007. [5] Jade Administrator’s Guide, 2005. Available in < http://jade.tilab.com/doc/index.html>. Accessed on: Jun. 01th 2007. [6] Eclipse - an open development platform. Available in . Accessed on: Jan. 03th 2008. [7] MySQL. Available in . Accessed on: Dec. 05th 2007. [8] Kim YK, Park K, Ko J. A symbiotic evolutionary algorithm for the integration of process planning and job shop scheduling, Computers & Operations Research 2003; 30:1151-1171.

Suggest Documents