1 Introduction

Since exotic and hard-to-cut materials such as superalloys, ceramics, composites, semiconductors, and superconductors are found in high-end applications, they have been intensively researched. However, when it comes to machining, such materials are commonly characterised by high toughness, low thermal conductivity, ultra-hardness and high work-hardening behaviour. Therefore, even in rigid CNC bed structures, the machining process of exotic material attains high cutting forces, chatter and vibration [1], frequently compromising accuracy and surface quality [2]. As a solution, electric discharge machining (EDM) has successfully replaced conventional processes to better machine hard-to-cut materials. By definition, EDM consists of a non-conventional process capable of cutting any conductive material with at least 0.01 S/cm [3] by gradually melting particles of the workpiece surface by thermal energy generated by a series of high-frequency discharges [4]. As the name suggests, in wire EDM, a thin and flexible wire plays the role of the electrode, allowing it to cut the workpiece’s surroundings without evaporating unused portions of the rare and expensive exotic material. In the high-speed wire EDM variant (HS-WEDM), the wire can be reused by reciprocating motion and runs with speed up to 12 m/s [5], which improves flushing the debris from the kerf delivering the ability to cut large workpieces with up to 1500 mm with minor forces and vibrations [6].

On the other hand, 6-axis industrial robotic arm (IR) advantages are widely recognised in shaping large and complex workpieces [7]. IRs have many advantages over CNC machines, such as larger working envelopes, 6-axis degrees of freedom, lower price, mechanical reconfigurability, and many more [8]. However, IR machining has been severely constrained by limited payload and lack of stiffness resulting in vibration and poor accuracy while machining hard-to-cut materials [9].

For the reasons above, EDM has recently been suggested as a low force machining technique to be combined into a robot to solve vibration [10]. Therefore, this study aims to design and conduct experimental testing of a robotic high-speed WEDM (HS-WEDM) machining performance under a novel mixed wire control strategy that benefits from the advantages of open and closed-loop methods. The research is organised as follows. Section 2 reviews the state of the art in wire EDM feed control. Section 3 introduces the combined robotic HS-WEDM system design. Section 4 describes the methods and theories supporting the design and control system development. Section 5 describes the experiments, while Sect. 6 discusses the results. Finally, Sect. 7 is the conclusion.

2 Review on wire EDM feed control

Since EDM is found in rigid CNC base, EDM techniques are frequently referred to as force-free [11, 12] or very light cutting process [13], thus avoiding mechanical stresses, chatter and vibrations [14] of convention machining. Nonetheless, several small forces acting on the wire can cause warp and vibrations considered relevant from the perspective of EDM precision [15].

As previously studied, controlling wire tension significantly impacts wire warp and vibration, thus improving accuracy, surface roughness, wire life and process stability [16]. For these reasons, various researchers have proposed wire tension control. Lingling et al. [17] made a significant contribution when they found that electric discharge machining can cause plastic deformation on the wire electrode, configuring the main factor of the non-even wire tension problem, and thus, EDM parameters can be verified separately. In brief, they found that the non-even problem increases with the increase of pulse energy. Also, if the dielectric fluid type is adopted, it will result in different cooling conditions in the positive and negative cutting directions, which will be one of the main factors affecting non-even wire tension. Also, when the workpiece thickness increases, non-even wire tension intensifies. As a solution, they proposed a variable wire speed reciprocating system where the speed in a positive direction—which follows the gravity effect—is reduced to balance the resistance in the negative direction affecting the dielectric flow running against the gravity. Li et al. [18] developed a closed-loop control by introducing a sensor that captures the wire tension used as input for a proportion integration differentiation (PID) control that adjusts the wire tension online by actuating a linear tension slider using a servomotor. Their experiments showed tension stability improved by 50% and surface roughness reduced by 6 μm. Next, Shi et al. [19] proposed a closed-loop control to overcome the non-even wire tension problem when the wire tension becomes inconsistent with time. They found that guide wheels have little effect on non-even phenomena, mainly observed during the no spark period. Wentai et al. [20] proposed a closed-loop control and found that the usual asymmetric design of the HS-WEDM wire-winding mechanism is the main reason for non-even wire tension. Wang et al. [21] proposed a system for micro reciprocating WEDM based on a gravity take-up. However, the system is built in a fixed structure, and open-loop control is found—in a micro-scale context—to be highly dependent on pulse parameters.

Similarly, Li et al. [6] found that better performance and wire rupture avoidance can be achieved by adding two symmetric tension controllers to achieve wire stabilisation while cutting large workpieces. Chen et al. [22] developed a closed-loop PID controller for wire speed and tension. The system monitors the wire tension and speed using a sensor to make adaptive adjustments for the current of a magnetic brake. They found improvements in surface roughness, corner error, kerf width and taper angle compared to traditional wire control. Lastly, a recent study conducted a theoretical review to simulate robotic wire EDM vibration and found EDM capable of avoiding vibration if the pulse frequency is controlled to be kept above the system’s natural frequencies [23].

From the studies above, it is possible to suggest that symmetrically designed systems using a closed-loop control approach can deliver superior results. In this sense, magnetic brakes are suitable for closed-loop control and are not constrained by gravity orientation. Nonetheless, all these studies are performed in rigid bed CNC machine structures, which function in a static and mostly vertical direction for the wire. Hence, closed-loop controls are primarily performed in low-speed EDM, while magnetic clutches in the market struggle to achieve high-speed values. While closed-loop controls deliver admissibility, they often lead to approximate solutions which are not optimal. Conversely, open-loop controls can achieve optimality, whereas the approximated solutions may not be physically admissible [24]. Therefore, despite relevant contributions, they do not offer a direct answer to novel problems that originated from a wire running inside a flexible outer case nor on how to cope with the random orientation of the electrode wire concerning the gravity field once embedded into a 6-axis robot.

3 Development of the flexible robotic HS-wire EDM system

As depicted in Fig. 1, the proposed robotic high-speed wire EDM system is composed of four main systems briefly described.

Fig. 1
figure 1

Robotic EDM wire winding system

3.1 Six-axis robot characterisation and selection

The most common configuration of IRs refers to a serial system of rigid bodies interconnected by joint mechanisms with 6 degrees of freedom (DOF) [25]. With the described configuration, machining IRs can perform programmable trajectories in three-dimensional space while containing arbitrary position and orientation for any object or end-effector [26]. In IRs, the joints can be of a revolute or prismatic type, while the link can be rigid or flexible. The serial IRs have the axis numbered based on the first joint fixed on the base ending on the sixth link, which is free to move in space. Figure 2a depicts the 6-axis principle, while Fig. 2b shows how it is embedded in a typical robot here exemplified with an ABB model IRB2400.

Fig. 2
figure 2

Typical serial six-axis industrial robot for machining processes

The adopted robotic system is composed of an ABB manufacturer’s IRC5 robotic controller moving 6-axis robot IRB120. This robotic system is one of the most miniature ABB models of 3-kg payload, yet able to deliver 0.7 m3 of working envelope [27]. Despite the reduced scale of the robot IRB120, the IRC5 control is precisely the same for the entire range of ABB 6-axis robots. In other words, the strategies developed in this research can be extrapolated to nearly all robot sizes with minimal adjustments considering natural frequencies and accuracy [23]. Lastly, regarding communication, the system provides the option to read and write robot standard variables and customised signals using a modern platform of OPC server communication [28].

3.2 EDM pulse generator

The source of EDM pulses is an experimental pulse generator developed by the Industrial Technology Research Institute (ITRI) in Taiwan, whose variables are acquired through a TCP/IP communication protocol. A customised code is developed using LabVIEW [29], providing integrated capabilities for complete closed-loop control of the pulse generator. Figure 3 depicts the user graphic interface (GUI) portion of the coded control, which refers to the pulse generator and all the captured functions available for the robotic-EDM control.

Fig. 3
figure 3

LabVIEW complete control of experimental ITRI pulse generator

3.3 The reciprocating wire feeder

However, wire characteristics such as elasticity, friction, wear, plastic deformation and thermal expansion can also create tension disturbances. Common problems found in HS-WEDM are wire length variation, sliding between the wire electrode and system pulleys [22] and non-even tension after a particular discharge time [17]. To overcome both usual and new problems, counter measurements are made in the proposed design depicted in Fig. 4.

Fig. 4
figure 4

Reciprocating high-speed wire winding system, where (1) is the winding drum; (2) is the servo motor; (3) are the magnetic clutches; (4) is the travelling unity; (5) is the connection for the flexible shaft outer case; (6) is the synchronous wire pulley; (7) are the tension wire pulleys; and (8) are the reciprocating trigger sensors

The function of the system’s components can be summarised as follows: The servo motor (2) provides both stable and adaptive speed control with wire tension sensing measured by torque feedback as an effect of the wire tension over the winding drum (1). The wire tension is provided by two magnetic clutches (3) being activated according to the reciprocation movement and wire direction. The clutches are of coaxial type assembled with wire pulleys (7) that generate wire tension force according to the torque of the magnetic clutch (3). To avoid slippage and wear between the wire electrode and the wire pulleys (7), the pulleys are manufactured using Inconel 601 and designed to accommodate a complete turn of non-overlapped wire around the pulley in a way that the wire tension constricts the wire towards the pulley (7). Running on linear bearings, the travelling unity (4) supports the magnetic clutches assembled with the wire pulleys (7) while connecting the two flexible shafts’ outer case (5). The synchronous wire pulley (6) is connected to the winding drum (1) main axis using timing belts to move the travelling unity (4) with a threaded rod to wind the wire over the winding drum (1) assuring no wire overlap. Lastly, the chosen servo motor (2) is equipped with a magnetic brake to prevent wire movement during wire reversal. Finally, two inductive sensors (8) are used to detect the approaching end of the wire length to trigger the wire reciprocation.

4 Control principles and configuration of reciprocating high-speed WEDM

The motion of the wire electrode is not trivial. In HS-WEDM, the wire is transported from the upper guide to the lower guide and vice versa at a certain speed while six forces are acting over the wire (Fig. 5).

Fig. 5
figure 5

Acting forces on wire EDM electrode [16]

Preliminary studies of wire vibration adopted the simplified approach of the classical string model and quickly evolved to complex models able to provide a complete explanation for the wire vibration. As a result, Chen et al. [16] proposed a multi-physics coupling model integrating the classic elastic continuum model to include the influence of temperature distribution and electromagnetic field. Thus, undesired wire vibration and controlling wire tension force can be better described by Eq. (1).

$$E\,{I}_{0}\frac{{\partial }^{4}y}{\partial {z}^{4}}- {T}_{f}\frac{{\partial }^{2}y}{\partial {z}^{2}}+\rho S\frac{{\partial }^{2}y}{\partial {t}^{2}}+c\frac{\partial y}{\partial t}={F}_{\left(z,t\right)}$$
(1)

where:

  • y(z, t) is the wire displacement.

  • E is Young’s modulus of the wire.

  • I0 is the second moment of the area.

  • Tf is the wire tension.

  • ρ is the wire mass density.

  • S is the cross-sectional area, and.

  • c is the damping coefficient from the dielectric viscosity.

The sum of the forces F(z,t) will describe the temporal and spatial process forces acting on the wire. Regarding the axial direction, except for the workpiece edges, the force from the discharges is nearly uniform even for thick workpieces in high-speed WEDM [30]. That is why some researchers have suggested that wire speed and workpiece thickness have little effect on the discharge location and wire vibration [31]. Finally, the wire tension Tf is the main opposing force acting to keep the wire straight and ideal. Therefore, the wire tension plays a crucial role in a stable wire motion. For the aforementioned principles, it is crucial to feed the wire electrode under controlled tension and speed.

4.1 Modelling the wire system transfer functions

Figure 6 depicts the control schematics to explain how the system is intended to function.

Fig. 6
figure 6

Schematics of the HS-wire tension control system

First, wire speed and tension values are set using a custom LabVIEW code and user graphic interface (GUI) shown in Fig. 7. The desired wire speed value is sent directly to the servo drive controller set-up to operate in speed mode. In other words, the servo controller in speed mode uses an internal closed-loop control to read and automatically adjust the motor torque to keep the desired wire-speed constant steady state. Therefore, the servomotor torque is adaptive and can be read online from the servo drive feedback current to calculate the wire tension using Eq. (2).

Fig. 7
figure 7

LabVIEW wire tension controller graphic user interface (GUI)

$${T}_{f}= \frac{2T}{D+{D}_{w}}$$
(2)

where:

  • Tf is the current wire tension.

  • T is the servo motor adaptive torque necessary to keep the desired wire-speed constant.

  • D is winding drum diameter, and.

  • Dwis the wire diameter.

The input value is converted into an analogic voltage signal sent to both magnetic clutch controllers following the desired wire tension. However, only one of the two magnetic clutches (4) is turned on according to the wire winding direction, while the other remains off until the wire reciprocation is triggered by the respective inductive sensor (8) and the clutches are powered reversed accordingly. The magnetic clutch controller converts the received analogue voltage signal into a respective current to power the magnetic clutch (4) and transfers the tensile force to the tension wire pulleys (7). Since the magnetic clutch (4) creates resistance to wind the wire, the servo torque rises, reads and is converted using Eq. (2) to depict the wire tension used as a feedback signal to the digital PID control system running within LabVIEW code. By measuring the error from the desired wire tension and the converted torque feedback signal, the PID controller continuously adjusts the voltage signal sent to the clutch controller to supply adjusted current to the magnetic clutch to perform online closed-loop control.

4.2 Modelling the wire system transfer functions

Transfer functions are mathematical models that capture the dynamic relationship between inputs and outputs of a system depicted by polynomial functions. The problem of controlling the tension of a wire electrode running inside of a flexible outer tube configures a dynamic system. Models to describe dynamic systems can be linear or non-linear. The proposed case falls into a non-linear model since it is appropriate to cope with backlash and dynamic friction effects and quantify effects, switches and limiters. Since the interaction between the wire and the outer tube is random, it is impossible to obtain the system behaviour between any two sampling points; thus, the system model is discrete. Finally, for modelling purposes, the system is considered time-invariant. To later improve the accuracy of the data-driven system identification, the order of the transfer function G0(s) needs to be identified. Thus, following the proposed system design, the transfer functions rely on the tension controller, magnetic clutch, servo torque sensor and tension pulley, which will next be characterised.

4.2.1 Magnetic clutch torque

Dissimilar to traditionally used gravity take-up wire tension systems limited to a fixed and vertical orientation, permanent magnetic clutches (PMCs) can work in any orientation and provide many advantages. For the proposed reciprocating wire tensioning system, two characteristics stand up. First, they provide soft starts with zero slip when a pre-set torque is reached. Second, they offer constant torque independent of slip speed up to a specific speed limit. Regarding its control, PMC torque is defined by the intensity of the current input in a nearly linear relationship for a specific speed range and can be controlled very accurately. Lastly, PMCs offer excellent overload and jam protection to avoid wear, thus providing longer life and reliable control [32].

In this experiment, a magnetic clutch model POB-05 from Helistar is adopted. Figure 8 depicts the near-linear relationship of current input versus torque output if the rpm is below 350 rpm. Thus, within the speed range of 0–350 rpm, the relationship between input current and output torque is depicted in Fig. 8.

Fig. 8
figure 8

Input current vs output torque POB-05 Helistar up to 350 rpm

In magnetic clutches, the torque comes from the friction of magnetic powder according to the intensity of the applied current. However, due to the coil inductance effect, it will take time to grow the supplied current from zero to the target value, demanding additional time to get magnetic powder together. The torque response delay for the adopted clutch model was experimentally acquired and found as 0.8 s. Therefore, the first-order process transfer function can be approximated in Eq. (3).

$${G}_{1}\left(s\right)=\frac{{K}_{p1}}{(1+{T}_{p1}s)}\mathrm{exp}({-T}_{d}s)$$
(3)

where:

  • Kp1 = 12.864 (static gain).

  • Tp1 = 0.0011842 (time constant).

  • Td = 0.8 (time delay).

However, in HS-WEDM, the wire performs a reciprocating motion with a speed of up to 12 m/s, which is several times more than usual in WEDM. However, most magnetic clutches’ output torque is no longer linear in such a high-speed magnitude. In fact, in the case of the selected clutch, when above the rpm limit, the model approximates a one-phase decay equation since the torque remains stable with an rpm limit of 350 rpm but decreases exponentially with the increase of rpm above the limit (Fig. 9). Therefore, to control the torque under the usual speeds of HS-WEDM, it is necessary to compensate for the torque lost caused by high rpm with the extra input current. In other words, the torque of the magnetic clutch in HS-WEDM is also a function of wire speed which means it is no longer linear. Therefore, the torque has not only one but two governing equations, while the second-order Eq. (4) expresses the process transfer function necessary for triggering current compensation as a function of the speed input when the rotation is above 350 rpm.

Fig. 9
figure 9

HELISTAR POB-05 torque vs rpm for a constant input current of 0.044 A

$${G}_{2}\left(s\right)=\frac{{K}_{p2}}{(1+{T}_{p2}s)(1+{T}_{p2\prime}s)}$$
(4)

where:

  • Kp2 = 3.5937–5 (static gain).

  • Tp1 = 8.4383 (time constant 1).

  • Tp2 = 0.40425 (time constant 2).

4.2.2 Clutch tension controller

The selected tension controller works by receiving an analogic voltage signal input from 0 to 10 V to convert it into a proportional amount of current supplied to the magnetic clutch. In the case of the selected controller,

$${G}_{3}\left(s\right)=\frac{{K}_{p3}}{(1+{T}_{p3}s)}$$
(5)

where:

  • Kp3 = 0.69398 (static gain).

  • Tp3 = 0.5128 (time constant 1).

4.2.3 Tension pulley

The desired effect of wire tensioning is a conversion of the magnetic clutch resistance torque through the connected tension pulley wheel. The pulley is designed with an auto-centred V-groove of a radius of 49.7 mm. Wear and wire slippage can compromise the control, and thus, the wheel is made of hard alloy Inconel 601, while the groove is dimensioned to accommodate two wire turns to avoid wire slippage. As previously demonstrated, the wire tension originated from the speed difference between the servo motor and tension pulley and can be expressed by Hooke’s law in Eq. (6) [22].

$$T=\frac{SE}{{l}_{0}}{\int }_{0}^{t}\left({v}_{1}-{v}_{2}\right)dt$$
(6)

where:

  • L0 is wire length between the servo motor and tension wheel.

  • v1 is the speed of the servo motor; and.

  • v2 is the speed of the tension pulley.

By following Eq. (6), the transfer function G4(s) of the tension pulley is expressed as a first-order time-delay system in Eq. (7), where \({K}_{p4}\) is, in our case, 1.8 m−1.

$${G}_{4}(s)=\frac{{K}_{p4}}{{(T}_{l}s+1)}$$
(7)

4.2.4 Servo torque sensing

In this research, the wire feed system is designed so that the servo motor plays the role of the wire winding drive and the wire tension sensor. The selected servo motor has 750 W, a rated torque of 2.39 Nm, a maximal speed of 3000 rpm and a maximal current of 3.0 A. The sensing torque response presents a linear relationship with the motor current, as shown in Fig. 10, while the transfer function G5(s) for torque sensing is described by Eq. (8). It is worth noting that this control signal is used after a digital low-pass filter is embedded within the developed LabVIEW code.

Fig. 10
figure 10

Servo motor torque sensing

$${G}_{5}(s)=\frac{{K}_{p5}}{(1+{T}_{p5}s)}$$
(8)

where:

  • Kp = 0.83997 (static gain).

  • Tp5 = 0.39753 (time constant).

Finally, by following the five identified transfer functions, the proposed system can be expressed by the open-loop process transfer function of Eq. (9) as a sixth-order time-delay system. Therefore, the usual trial and error approach for order estimation should ideally accommodate sixth-order models during the data-driven system identification process.

$$\begin{aligned}{G}_{0}\left(s\right)&={G}_{1}(s){G}_{2}(s){G}_{3}(s){G}_{4}(s){G}_{5}(s)\\&=\frac{{K}_{p1}{K}_{p2}{K}_{p3}{K}_{p4}{K}_{p5}}{(1+{T}_{p1}s)(1+{T}_{p2}s)(1+{T}_{p2\prime}s)(1+{T}_{p3}s){(T}_{l}s+1)(1+{T}_{p5}s)}\mathrm{exp}({-T}_{d}s)\end{aligned}$$
(9)

4.3 Data-driven system identification

Controlling the magnetic clutch with the proposed design is not trivial. The main obstacles are (1) the lack of linearity torque response caused by the speed problem, (2) the delay between input current and output torque response and (3) the random dynamic friction between the wire and the outer case whose combination create a complex system to be accurately modelled for a practical process. Thus, this section will first present the model identification to evaluate the model next.

4.3.1 Full-factorial design of experiments with Poisson regression

To overcome the problem of modelling the non-linear clutch torque response, we adopt an extensive design of experiments under the full-factorial approach. As predictors, two controllable factors of current and rpm are adopted, while torque is the response variable whose regression equation we want to find. The fit criteria adopted to select potentially acceptable models was an R-squared fit value above 90% [33]. In brief, higher values of R-squared are desirable since it depicts how much variation within the response is captured by the model. A few attempts modulated the experiments to increase the number of samples to achieve a good fit for the R-squared deviance target. The final parameters and respective levels are shown in Table 1, while Table 2 presents the full-factorial DOE settings of 304 trials (16 × 19 = 304) with their respective findings.

Table 1 Full-factorial DOE variables vs levels
Table 2 Full-factorial variable parameters and torque response

For processing the data, we use Minitab software. First, different approaches were attempted to generate potentially suitable models whose targeted predicted R-squared is found above 90%. Next, for screening the models and selecting the most suitable, the following indicators and criteria were adopted:

  • The adjusted R-squared (RSq) accounts for the number of predictors in the model relative to the number of observations. The RSq is calculated using Eqs. (10) and (11), noting that a higher value with fewer model terms is desirable.

    $$RSq=\frac{\left(n-1\right)}{\left[n-\left(k+1\right)\right]} \left(1-{R}^{2}\right)$$
    (10)

    where:

    • k = the number of estimated predictors in the model.

    • n = the number of the sample data points in \(x\)

    and:

    $${R}^{2}=1-\frac{{\sum }_{i}{\left({y}_{i}-{\widehat{y}}_{i}\right)}^{2}}{{\sum }_{i}{\left({y}_{i}-{\overline{y} }_{i}\right)}^{2}}$$
    (11)

    where:

    • y = the actual value.

    • \(\widehat{y}=\) the predicted value of y

    • \(\overline{y }=\) the mean of \(y\) values.

  • The Akaike information criterion (AIC) is a statistical test that simulates the model performance on a different data set. The AIC is calculated using Eqs. (12) to (13), noting that the most accurate model has the smallest value.

    $$AIC=2k-2\mathrm{ln}(\widehat{L})$$
    (12)

    where:

    • k = number of estimated parameters in the model.

    • \(\widehat{L}\) = maximum value of the likelihood function for the model.

    and:

    $$\widehat{L}\left(\mu ,\sigma |x\right)=\frac{1}{\sqrt{2\pi {\sigma }^{2}}}{e}^{-{\left(x-\mu \right)}^{2}/2{\sigma }^{2}}$$
    (13)

    where:

    • \(\mu =\) the mean.

    • \(\sigma\) = the standard deviation.

    • x = data.

  • The Bayesian information criterion (BIC) is a statistical model fit indicator under the maximum likelihood for the estimation dataset. The BIC is calculated using Eq. (14), while the lowest value depicts the best model.

    $$BIC= k\mathrm{ln}(n)-2\mathrm{ln}(\widehat{L})$$
    (14)

    where:

    • k = the number of estimated predictors in the model.

    • \(\widehat{L}\) = the maximum value of the likelihood function for the model.

    • n = the number of the sample data points in x.

Once the most suitable model was selected, it was reduced to having only statistically significant terms. To this end, the p value, also known as ∂ value, with a threshold of 0.05, is adopted. In other words, a significance ∂ value of 0.05 depicts a 5% risk of assuming a term significance that, in fact, may not exist. Therefore, to reduce the model, an interactive process is performed where the term with the highest p value is individually eliminated one at a time. Finally, the Poisson regression is selected, delivering the best-fitted model. It is worth noting that the Poisson approach is well known as suitable for predicting a dependent input variable (i.e., torque) given one or more independent variables (i.e., current and rpm). As a result, the found regression equation Gr(s) for open-loop torque output is expressed in Eq. (15). In addition, its behaviour is illustrated by a surface plot response for torque output having rpm and current as inputs (Fig. 11).

Fig. 11
figure 11

Surface plot response for torque vs rpm and current

$${G}_{i}\left(s\right)={e}^{(-0.704 \;+ \;9.13\;\boldsymbol{\mathrm{current}} \;- \;0.001076 \;\boldsymbol{\mathrm{rpm}} \;- \;7.78 \;\boldsymbol{\mathrm{current}}^{2})}$$
(15)

4.3.2 Model assessment and validation

Next, different theoretical and experimental steps are taken to evaluate the model. Hence, since the analysed system is a grey box, some behavioural information about the system is known and opens opportunities to analyse better and validate the model.

In Table 3, the model is summarised. The R-squared value was found as 96.38%, which indicates a robust fit with the identification data set. Also, the adjusted R-squared of 95.63% confirms that the reduced model number of predictors relative to the number of observations also performs above the target deviance of 90%. Since AIC and AICc have similar results, it is possible to conclude that the adopted final sample size is large enough when correlated with the model terms. Lastly, the k-fold cross-validation with 30 folds is conducted. Briefly, the k-fold cross-validation method randomly splits the identification dataset into k folds to next adopt k (k − 1) folds to build the model. Meanwhile, the remaining k-fold is used as test data to calculate the mean R-squared deviance finally. As a result of k-fold cross-validation, an R-squared fit of 96.22% is found, satisfying the target of 90% fit.

Table 3 Poisson model summary

In Table 4, as expected due to model reduction, all model predictor terms are found with p values below the 5% risk threshold, thus rejecting the null hypotheses and confirming the high statistical significance of the adopted terms.

Table 4 Model coefficients

According to Fig. 12, it is possible to verify that the residual data points fall closely along the straight fitted distribution line, thus indicating that most of the results are normally distributed, representing a good fit to the data.

Fig. 12
figure 12

Normal probability plot for torque response

As a final set of theoretical tests, we want to verify whether the mean of a dependent torque variable relates to the information provided by the manufacturer regarding the independent variables of rpm and current. To this end, the one-way analysis of variance (ANOVA) is adopted. As shown in Fig. 13, the model torque response for both current (A) and rpm (B) reasonably relates to the magnetic clutch information in Figs. 8 and 9, therefore confirming the expected torque behaviour predicted by the manufacturer for both current (A) and rpm (B) inputs within a 95% confidence level.

Fig. 13
figure 13

One-way ANOVA interval plot of A torque vs current and B torque vs rpm within 95% confidence interval

Lastly, to experimentally verify how well the model fits the system, a second validation set of 304 data points is acquired by modulating the rpm input. In other words, the column of rpm predictor in Table 2 is arbitrarily modulated in steps of 6 rpm in a crescent order from 6 to 1800 rpm. In Fig. 14, both identification data (A) and validation data (B) are plotted for comparison. In brief, while Fig. 14A depicts the model performance above presented with an R-squared fit of 96.38%, Fig. 14B plots the model against the second validation dataset and confirms a robust model performance with an R-squared fit of 96.91%.

Fig. 14
figure 14

Regression model fit plot for A identification and B validation data sets

4.3.3 Tunning the PID controller

Before running the cutting experiment, it is essential to tune the PID controller. However, tunning a PID controller is challenging when disturbances, in this case, associated with wire friction, are unknown. Thus, we adopt the widely accepted autotuning heuristic method from Ziegler and Nichols [34] embedded in LabVIEW to find the optimal PID values. The targeted loop performance is the normal type, which means that a fast response with minor overshoot is expected. Under these settings, the autotuning algorithm identifies the dead time and time constant Tp, which are two parameters in the integral-plus-deadtime model.

To summarise the tunning process, Fig. 15 illustrates the autotuning procedure connecting a relay and an extra feedback signal with the desired setpoint [29], while Eq. (16) depicts the governing equation using Table 5. As a result, the tuned PID values found for our case are proportional gain (Kc) as 28.93, the integral time (Ti) as 0.032 min and the derivative time (Td) as 0.008 min.

Fig. 15
figure 15

The process under PID autotuning control with setpoint relay

Table 5 Tuning formula for normal overshoot PID control
$${G}_{p}(s)=\frac{{e}^{-\tau s}}{{T}_{p}s}$$
(16)

where τ is dead time and \({{\varvec{T}}}_{{\varvec{p}}}\) is the time constant.

5 Wire tension and cutting experiments

In Fig. 16, the experimental apparatus set-up is presented, followed by the chosen workpiece and process parameters summarised in Table 6.

Fig. 16
figure 16

Experimental HS-WEDM robotic cell

Table 6 MEDM process parameters

Once the PID is tuned, two experimental procedures are taken. First, we test the control’s ability to control the wire tension as a speed change response, in other words how the open-loop control performs. The speed change is induced by manual change combined with unavoidable friction disturbances. The friction is mainly generated between the running wire and the internal walls of the flexible outer case, while the disturbances are caused by the robot moving and flexing the outer cases and changing the contact with the wire. Also, this first experiment aims to evaluate how the control recovers the tension when the wire reaches a reciprocation point and its running direction is reversed. Figure 17 presents the results.

Fig. 17
figure 17

Hybrid open-loop and closed-loop tension control under wire-speed change and reciprocation

According to Fig. 17, the experiments started with a tension set point of 3 N and a speed of 1.6 m/s. Next, the speed was manually changed to 1.8 m/s, 2 m/s, 2.3 m/s, 2.5 m/s, and 1.2 m/s, respectively. For each manual speed change, it was verified that the speed responds as quickly as 2 s to reach a steady state with an error lower than 5%. However, it is possible to observe that higher speed sets significantly more disturbances on the speed error, for example, at 2 m/s and 2.3 m/s. Also, it is possible to notice a trend of wire tension increase following the speed increase of approximately 18%.

On the other hand, the control performs well and recovers the tension less than 2 s after the wire reciprocation. However, a significant peak in the tension of nearly 4.5 N is observed. It seems to be caused by the change in dynamic friction being also observed when the speed is manually dropped from 2.5 to 1.2 m/s.

Next, we perform a robotic wire EDM cutting experiment to evaluate the proposed system (Fig. 18).

Fig. 18
figure 18

Process improvement by PID tunning

Figure 18 summarises the state and transition of two critical evaluating conditions when (1) only the open-loop regression model-based control is working and (2) when the PID control is turned on, and the control becomes a combination of open and closed-loop control. It is possible to observe that the open-loop control has difficulties coping with friction disturbances to achieve a steady state for both wire tension and speed. Also, since arc pulses and robot feed decrease, it can imply that the material rate removal (MRR) is low and wire vibration is potentially high. Conversely, once the closed-loop PID control starts, the gap voltage drops significantly, which means that an effective wire tension control overcomes the wire vibration together with the forces repelling the wire, and the wire is kept at an appropriate gap distance from the workpiece. As a result, arcing pulses increase from 4 to 20% while the robot feed grows from 50 to 62%; thus, MRR also increases.

6 Experimental process and cutting results

This section examines the two phases of the cutting experiments with and without the PID combination using widely accepted EDM performance metrics of surface roughness and kerf width. We adopt a non-contact 3D microscope Alicona Infinite Focus equipped with an × 50 magnification lens to perform these analyses.

6.1 Kerf and surface roughness

In Fig. 19, the cut performed by the open-loop regression model-based control is analysed, while Fig. 20 depicts the cutting results when the control combines open loop and closed loop.

Fig. 19
figure 19

Wire EDM cut under open-loop control

Fig. 20
figure 20

Wire EDM cut under combined open-loop and closed-loop control

Figure 19 reveals a stepped surface that repeats a pattern defined by the surface areas a, b, and c. Also, while pattern b has a trend of positive height found from 0 to up 70 μm, the pattern from surface areas a and c have a negative height from 0 to − 50 μm, resulting in a large amplitude of 120 μm. Such behaviour is caused by different wire vibration amplitudes and asymmetric system friction when the wire reciprocates and runs in opposite directions. Hence, as shown in Table 7, the maximal difference for Ra, Rq, and Rz measurements for areas a, b, and c is 27%, 34%, and 38%, respectively. These differences are considered significant and caused by the lack of adaptivity of the open-loop control since the robot is performing in slightly different positions for each cutting area, thus copping with different disturbances along time.

On the other hand, Fig. 20 reviews a remarkable improvement in surface topology for uniformity and roughness. With the combined closed-loop control adjusting the wire tension disturbances, the roughness amplitude is kept from − 20 to 35, which means a maximum of 55 μm and an improvement of 54% compared to the open-loop control results. However, as shown in Table 7, Ra, Rq, and Rz measurements for the improved area d are 2.94 μm, 3.80 μm, and 5.69 μm, which compared to the average values of areas a, b, and c are 3.21 μm, 4.11 μm, and 15.82 μm representing a difference of only 8.4%, 7.5%, and 0.8%, respectively. Therefore, the significant improvement of the combined closed-loop control is to avoid disturbances and stepped areas rather than significant EDM roughness improvement.

Table 7 Wire EDM surface roughness under open-loop control

Lastly, the performance of the open-loop controller is evaluated using kerf width analysis.

According to Fig. 21, it is possible to observe that frictions create vibrations and tension disturbance resulting in significant errors. Since the wire diameter is 300 μm and the spark gap is experimentally found as 11 μm, it is possible to calculate the amplitude of the wire vibration for the smallest kerf dimension (A) and most significant kerf dimension (A′) found as 28 μm and 117 μm, respectively. Thus, the kerf analysis agrees with Fig. 19, where reciprocating patterns identified stepped surfaces.

Fig. 21
figure 21

Kerf width under open-loop control

6.2 Statistical analysis of the hybrid open and closed-loop control performance

Since the ultimate objective of the proposed wire control is to provide a stable and controlled HS-WEDM cutting process, the widely accepted EDM key process indicator of gap voltage is adopted. The principle behind the gap voltage metric is its capability to depict the distance between the wire and the workpiece based on the existing capacitance between the charged wire electrode and the workpiece [35]. To analyse if the process is under statistical control, we adopt the robust six sigma approach to evaluate the potential process capability versus the actual process performance, which in the context of EDM gap voltage control can be summarised as follows.

The potential process capability analysis deals with forecasting the short-term process’s capability to meet the gap voltage specifications through two metrics. First, the process capability index (Cp) is calculated using Eq. (17) to measure how well the process performs the control task if there is no input change, and second, Cpk uses the short-term prediction of the process behaviour in staying centred to the gap voltage specification or drifting out due to a non-centred distribution using Eq. (18) [36].

$${C}_{p}= \frac{\left|USL-LSL\right|}{6\sigma }$$
(17)
$${C}_{pk}=\mathrm{Min}\left[\frac{\left|USL-\overline{x }\right|}{3\sigma }\right]$$
(18)

where.

  • USL = upper specification limit.

  • LSL = lower specification limit.

  • \(\sigma\) = process standard deviation.

  • \(\overline {x}\) = process mean.

Conversely, the actual process performance analysis uses historical rather than a predictive analysis to evaluate the process control and verify how it performs in the long term over time.

The critical difference between short term and long term is given by the standard deviation modified to include the overall average to estimate the long-term variability. Thus, the long-term standard deviation (s) is calculated by summing the differences between the individual data points and their data set’s overall average in Eq. (19).

$$s= \sqrt{\frac{\sum {\left({x}_{i}-\overline{x }\right)}^{2}}{n-1}}$$
(19)

Similarly, the actual process performance is captured through the two metrics of (1) performance index (Pp), which is calculated using Eq. (20) and measures how well the data fit between the gap voltage specification limits without considering centred distribution while the (2) Ppk is the performance centring index calculated as in Eq. (21).

$${P}_{p}= \frac{\left|USL-LSL\right|}{6s}$$
(20)
$${P}_{pk}=Min\left[\frac{\left|USL-\overline{x }\right|}{3s}\right]$$
(21)

To identify which performance indicator of Cp, Cpk, Pp, or Ppk can be used to evaluate the control process performance, it is first necessary to confirm if the process is under control and obey a normal distribution. Therefore, the gap voltage was analysed using individual moving charts.

According to Fig. 22 individual value, the chart accesses the variation between consecutive individual points to reveal a process with a certain degree of instability yet still within the statistical control limits. Similarly, Fig. 22 moving range chart quantifies the total variation as 4.22 V which is not centred and reveals a dominant deviation of 1.292 V above the lower control limit (LCL).

Fig. 22
figure 22

Individual MR chart for gap voltage process parameter

Therefore, since the process is under control, the performance index of Pp and Ppk will be used for comparison only. Next, we evaluate the normality of the data using the Anderson–Darling approach.

According to Fig. 23, since P value is close to 0.010, the data can be considered normal, and thus, the capability can be evaluated using a normal distribution approach.

Fig. 23
figure 23

Normality test of gap-voltage data by Anderson–Darling approach

According to Fig. 24, the first conclusion is that the process is not well centred, so Cp should not be used. Since no external changes are applied to the process, the process is stable only if the Ppk = Cpk. However, since Ppk (0.72) is slightly below Cpk (0.82), the analysts predict a long-term process that is close to stable buts drifts over time. In other words, the actual performance matches the predicted performance but not quite. Furthermore, since the Cpk value is lower than 1, the desired gap voltage tolerance from 26 to 34 V is potentially lower than the actual process variance. Hence, with a Cpk of 0.82, the approximate sigma value is 2.4, which means a process with 98.36% within limits confirmed by a Cp value found with 1.0, which shows a short-term process that needs to be tightly monitored. Lastly, since Cp is different from Cpk, the process is not perfectly centred.

Fig. 24
figure 24

Six-sigma spread process control capability for gap voltage

7 Conclusions

This paper outlines the design and experimental verification of a novel robotic wire electric discharge machining system. To the best of the author’s knowledge, this is the first experimental attempt to combine wire EDM into a robotic system. The specific contributions of this research are summarised as follows:

  • The lack of stiffness and resulting vibrations of industrial robots in hard machining materials is overcome by the innovative combination of robotic and HS-WEDM. Since the cutting results show no evidence that the usual accuracy of wire EDM deteriorates, it can be deduced and verified by experimental results that the EDM forces applied to the robot did not induce harmful robot vibrations.

  • The lack of stiffness and resulting vibrations of industrial robots in hard machining materials is overcome by the innovative combination of robotic and HS-WEDM. Since the cutting results show no evidence that the usual accuracy of wire EDM deteriorates, it can be deduced and verified by experimental results that the EDM forces applied to the robot did not induce harmful robot vibrations.

  • The experimental results demonstrate that industrial robots combined with wire EDM end-effectors can effectively cut exotic hard-to-cut materials if wire tension and vibrations are appropriately controlled. The high-speed reciprocating wire system created in this research effectively controls the reciprocating wire while the robot is free to perform complicated cutting paths.

  • Under the wire EDM combination, machining forces are no longer the main limitation of robotic machining. Instead, the robot payload versus the complicated and inevitably heavy wire winding system becomes the main challenge to be considered while designing the end-effector and specifying the robot size.

  • In the light of the gap voltage variable, the statistical performance approach revealed an acceptable and under-control wire system but resulted in an EDM process that can be optimised for a more narrowed variance. Nevertheless, the causes can not be directly associated with the wiring system alone. Since EDM is a stochastic process, there are many possible causes for gap voltage variance. For instance, the fuzzy system responsible for feeding the robot may also cause such variance in gap voltage. In other words, the statistical analysis can only conclude that the wire tension control suffices in not degrading the process.

  • Since the system control was designed as time-invariant, it does not consider the effects of the wire wear. In other words, despite finding feasibility to control the wire tension and speed, the experiments do not cover the impact on the wire electrode life spam, which potentially originated by (1) natural EDM process slowly wearing the wire electrode along with time or (2) tribology aspects such as increased friction, mechanical wear, or opportunities to lubricate the wire. Such aspects are left for future research.