FUZZY LOGIC CONTROL FOR VARIED INSPECTION

Varied inspection is an on-line dynamic inspection method in which the amount of inspection performed fluctuates, based on production needs. A two-level control architecture of fuzzy controllers was used to perform varied inspection. The research was the application of varied inspection into three manufacturing subsystems: transfer lines, assembly, and disassembly. The results from each simulation showed that varied inspection could be used to meet production cycle aims while reducing manufacturing lead time. Varied inspection was compared with 100 per cent inspection to determine the significance of varied inspection compared with traditional quality control methods.


INTRODUCTION
Recent trends towards Industry 4.0 have led to the development of flexible technologies that are able to improve on traditional manufacturing methods, thus allowing for the production of differentiated products at low cost [1].Mass customisation (MC) aims for the mass production of differentiable products, which researchers suggested could be economically beneficial [2].Flexible technologies aid current manufacturing systems in the production of customised products.Due to the shift from dedicated manufacturing systems -where the same products were mass producedto MC, new quality control techniques needed to be developed to ensure that the customised products would meet customer requirements.
The research outlines the development and implementation of fuzzy logic controllers (FLCs) for the purpose of varied inspection.Varied inspection is an aperiodic inspection scheme in which the amount of inspection performed is varied.A two-level control architecture was used.Lower-level heuristic distributed fuzzy (HDF) controllers were used to reduce inspection by controlling the amount of inspection performed for each inspection station.An upper-level heuristic supervisory fuzzy (HSF) controller was used to measure production outputs such as work-in-process and end production rates to tune each HDF controller so that the production aims were met.The controller configuration was tested against three subsystems: transfer line, assembly, and disassembly.
Previous researchers [3]- [5] stated that these three modules were sufficient to model most manufacturing layouts.Each subsystem was measured for its manufacturing lead time, work-inprocess, and production surplus.Previous research in varied inspection [6], [7] showed that this type of inspection plan could reduce work-in-process and manufacturing lead time for the benefit of the manufacturer, and could be applied to the mass customisation environment, as mass customisation requires flexible inspection tools and methods.
The order of this article is as follows: Section 2 describes the existing research in the field of quality control.Section 3 defines the theory of fuzzy logic and provides manufacturing applications of fuzzy control.Section 4 outlines the previous research and the results of varied inspection performed by the authors.Section 5 discusses the full controller design for the HSF and HDF controllers.Section 6 outlines the parameters used for each simulation of each subsystem, and provides the results.Section 7 discusses each result.Section 8 concludes with the major findings of the results, and provides areas for further research.

BACKGROUND
Research into quality control for mass customisation processes is limited [2].A significant issue relating to quality control for mass customisation was that traditional quality control methods used in dedicated manufacturing systems cannot be used in high variety production.Traditional quality control tools, such as control charts and statistical process control, were used in dedicated manufacturing systems because of the minimal variety of mass-produced parts.Statistical methods could be used to generate trends and characteristics that would then be used to adjust parameters to improve quality.However, traditional quality control tools cannot be used where part variety dominates production.
Recent research is focused on reducing inspection to aid production needs.Frequent inspection impedes production rates [8].Davrajh and Bright [8] developed a method of high inspection frequency without affecting production rates, as inspection was only performed on important areas of the product as prescribed by the customer.Similar research to this was performed by He and Chang [9], where inspection was focused on product key quality characteristics (PKQCs), as these characteristics held the most value in the product.Other previous research [6], [7] showed that a reduction in inspection in a single-station manufacturing cell could reduce work-in-process and manufacturing lead time, where parameters used to reduce inspection were centred on the defect rate.Reduced inspection could also reduce inspection costs; a study performed by White et al. [10] showed that reducing inspection on a fin gripper reduced appraisal costs and production time, as a selection algorithm was only used to inspect the important fin gripper features.
Flexible inspection provides a solution to high variety part inspection; however, the technology is not feasible and is slow.Highly flexible inspection methods such as coordinate measuring machines (CMMs) are highly accurate and reliable; however, their performances are slow, which may drastically slow down production [8], [11].Tuominen [12] stated that CMM sampling inspection increases costs linearly, and therefore 100 per cent inspection would yield the highest appraisal costs, whereas reducing CMM use would reduce appraisal costs.However, the risk of costs involved in allowing parts to pass through without inspection would increase.The advantage of using CMMs is that manufacturers can minimise the costs of adapting inspection systems to changes in the manufacturing plant, which may benefit manufacturers in the future [11], [13], [14].Varied inspection was based on the notion that flexible inspection could be used to provide adequate quality control measures in mass customisation while not hindering production rates.

FUZZY CONTROL THEORY AND APPLICATIONS
Fuzzy logic (FL) refers to the use of 'fuzzy sets' as an alternative to classical Boolean logic.Elements/objects of fuzzy sets have degrees of membership to that set.Fuzzy logic was created by Zadeh in 1965 [15].Fuzzy logic uses imprecision, and categorises elements into fuzzy sets that are described by linguistic variables [16].For example, instead of speed being defined by an exact value, speed could be defined as either 'fast', 'slow', or 'average'.Fuzzy control refers to the control of a system using fuzzy logic [16].Fuzzy logic controllers are nonlinear controllers that can often provide adequate control of complex systems.Fuzzy logic controllers differ from conventional control techniques (such as proportional-integral-derivative and linear quadratic regular) in that fuzzy logic controllers mainly use heuristic approaches, while conventional control uses differential equations [17].Fuzzy control thus does not suffer from any consequences of linearisation, as no system modelling is required [16].
Fuzzy logic has large applications in manufacturing.Due to the large scale and complexity of such systems, FL was favoured, as it could provide adequate control without complex system modelling.
With the implementation of mass customisation, processes become more complex, thus favouring fuzzy logic control to solve imminent problems.Azadegan et al. [18] performed a comprehensive study of fuzzy logic implementation in existing manufacturing applications.Nine major applications were found, as shown below: Major researchers in fuzzy control for production scheduling and complex production are Ioannidis and Tsourveloudis [3]- [5]; Homayouni and Ismail [19]; Homayouni [20]; and Homayouni et al. [21].

VARIED INSPECTION
Varied inspection is an aperiodic inspection method in which the amount of inspection performed changes, based on the state of the manufacturing system and the needs of the manufacturer.Varied inspection refers to the control of the use of inspection systems where controllers make decisions on whether or not to inspect incoming parts.The inspection control system may choose to increase or decrease inspection, based on part quality, work-in-process, manufacturing lead time, bottlenecking, starving, and production requirements.Varied inspection makes use of fuzzy controllers to read inputs and to calculate how much inspection to perform, known as 'inspection intensity'.Previous research [7], [6] showed that varied inspection could be used to reduce work-inprocess and manufacturing lead time respectively.Figures 1 and 2 show the respective results [7], [6].Both results were obtained from simulations of a single-station manufacturing cell.The controllers used for these operations were rudimentary, and could only handle a small amount of input with minimal production layout complexity.However, the results provided insights into how varied inspection can improve production performance, compared with 100 per cent inspection (inspection of every produced part).Varied inspection was implemented using a two-level control architecture.The lower-level controllers, known as heuristic distributed fuzzy (HDF) controllers, performed varied inspection by measuring inputs such as buffer levels, machine states, defect rates, and production surplus.The upper-level controller, known as the heuristic supervisory fuzzy (HSF) controller, performed all adjustments and tuning that the HDF controllers were unable to perform by themselves.HSF controllers were responsible for increasing inspection at the beginning of a cycle, and adjusting inspection of the HDF controllers for better performance.Figure 3 shows the two-level control approach to varied inspection.The fuzzy logic controller design for both HDFs and the HSF was based on the fuzzy controller architecture described by Passino and Yurkovich [17], shown in Figure 4. Upstream and downstream buffer levels were measured for manufacturing lead time and work-inprocess.Machine state was monitored for breakdowns and repairs, as these actions affect part quality.Defect rate (defined as the amount of defective parts per total inspected amount of parts) was used as a measure of the produced part's quality.The production surplus was used to determine the difference in production compared with the desired production rate.The output was inspection intensity, which was defined by the authors as the amount of inspection performed on a part stream.For example, an inspection intensity of 85 per cent for a batch of 100 parts means that 85 parts would be inspected and 15 parts would pass through without inspection.Inspection intensity was done through an independent and identically distributed (IID) module created in MATLAB and described by Naidoo et al. in [6].
Fuzzy logic control makes use of linguistic descriptions for inputs and outputs.The linguistic descriptions provide groupings of an entire input/output space.For example, buffer level inputs can be classified as 'empty' when there are no parts or very few parts in storage.The inputs and output were classified into the linguistic descriptions shown below: B = {empty, almostempty, middle, almostfull, full} MS = {repair, transition, running} Q = {extremelow, moderatelow, average, moderatehigh, extremehigh} PS = {negative, balanced, positive} I = {extremelow, verylow, low, medium, high, veryhigh, extremehigh} where: 'B' is the linguistic term set for the buffer levels; 'MS' is the linguistic term set for the machine state; 'Q' is the linguistic term set for the defect rate; 'PS' is the linguistic term set for the production state; and 'I' is the linguistic term set for the inspection intensity.
The rule-base for the HDF controllers was based on the following general rules:  Keep the inspection intensity higher than the defect rate.


Adjust the inspection intensity to meet demand when part quality is acceptable and buffer levels are neither empty nor full.


Adjust inspection intensity accordingly when buffers are full or empty to mitigate blocking or starving.
The designed FLCs are 'Mamdani' type with rules in the form of Equation 1.
where: X and Y are inputs A and B are linguistic values for X and Y respectively Z is the output C is the linguistic value for the Z output The inputs section of Equation 1 is known as the 'premise', and the output section is known as the 'consequent'.Based on Equation 1, the following control rule (Equation 2) was used to construct the rule-base: IF  , is  () AND  , is  () AND   is  () AND   is  () AND   is where:  , is the upstream buffer level  is the linguistic value for the buffer level (upstream or downstream)  , is the downstream buffer level   is the batch size  is the linguistic value for the batch size   is the defect rate  is the linguistic value for the defect rate   is the production surplus  is the linguistic value for the production surplus   is the inspection intensity  is the linguistic value for the inspection intensity  is the rule number From Equation 2, fifty-six rules were prescribed for the HDF that encompass the control requirements.Membership functions are used to quantify the linguistic values of inputs and outputs.Membership functions quantify the certainty that an input or output belongs to a linguistic value.Trapezoidal membership functions were used.
Fuzzification is the simple task of converting crisp values into fuzzy values through the membership functions.The inference mechanism maps inputs to outputs.To map outputs, the inputs must be combined to provide one singular premise certainty for all appropriate inputs.The 'minimum' operator was used to combine inputs that are related through the 'AND' operator shown in Equation 3. Let * denote the state of the inputs at time t.The certainty of the premise,   'Matching' determines which rules are appropriate for each situation.The rules that are 'on' determine the output membership functions.Matching was done when the certainty of the premise was positive, shown in Equation 4.

𝜇 𝑝𝑟𝑒𝑚𝑖𝑠𝑒 *
( , ,  , ,   ,   ,   ) > 0 The recommended output membership function that is determined when the premise certainty is positive is known as the 'consequent membership function'.Define a fuzzy relation FR (k) with   () consequent membership function, shown in Equation 5.
The aggregation of each implied fuzzy set to determine the output membership functions is done through the 'maximum' operator, shown in Equation 7.
Finally, defuzzification is performed to convert the fuzzy   * (  ) value into a crisp   * value.The centroid method was used for defuzzification, shown in Equation 8.

Heuristic supervisory fuzzy controller design
The HSF controller was based on MISO control.The design of the HSF was performed through the same methodology as the HDF controllers.The tasks of the HSF controllers were to:


Inspect every part at the beginning of every cycle  Adjust the inspection intensity calculated by the HDF controllers to compensate for the desired total work-in-process and end production surplus 100 per cent inspection was performed at the beginning of every cycle, as it ensured that the best realisation of the defect rate was achieved before varied inspection affected the calculation of the defect rate.As an estimation, the first 30 per cent of the part stream would be fully inspected.The second objective involved the feedback loop; the supervisory controller must adjust the inspection intensity of the lower-level distributed controllers to meet target end production rates and workin-process levels.The inputs of the HSF controller are: EPS error   , where:  WIP error   , where: The output of the heuristic supervisory controller was a multiplier variable, 'M', where the inspection intensity that was calculated by the heuristic distributed controllers would be multiplied by M either to increase or to decrease overall inspection for the purpose of meeting WIP or end production needs.The methodology to design the HSF was the same as that for the HDFs, using the same Mamdani-type shown in Equation 1.The linguistic descriptions for the HSF inputs and output are shown below: BS = {initial, cycle} EPS = {negative, balanced, positive} EW = {negative, balanced, positive} M = {lessone, one, moreone, initial} The rule-base was constructed from Equation 11.From the rule-base, seven rules were generated.
IF  is  () AND  is  () AND  is  () THEN  is  () (11) At the beginning of the production, 'M' was set to 'initial' to ensure that the product of  * and   * was much greater than 1.A saturation module was then used to limit the final inspection to 1, thus ensuring 100 per cent inspection at the beginning of the cycle.The following equations (Equations 12 to 15) describe the design of the HSF with similar descriptions and explanations to those of the HDF controllers.
The final inspection,   , performed by the HDF controllers, was the product of  * and   * , shown in Equation 16.

SIMULATION AND RESULTS
MATLAB's SimEvent ® [22] was used for discrete-event simulation and MATLAB's Fuzzy Logic Toolbox ® [23] was used to design and test the controllers.Each fuzzy logic controller was developed in MATLAB M-files.

Simulation assumptions
The following assumptions were used for each simulated module:  Part quality was based on a random Poisson number  Buffer storage did not affect part quality  Inspection was 100 per cent accurate and was performed at a fixed inspection time  Inspected nonconforming parts were removed from the system -there were no reworked parts  Machines did not fail  Production surplus for each machine was generated by a Gaussian distributed random number with a mean of 0 and variance of 0.5 Assumptions about the subsystems were taken from Tsourveloudis [3], and are shown below:


All machines operated at known rates  Initial buffers were infinite sources of raw materials, and consequently the initial machines were never starved  Buffers between adjacent machines had finite capacities  Set-up and transportation times were included in the machining processing times The following parameters were used in the simulation: Note that the simulation time could be any time unit (seconds, minutes, hours) as long as consistency was upheld.Three cases were simulated: the transfer line (Figure 7), assembly module (Figure 8), and disassembly module (Figure 9).Each variable was scaled to be used by each FLC.For example, a full buffer would be represented by a '1', and an empty buffer would be '0'.

Results
The fuzzy control approach was tested against 100 per cent inspection for each case.Due to the membership function of the 'batch size' for the HSF, the controller implemented 100 per cent inspection at the beginning of the simulation and started varied inspection at 563 time units (roughly 30 per cent of the total simulation time).

Test case A: Transfer line
The transfer line simulation produced results similar to the results found by Naidoo et al. [6] because of the similarities of the manufacturing plants.However, Test case A included more inputs that were relevant to production. Figure 10 shows the effect of varied inspection on the end production surplus (EPS).The targeted end production surplus was 0.5 pc/time unit.From the figure, the controlled state overshot the target end production surplus beyond 1000 time units, and continued to increase.The total work-in-process (WIP) remained the same across both simulations, as shown in Figure 11.However, the manufacturing lead time (MLT) significantly decreased through varied inspections, as shown in Figure 12, which was similar to the result obtained by Naidoo et al. in [6].Total MLT Total MLT FLC Total MLT 100% Figures 13,14,and 15 show the results from the assembly module simulation.The end production surplus increased substantially due to varied inspection, as shown in Figure 13.The work-in-process remained relatively lower, compared with the 100 per cent inspection, as shown in Figure 14.As with the transfer line module, the manufacturing lead time drastically decreased when varied inspection was performed, as shown in Figure 15.Total MLT FLC Total MLT 100%

6.2.3
Test case C: Disassembly module Figure 16 shows that the end production surplus for the disassembly module decreased through varied inspection, which was different from the previous two results.The total work-in-process was higher than the 100 per cent inspection method shown in Figure 17.The manufacturing lead time decreased slightly through varied inspection, shown in Figure 18.MLT FLC 100%

DISCUSSION
The results from each test case revealed the following major conclusions:


The end production surplus always changed significantly (either increased or decreased)  There were minimal changes in work-in-process  Manufacturing lead time decreased in all test cases The end production surpluses for the transfer line and assembly modules both increased, while the end production surplus for the disassembly module decreased.This decreased because of the way in which the production surplus was calculated: due to two final buffers at the end of the disassembly module, the end production surplus was calculated as the average of both end buffers.This may have reduced the end production surplus result as a result.
Changes in work-in-process were minimal, with the transfer line having no change in work-in-process for the varied inspection and the 100 per cent inspection.Work-in-process and throughput were related -for throughput to increase, work-in-process must also The results revealed that the work-in-process error mechanism, shown in Equation 10, cannot provide adequate results when aiming for a specific work-in-process mean.The results might suggest that a targeted range work-in-process would be more effective in reducing work-in-process, compared with a single targeted work-in-process value.
The manufacturing lead time decreased, as parts spent less time in production through varied inspection, compared with 100 per cent inspection.This result was expected, as all simulations performed with varied inspection showed a decrease in manufacturing lead time.

CONCLUSION
The research showed that varied inspection could be used to enhance manufacturing performance, and fuzzy control provided a viable control solution to implement varied inspection.Fuzzy control managed to incorporate multiple objectives of lower-level and upper-level control adequately.Results showed improvements in manufacturing lead time, while no significant changes were observed in work-in-process.The full controller design was provided, and assumptions were made for each test case.Combinations of the subsystems could be used for the majority of manufacturing layouts, implying that varied inspection can be used for various production systems -including mass customisation.
One shortfall of the HSF controller was the lack of robustness for reducing work-in-process.Future research should investigate suitable methods for reducing WIP, such as targeted WIP ranges.The HSF would benefit from an optimisation module, such as a genetic algorithm optimisation module, to reshape the HSF membership functions to provide more robustness for user requirements.Further research into varied inspection should combine the subsystems to model more complex manufacturing layouts, such as high-variety environments, and test the performance of varied inspection on these layouts.


Average arrival rate: 1 pc/time unit  Buffer capacities: 10 units  Machining time: 1 time unit  Inspection time: 2 time units  Quality tolerance: 20 per cent, which means that when a part is 20 per cent above or below its mean value, it is a defect  Buffer capacity: 10 pc maximum  Simulation time: 2000 time units

Figure 10 :Figure 11 :Figure 12 :
Figure 10: Transfer line end production surplus comparison (see online version for colour)

Figure 13 :Figure 14 :Figure 15 :
Figure 13: Assembly module end production surplus comparison (see online version for colour)