Production planning for agroalimentary laboratories using customer satisfaction criteria

Agroalimentary laboratories typically process samples that require different types of analysis depending on the substance being analyzed and the requirements of the clients. A key parameter for client satisfaction is the time that it takes since the samples arrive at the laboratory facilities and the results are provided to the client. Thus, the order in which the different samples are processed and the analysis are performed can have a significant impact in the overall customer satisfaction. This paper proposes a novel approach for planning the production of agroalimentary laboratories based on maximizing a measure of customer satisfaction derived from this lag between sample reception and analysis finalization. This way, a planning model is defined which, based on the basic version of the Resource-Constrained Project Scheduling Problem, can be used to optimize an objective function that focuses on the client satisfaction, considering the relative relevance of clients and samples. The paper includes a detailed presentation of the parameters, variables and constraints required to define the problem, along with the corresponding modeling assumptions. The applicability of the approach is presented with a discussion of the solutions provided by the optimization problem for a set of scenarios of interest, which show the suitability of the method as a systematic tool for planning the operations of agroalimentary laboratories.


I. INTRODUCTION
Production planning has become a fundamental tool in almost every industry in the last few decades. The increase in the demand and the competition in a global environment [1], [2] are some of the factors that have boosted the adoption of these techniques. One of the most frequently employed tools for implementing this production planning is operational research [3], which has become a fundamental tool in different maganement levels due to the mathematical support that provides [4].
The paradigm that sustains most production planning models found in the literature is that it is possible to store the offered products if that helps to satisfy the client's demand. Traditional planning models try to arrange the future operations of the organizations according to certain economic criteria for a specific planning horizon [5], [6], with the most common economic criterium being the minimization of the total costs associated with the different possible ways to organize the production to satisfy a given demand [7]- [11].
However, papers that deal with the application of production planning techniques to agroalimentary laboratories are very scarce in the literature. Typically, these organizations recieve a set of samples that require different types of analyses, depending on the substance being analyzed and the requirements of the clients. The major difference of an agroalimentary laboratory with a classical industrial setup is the impossibility to store the offered product, since the samples need to arrive to the laboratory facilities before the analysis can begin [12]- [14].
Another aspect that requires some attention is defining what should be optimized when planning the production of an agroalimentary laboratory. As commented before, cost minimization is the traditional objective in most production planning problems, however, customer satisfaction is another aspect that can also be considered. Different optimization models have been recently developed for the tourism industry that especifically take into account the client satisfaction in their objective functions. In [15], the authors develop a model that seeks to provide the optimal path between two points in London depending on the input of the client: the shortest, the most beautiful, the happiest, or the quietest. In turn, [16] proposes an algorithm that provides the optimal path through a set of points of interest (POI) in a city according to the time needed for the transit and the time spent visitting each of the POI. For an agroalimentary laboratory, a metric that directly impacts client satisfaction is the time taken since a sample arrives at the laboratory facilities and the results of the analysis are received by the client.
Unfortunately, the minimization of production costs and the maximization of client satisfaction typically constitute a trade-off, mainly due to the impact on the cost of the analysis batch size, as will be detailed in Section II. In this context, an interesting approach is to optimize the order in which each analysis is performed with the objective of maximizing the aggregated satisfaction of the clients.
Previous research efforts regarding production planning for laboratories have been mostly devoted to medical analysis settings which, although present some similarities with our case, generally deal with samples that all require the same type of analysis [17]. Furthermore, these works are focused on research environments, instead of business environments [18], which allows them to obviate the concept of clients and their satisfaction.
A widely studied problem in the scientific literature is the Resource-Constrained Project Scheduling Problem (RCPSP). An interesting survey can be found in [19], where the authors provide a definition of the problem, along with several variations of it. Essentially, a RCPSP allows to order a series of activities or processes in time, subject to a set of precedence relations and constraints on the resources available to complete the tasks.
The main contribution of this paper is the development of a production planning model for agroalimentary laboratories which, based on the basic version of the RCPSP, can be used to optimize an objective function that focuses on the client satisfaction, instead of economic criteria. The focus on the client satisfaction allows to take into account the relative importance or weight of the clients, so that the optimal solution incorporates these considerations. This way, this paper formalizes the parameters, variables and constraints that define the model so that all the essential features of the operations of an agroalimentary laboratory are included, but the problem remains tractable and interpretable.
The rest of the paper is organized as follows: Section II includes some definitions and the ideas that support the use of the client satisfaction as the main focus of the objective function. Section III presents the definition of the optimization problem, including all the parameters, variables and constraints proposed, along with the objective function. In turn, IV shows the results obtained solving the proposed optimization problem for a set of scenarios, discussing the influence of different parameters and the solution of the problem. Finally, Section V contains the conclusions and the future work lines.

A. DEFINITIONS
In order to clarify some key terms that will be used throughout the paper, it is convenient to include the definition of the following four core concepts: • Sample: a sample is a certain amount of the substance meant to be analyzed, provided by the client, which is used to obtain aliquots of different volume depending on the types of analysis to be performed on the sample. • Aliquot: an aliquot is a part of a sample taken to be analysed, whose chemical and physical properties represent those of the sample. • Analysis: an analysis is a procedure that can be performed on an aliquot of a sample to determine the value of a certain chemical parameter of interest. The different types of analysis (ToA) are the services offered by the organization and constitute the main object of our study. A ToA can be decomposed into a series of processes. • Batch: a batch is a set of aliquots that are analyzed simultaneously, both for cost reduction and quality control considerations. Depending on the particulars of the type of analysis, one or several additional samples need to be included in the batch for quality control purposes. Figure 1 shows the relations between these concepts.

B. ROLE OF CUSTOMER SATISFACTION
As commented in the Introduction, cost minimization and client satisfaction maximization are opposed objectives. For a specific analysis, the economic profit (P ) of the organization can be defined as the product of the number of analyzed samples times the sale price minus the production costs, i.e.: where p represents the sale price of each of the analysed customer samples (s r ), while C denotes the production costs. As commented above, along with the samples provided by the clients, it is usually required to analyze additional samples (s e ) in the batch in order to perform the appropriate quality controls. The number of these additional samples depend on the quality control requirements of the analysis, and not on the number of customer samples to be analysed in the batch. Therefore, it constitutes a cost associated to the batch, and independent of the number of customer samples included in it. This way, the production costs can be decomposed into fixed (C f ) and variable (C v ) costs:  C f can be expressed as the unitary cost of a sample (c) times the number of additional samples required for the batch (s e ) and the number of total batches completed (b). In turn, C v depends exclusively on the unitary sample cost and the number of customer samples being analyzed. Taking this into consideration, Eq. 2 can be rewritten as: The parameters p and c can be regarded as constant through the planning period, while s e is defined by the quality control requirements of the analysis, and s r depends exclusively on the client demand. Therefore, the only parameter that could be used to minimize the production costs would be the number of batches completed (b).
The only way to reduce the amount of batches would be to include as many samples as possible into each batch, which would typically mean withholding the start of the analysis, waiting for more samples to arrive. In the limit, only one batch would be carried out with all the samples, at the expense of the delay in the completion of the analysis and, consequently, the decrease in customer satisfaction.
A simple criterium to overcome this difficulty is establishing that the batches should be completed at a predefined schedule, say, once a day. This fixes also the number of batches to be performed, and, therefore, leaves no room to optimize the cost.
The fact that not all the samples require the same analysis, and that the satisfaction of some clients could be more important than others raises the question of how to plan the batches required to analyze a given set of samples, so that an aggregated measure of customer satisfaction is maximized. This is precisely the question that we address for the rest of this paper.

III. MODEL DEFINITION
As commented in the Introduction, an organization that offers a service that cannot start until the client demands it will always need a certain amount of time to complete the service. This time can be used as a metric for the client dissatisfaction, as it is natural to assume that clients want this time to be as little as possible. Thus, we can define γ t as the total client dissatisfaction for a given time, and use it as the key variable to minimize in the optimal production planning problem.

A. PARAMETERS
The following Sections detail the main elements of the model and their corresponding parameters.

1) Samples
Let M denote the set of cardinality M that contains all the samples to be analysed. Each of these samples has an assigned cost α m , that depends on the relevance of the associated client and possibly other aspects related exclusively to the sample itself, such as a particular interest of the client to have this sample results sooner than other.

2) Processes
Let I denote the set of cardinality I that contains all the processes that make up each analysis. Analogously to the definition of a process in the basic RCPSP, each of these processes is assumed to be an indivisible and uninterruptible part of an analysis. Each of these processes is associated wiht a cost β i , that depends on the relevance assigned by the organization to the related analysis, modeling the perception of clients on delays of different analysis. This way, all the processes that integrate an analysis are assigned the same value of this parameter.
Processes can be classified into two types: regular processes and validation processes. Validation processes are the final processes that check if the quality control is satisfactory VOLUME 4, 2016 and represent the end of the corresponding ToA. In turn, regular processes are the ones that need to be performed before the validation takes place. This difference is modeled using a parameter ν i , with ν i = 1 if the process i is a validation process, and ν i = , with 0 ≤ 1 for regular processes. The reason for this distinction is that the most important processes, from the client satisfaction point of view, are validation processes, as these are the ones that allow the client to obtain the results. If all the processes of a ToA were required to be finished before the validation process, then the ν i could be zero for the regular processes, as minimizing the time when the validation process is completed would also minimize each of the other processes that are required to be completed before it. There are, however, processes that are not strictly required to be finished before the validation process can be performed, such as those related to cleaning the equipment used for the ToA. Therefore, in order to take into account that those processes should not be arbitrarily delayed, we assign a small value of ν i for the regular processes. The scenarios presented in Section IV employ ν i = 0.1 for the computations.
Another parameter related to processes that needs to be defined is δ im , a binary parameter that is 1 if process i is required for sample m, and 0 else. The influence of the parameters defined above can be condensed into a new parameter η i , that represents the resulting dissatisfaction cost of the process, including the relevance of the associated ToA (β i ), the samples that require it (α i and δ im ) and the type of process (ν i ): Finally, each process i requires some amount of time to be completed. These time periods can be divided into fixed (τ fi ) and variable (τ vi ) components. The total time required to complete the process i, denoted τ i can be computed as:

3) Precedence relations
The different processes are subject to temporal constraints according to a set of precedence relations imposed by the analytical procedures. A precedence relation relates a predecessor process i with a successor process k, with k ∈ K and K ≡ I . Three different types of relations are considered [20]: • Strong Finish-Start relationship (SF S ik ): this relation requires that process k is started immediately after process i is finished, not allowing any delay between both processes. • Weak Finish-Start relationship (W F S ik ): this relation requires that process k is started after process i is finished, but allows to have any delay between both processes.
• Start-Start relationship (SS ik ): this relationship requires that processes k and i should be started at the same time.

4) Resources
In this paper the resources needed to perform the processes are considered renewable [21], so that they are completely available once that the processes using them have finished.
We define the set J as the set of all resources, and the binary parameter θ ij to determine whether the process i can employ resource j. Two types of resources are considered: • Human resources: employees of the organization that, according to their training, are allowed to perform some processes or others. • Technical resources: equipment used for specific processes that can be carried out without human intervention.

5) Time intervals
In order to plan the production, we consider a planning horizon divided into a set of discrete time intervals. Let H denote the total length of the planning horizon, Γ the length of the discrete time intervals, T the set of all the discrete time intervals and T the cardinality of the set T , i.e., the total number of time intervals. The choice of the parameter Γ is an important part in the definition of the model, since it represents a trade-off between accuracy in the solution and the computation time. The lower the value of Γ, the greater the time resolution and the more precise the solution, at the expense of a larger computation time. On the other hand, an increase in Γ reduces the computation time, while decreasing the precision of the solution.
The first approach to choose Γ could be to take it as the greatest common divisor (GCD) of all the process times: The use of the GCD guarantees that all the process times τ i can be expressed as an integer multiple of Γ, and would provide the maximum value of Γ that allows to compute the solution with total precision. However, it is likely that the GCD of τ i where 1, which could be too demanding from a computational point of view. An alternative approach that allows to regulate the error of the solution is to define a minimum value for the time intervals κ, and use this value as a basis to define normalized process times τ * i so that they are guaranteed to be integer multiples of κ: This way, the GCD of these normalized times is guaranteed to be a multiple of κ. Therefore, we can select Γ as: Another parameter that has an impact in the solution time is the total number of discrete time instants considered, i.e., the value of T . This value depends on the time required to complete each process (τ * 1 , τ * 2 , . . . , τ * I ) and Γ. The time that would take to complete all the processes is not known a priori, since different processes can be run in parallel. An upper bound of the minimum length of the planning horizon H is easy to obtain, simply assuming that no processes will run in parallel, thus: With this bound, we can obtain a value of T simply dividing H by the length of the discrete time step Γ: This value of T is guaranteed to provide a feasible optimization problem, however, it is very conservative. Since the number of variables in the optimization problem is affected by the choice of T , it is important to try to work with a value of T as low as possible, in order to reduce the number of variables in the problem. Next Section further discusses this point, when the variables of the problem are defined. The additional duration of the processes that the introduction of the minimum value for the time intervals κ conveys, can be analysed introducing a parameter µ, defined as: In a scenario with low numbers of samples and processes, i.e., the sizes of the sets I and M are low, the values of τ i will also be low, as they depend on the number of samples. In this case, a large value of κ would induce large differences between τ i and τ * i , and consequently, a large value of µ. However, if there are not many samples and processes, the total amount of time required to complete all the task should not be high either, and thus H would be small. This way, the choice of a relatively small value of κ would still provide a value of T that is not too high, reducing the need to choose a large value of κ.
On the other hand, if the number of samples and processes is high, yielding larger set sizes for I and M , choosing a relatively large value of κ would induce smaller differences between τ i and τ * i (small µ) , since τ i would be a relatively large number. Section IV-D provides some numerical results and a more detailed discussion of these ideas.
Finally, we can define time slots where there is no availability of the resources as a subset N j ⊂ T . This provides an easy way to model the time schedule of the human resources and possible maintenance schedules of the technical resources. Significant setup times for a technical resource can easily be modeled simply creating a specific process linked via a SFS.

B. VARIABLES
The following three sets of variables are defined for the optimization problem: • Resource variables (r ijt ). r ijt is a binary variable valued 1 if the process i is being done using resource j in the time slot t. • Process start variables (s it ). s it is a binary variable valued 1 if process i has been started before time slot t. • Process end variables (f it ). f it is a binary variable valued 1 if process i has been finished before time slot t.

1) Reduction of T
As commented before, the choice of T assuming that no processes will be carried out simultaneously provides a very conservative value, which results in having a large number of variables that have no practical value for the optimization problem. Indeed, once that all the processes have been finished a time t † , all the variables r ijt will be 0 for t > t † . Therefore, we do not need to define these variables, nor the associated s it and f it . The problem is that t † is not known in advance.
A simple, yet useful, approach to handle this is to leverage the fact that the optimization solver determines very fast if a problem is feasible or not. The idea is to try to solve the problem with increasingly larger subsets of T . A parameter ξ can be defined as: If the value of ξ · T is too small, then the problem will be unfeasible, which is easily detected by the presolver. Then, the value of ξ is increased and the process repeated, until a feasible solution is found. The following pseudocode illustrates the approach: for ξ ∈ {0.1, 0.2, ..., 1} do solution = solve(ξ, rest of data) if not infeasibility error then Solution found end if end for Algorithm 1: Algorithm used to solve the optimization problem using increasingly larger fractions of T .

C. OBJECTIVE FUNCTION
As discussed in previous Sections, the time until the ToA of a sample is completed can be used as a metric of customer dissatisfaction, as commented before. This way, a variable γ t can be defined to represent the total dissatisfaction generated at time t as: where it is easy to see that if a process i has already been completed at time t, i.e., f it = 1, then no dissatisfaction is created. The inclusion of Γ as a factor helps to compare the results obtained in scenarios that employ different values of this parameter. This way, we could express the total dissatisfaction accumulated through the planning horizon as the sum of the dissatisfaction of each time instant: Therefore, since our objective is to maximize client satisfaction, this is equivalent to minimizing client dissatisfaction through the planning horizon. This way, we define the objective function of the optimization problem as:

D. CONSTRAINTS
In order to simplify the set of constraints needed to model the problem, it is assumed that only one resource is needed to perform a process, as it does not pose any loss of generality of the model. If two resources were needed for a process, it is always possible split that process into two and link them by a SS requirement. This way, the first constraint links the resources with the processes that they can perform, leveraging the parameter θ ij . If the resource j cannot perform process i, then all those variables need to be zero at every time instant, and so needs to be their sum: If the resource is allowed to perform the process, then, the sum of all the resources that can perform the process need to be used exactly the amount of time required to complete the process: Using an equality forces that all the process are completed at the end of the planning period, or the solver will raise an unfeasibility error. In order to assure that once that a resource begins a process remains doing it until it is completed, the following constraint is introduced: An additional constraint that is not strictly required to formally pose the problem, but has been empirically found to help reduce the computation time is: This constraint basically states that at any given time, the process cannot be finished and having assigned resources at the same time.
Another required constraint states that a resource can only be used in at most one process at any given time: The basic RCPSP does not allow the interruption of processes, and that is a requirement we also adopt, enforcing it via the following constraints: f it ≤ f i,t+1 , ∀i ∈ I , ∀t ∈ T ; The last constraint links the resource variables with the process start and process end variables. The precedence relations impose constraints between the process start and process end variables. Each of the different type of precedence relations (WFS, SFS and SS) impose a differnt contraint, as detailed below: Finally, the periods of time were a resource is not available due to their schedule or maintenance, can simply be modeled by forcing the sum of the resource variables during all those time instants to be zero: i∈I r ijt = 0, ∀t ∈ N j ; ∀j ∈ J . (27)

IV. RESULTS AND DISCUSSION
This Section presents the solutions to the proposed optimization problem for a set of scenarios that explore different combinations of number of samples, demanded ToA, client profiles, human resources availability and values for the κ parameter. The optimization problem has been implemented in Pyomo [22] using a deterministic model. The problems have been solved using Gurobi [23]. The different scenarios considered represent situations likely to occur in a agroalimentary laboratory, although some of them represent edge cases (A-1, A-4, A-5, A-6, A-7 and B-1) in order to examine the behavior of the model defined in Eq. (28). The problems defined for each scenario are solved independently of each other.

A. PARAMETERS COMMON TO ALL THE SCENARIOS
Six different ToA have been considered, each consisting of several associated processes. Table 1 shows the color assigned to each ToA in the graphical representation of the solution, along with the number of processes for each ToA.   Figure 2 show the precedence relations defined for the different processes. Green arrows represent WFS relations, while red and blue represent SFS and SS relations respectively. Black arrows denote the link with ficticious processes that represent the start and end of the planning. It is possible to include a precedence relation between processes of different ToA, as depicted with process 3 from ToA-1 and process 5 from ToA-2.
The two ToA with the largest amount of processes, ToA-2 and ToA-3, require a large amount of time of technical resources, and this confers them some unique features. In order to represent this classification between types of ToA, we can define a set F including ToA 1, 4, 5 and 6, and a set C including ToA 2 and 3. Let σ denote the ratio between the total amount of ToAs to be performed from set F and those from set C , then this parameter σ provides a way to visualize the relative weight of these two sets in the scenario.
Four different profiles are considered for human resources. The first is the director level (D), responsible for the validation processes and some other high-skill processes. The second profile is senior analyst (MA), who can perform the validation process for some ToA and most of the processes for the rest of anlysis. The third profile is analyst (mA), with authorization to perform regular processes for most ToA. Finally, a profile called assistant analyst is considered (T), who can only execute simpler processes.
The time schedule for the human resources represents a workday with two shifts: from 6 A.M. to 2 P.M. (0 to 480 min) and from 2 P.M. to 10 P.M. (480 a 960 min). In the cases where there are two human resources of the same category working on different shifts, they are modeled as a single resource with an extended schedule.

B. VARIATIONS IN THE NUMBER OF SAMPLES AND CLIENT PROFILE
This Section explores the behavior of the model when the client profile changes, keeping constant both the profile of the ToA demand and the influence of the parameter η i , that assigns the relative weight to each ToA. Table 2 depicts the considered demand profiles, as defined by the parameter σ, and the specific number of samples per ToA considered in each of the demand scenarios employed in the analysis. These profiles correspond to typical situations encountered in the agroalimentary laboratory CM Europa, located in Southern Spain and focused on olive oil analysis, and reflect the variability of the demand depending on the VOLUME 4, 2016 Demand profile ToA-1 ToA-2 ToA-3 ToA-4 ToA-5 ToA-6 F C σ   B  64  10  10  38  38  40  180  20  9  F  90  5  5  80  80  90  340  10  34  C  10  30  20  6  6  8  30  50  0,6  M1  24  5  5  12  10  14  60  10  6  M2  48  10  10  24  20  28  120  20  6  M3  72  15  15  36  30  42  180  30  6   TABLE 2 In turn, the client profile is based on typical distributions found in CM Europa, but shifted to slightly more extreme distributions in order to help to analyse the influence of this factor in the results of the optimization problem. This way, the profile is defined as: Nine different scenarios are considered, combining three profiles of demand with three different client profiles, as included in Table 3. For all these scenarios, two T-types, two mA-type, one MA-type and one D-type human resources are considered. The first two types of resources are modeled as a single one with a longer schedule, spanning both shifts. The minimum time legth κ is set at 15 minutes, having a value of Γ also equal to 15 minutes. Figures 3, 4, 5 and 6 show the solutions obtained for scenarios A-1, A-2, A-3 and A-7, respectively. The number assigned to each process is set either on or below the bar representing it, if there is not enough space. A number in parenthesis denotes the validation processes. The less opaque part of some bars represent the difference between τ * i and τ i for the corresponding process i. Assignment of processes to resources  Assignment of processes to resources Assignment of processes to resources   -6  TR-7  TR-8  TR-9  TR-10  TR-11  TR-12  TR-13   Resources   4  28  30  33  35  37  39  41  42   0  1  10  18  29  32  34  40  43   2  (3) 5  6  8  14  17  20 22 23  27  38 11 (13)  Assignment of processes to resources FIGURE 6. Process and resource allocation through the planning horizon for the optimal solution to scenario A-7.
Regarding the results of the problem for each scenario, the only difference between the first three are some different assignments of resources that carry out some of the regular processes, like processes 17 and 33 in scenarios A-1 and A-2, or processes 20 and 27 in scenarios A-1 and A-3. There are also some alternation in the validation processes 31, 36 and 44 in the three escenarios, due to the fact that these ToA are demanded by the same samples.
Overall, the client profile does not provoke drastic differences in the planning, with the method offering sensible solutions for each scenario. The number of samples in the scenarios dilutes the effect of the client profile, prioritizing the start of ToAs included in set F as soon as possible.
Regarding the influence of the weight of each ToA, we can check that in scenarios A-1 (Fig. 3) and A-3 (Fig. 5), process 14, which is the one that begins ToA-3, is scheduled right at the beginning of the shift, to be able to leverage the autonomy of the technical resources. This does not happen in scenarios A-2 (Fig. 4) and A-7 (Fig. 6), where processes 38 and 27 are scheduled before process 14. In order to gain insight into this behavior, Table 4 shows the ratio between the parameters η i for the relevant processes of the four scenarios that are compared.  We can check that low values in the cost ratio of ToA-3 is enough to provoke that process 14 is started early. Larger values of this ratio, like the ones in scenarios A-2 and A-7, lead to delaying the start of ToA-3.
Several deadtimes can be found between processes carried out by the same human resource; for instance, in scenario A-1 (Fig. 3) this is visible between processes 8 and 43 for the mAtype human resources and processes 28 and 39 for the T-type. These deadtimes arise from the precedence relations between processes. In the first case, the lag between processes 8 and 43 is imposed by the SFS relation linking processes 42 and 43, while the latter is due to the SFS link between processes 29 and 40 and the SS link between processes 40 and 41. These effects are visible also in some other scenarios.
In scenario A-7 (Fig. 6), processes 30 and 35 of ToA-4 and ToA-5, respectively, are performed after the validation process is carried out. This is due to the fact that these processes represent minor processes, such as cleaning of the material, and thus do not block the validation process.
The time gap between processes 12 and 13 seen in the first three scenarios represents the night hours outside the workday of the organization. Process 12 is carried out by an automated technical resource that can work without human intervention, thus being able to work during the night. The corresponding validation process is carried out by the human resource first thing in the morning the next day.

C. NUMBER AND TYPE OF HUMAN RESOURCES
This Section illustrates the different solutions to the planning problem depending on the number and type of human resources, comparing the total value of the objective function Ω, the total time needed to carry out all the processes t † , the minimum ξ employed for the computation and the total time required to solve the optimization problem.
Six different scenarios are considered, all with a similar demand and client profiles to settings B and N of Section IV-B. The number and type of human resources considered is included in Table 5. The entries of the  Assignment of processes to resources  Assignment of processes to resources  Assignment of processes to resources Scenario Ω t † (min) ξ (%) Solver time (s)   B-1  7664895  1935  80  295,35  B-2  6363195  1485  60  82,71  B-3  5428905  930  40  49,57  B-4  4577220  915  40  73,93  B-5  4577220  915  40  88,18  B-6  4443060  915  40  42,97   TABLE 6. Results obtained for the scenarios studying the influence of the number and type of human resources.
As expected, increasing the amount of human resources generally involves reducing the total dissatisfaction (Ω) and the total execution time (t † ). The type of human resource also shows some influence, as can be seen from the comparison of scenarios B-2 and B-3, with Ω ≈ −15% and t † ≈ −38% in B-3 with respect to B-2. The only difference in these scenarios is the change of a T-type to a mA-type human resource, which is allowed to perform a larger number of regular operations. In this case, the key process that explains the difference is process 2 from ToA-1. T-type human resource are not allowed to carry out this process, which provokes that this process is started in the second shift, provoking a delay in the validation and, therefore, a delay in the start of ToA-2, due to the WFS link between processes 3 and 5.
In turn, scenarios B-4 and B-5 show the same values of Ω and t † , despite having a extra T-type human resource in the latter. This behavior is understood when the workload assigned to T-type HR-1 in B-4 is observed. Since this workload is not enough to complete the first shift, the addition of second shift is completely unneccesary.
The influence of the parameter ξ in the computation time can be observed in Table 7. As depicted in the Table, it is usually very advantageous to opt for the iterative procedure of incrementing ξ instead of always opting for ξ = 1, with reductions ranging from around 35% for scenario B-1 to 85% for scenario B-3. The time used by the algorithm to actually solve the optimization problem (ST s ) is typically between 60 and 80% of the total execution time (ST t ), with the rest of the time being used in detecting the unfeasibility of the problem for lower values of ξ.

D. INFLUENCE OF THE PARAMETER κ ON THE SOLUTION
This Section addresses the role of the parameter κ in the solution and its influence on the objective function (Ω), the fraction of additional process time added (µ) and the required computation time.
A total of 15 different scenarios were analyzed, obtained combining 5 values of κ, namely 5, 10, 15, 20 and 30 min, with 3 different demand profiles (M1, M2 and M3). Scenarios M2 and M3 demand 50% and 100% more samples than scenario M1, respectively. All scenarios use a value of σ = 6, the client profile N from Section IV-B, and the human resource profile of scenario B-5 from Section IV-C. The different scenarios are included in Table 8.
C-1 C-6 C-11 10 C-2 C-7 C-12 15 C-3 C-8 C- 13 20 C-4 C-9 C-14 30 C-5 C-10 C-15  Table 9 includes the results obtained for each of the scenarios defined. The first observation is that all the metrics included the table increase along with κ in every demand profile, while the computation time is drastically reduced. Exceptions to this reduction are scenarios C-4 and C-15. The increase in the computation time is due to the larger value of parameter ξ required to solve the problem, which in turn provokes a larger size of the set T .
As commented in Section III-A5, the percentage of error commited due to larger values of κ is reduced when there is a larger sample demand. This effect can be observed in the row corresponding to κ = 15 min for demand profiles M1 and M2. In the first case, the value of t † is around 8% larger than the base case (κ = 5 min), while the latter is only around 6 % larger. Regarding µ, the observation of the rows with equal κ show that this parameter is progressively reduced from M1 to M3.
Finally, the solution time increases with the number of samples included in the model. To illustrate this, the observation of the rows for κ = 10 min shows that the solution for profile M1 was 102.37 s, 119.15 s for M2, and 129.69 s for M3, which are not excessive increases. For the rows for κ = 15 min, the relative difference between the computation times is larger, although the absolute values remain in the same order of magnitude. Overall, influence on the solution time of parameter κ is much larger that the effect of the number of samples. The results depicted in Table 9 show that a value of κ = 10 min offers a good compromise between time resolution for the model and computation time needed to solve the problem, rendering it a good option as the default value of the parameter.

V. CONCLUSIONS
This paper has presented a novel approach for the planning of the operations of an agroalimentary laboratory. A model based on the RCPSP that captures the main features of these operations has been defined and included in an optimization problem to plan the production of an agroalimentary laboratory with the objective of maximizing customer satisfaction. The model has been shown to be useful to determine the order in which the different processes need to be scheduled so that an aggregate measure of customer satisfaction is maximazed, being able to incorporate information on the relative relevance of the different clients and samples. The model can also be used to study the influence of the availabilty of human resources in the customer satisfaction.
The major limitation of the approach is not considering the stochastic nature of the demand, and thus, planning only the production once that the samples have arrived to the facilities. Future research will address this stochastic nature of the demand in a planning horizon spanning longer time periods. The forecast of the demand may influence the decision of carrying out a particular ToA with the current number of samples or wait for some others to arrive, thus influencing the size of the ToA batch and the number of batches completed. These decisions impact both customer satisfaction and the total costs, so their consideration may constitute an interesting generalization of this paper.  -1  560  1080215  -50  1352,19  -6,00  10  C-2  580  1117290  3,432  50  102,37  -92,429  15,20  15  C-3  600  1213020  12,294  40  18,31  -98,646  24,80  20  C-4  760  1251180  15,827  50  24,69  -98,174  37,60  30  C-5  810  1449690  34,204  40  11,33  -99,  JUAN GÓMEZ ORTEGA (M'10) received the degree in electrical engineering and the Ph.D. degree from the University of Seville, Seville, Spain, in 1989 and 1994, respectively. He became a Professor with the University of Jaén, Jaén, Spain, in 2001, where he is currently the Rector. From 1987 to 2001, he was with the Departamento de Ingeniería de Sistemas y Automática, University of Seville, as a Research Assistant, and then as an Assistant Professor and Associate Professor. He has been responsible for several research projects on robotic systems, computer vision applied to fault detection, and automatic assembly, with some of them being directly applied to industry. His current research interests include force control and sensor fusion in robotic manipulators, sensor planning, mobile robot, and education in engineering. He has been serving as a Reviewer for different technical journals.
JAVIER GÁMEZ GARCÍA received the degree in electrical engineering and the Ph.D. degree from the University of Jaén, Jaén, Spain, in 2001 and 2006, respectively.
He was a Visiting Researcher with the Department of Automatic Control, University of Lund, Lund, Sweden, from 2003 to 2004. Since 2005, he has been with the System Engineering and Automation Department, University of Jaén, as an Assistant Professor. He is currently the Director of the Transfer and Entrepreneurship Secretariat with the University of Jaén, and the Research Results Transfer Office. His research interests include force control and sensor fusion in robotic manipulators, engineering education, and automatic control applied to olive oil and production process. He was a recipient of the Formacion de Profesorado Universitario Grant from the Spanish Ministry of Education and Science, in 2002. VOLUME 4, 2016