Methods of intelligent protection from asymmetrical conditions in electric networks

Possible cases of non-fulfilment of the requirements of the necessary sensitivity and the selectivity of the existing protection against incomplete-phase and asymmetric modes in the electrical network under conditions of uncertainty of the initial data are determined. The paper considers the issue of intellectualization of protection from asymmetric modes based on theories of fuzzy logic, as well as machine learning models, and offers a structural diagram and an algorithm for the functioning of protection. The results of the synthesis of intelligent protection and an approach to modelling and control for controlled drive systems based on reinforcement learning are presented.


Introduction
The system of three-phase voltages applied in the nodes of the electrical network with complex loads, including the stator windings of synchronous and asynchronous motors used in the auxiliary systems of power plants and substations, their symmetry is violated with an uneven distribution of single-phase loads between phases, as well as in emergency modes in electrical networks. As the boundary state of unbalance, it is possible to show out-of-phase modes due to voltage loss in one of the phases, for example, in the event of a break in one phase of the supply line, fuse blowing in one phase, etc. Because of these and other reasons, the likelihood of the occurrence of incomplete-phase modes at the nodes of the complex load is significantly high and amounts to 40% of all emergency shutdowns of elements of distribution electrical networks (DN) [1].
Research has shown that with a voltage unbalance ratio of 4%, the service life of three-phase asynchronous motors is halved in comparison with the service life in symmetrical mode, and with a current unbalance ratio of 10% or more, the insulation service life of power transformers decreases by 16%. Certain parts of violations occur due to unbalanced currents, which, in addition to the above, are the cause of other undesirable negative effects, such as the occurrence of harmonics of currents and voltages, distortion of current curves, changes in power factor, etc. [2].
The results of scientific research on the analysis of the operation of a node with an asynchronous load [3], carried out when one phase is broken, suggests that, depending on the degree of asymmetry, under conditions of uncertainty in the initial data, non-selective operation of existing protection and false actions of automation are possible. Therefore, to improve the reliability of protection in conditions of asymmetry of currents and voltages, the development of appropriate technical means or measures is a necessary and urgent issue.
In DC distribution grids, distributed generation control issues are greatly simplified. For example, in wind generators with variable rotation speed, for operation on a DC voltage network, the converter can be simplified by reducing its weight and dimensions. But, in practical applications, the motor often shall run at different velocities and, thus, the input voltage is not constant. To achieve variable input voltages, a power electronic converter is used in between the electric motor and the DC link (i.e. the supply voltage which could be a battery or a rectified grid supply). At the same time, voltage is supplied to the motor from the inverter, which is regulated both in magnitude and in frequency. The inverter is powered either through a rectifier from an AC voltage or directly from a DC voltage.
Modern drives also provide smooth start-up with reduced starting currents, which greatly facilitates the operation of the supply network in comparison with traditional starting schemes for asynchronous electric motors. At the same time, in asymmetric modes, for example, in case of failure of one of the phases in the power channel of the electric drive, the problem arises of ensuring the constancy of the electromagnetic torque, in particular for controlled systems based on a permanent magnet synchronous motor (PMSM) [4]. In this case, an effective solution can be the use of an autonomous bridge voltage inverter, which will allow the currents of the remaining phases to be formed so that the electromagnetic torque of the motor is stable. In such a setting, the development of optimal control strategies for voltage converters for controlled drive systems in normal and emergency modes can, among other things, be considered as a variant of protection against asymmetric modes.
The paper deals with the creation and implementation of intelligent protection against asymmetric modes operating on the basis of fuzzy sets and fuzzy logic, as well as machine learning models.
2 Fuzzy-based intelligent protection from asymmetric modes

Block diagram
The device proposed in [3] in its technical essence is an automated system for protection of detection and protection against partial-phase modes in DN, based on the use of digital filters of direct and negative sequence. Devices, which include a supply and an intersection switch, digital filters of current direct and negative sequence, an analog-to-digital converter, a microprocessor and an executive body, in the event of incomplete-phase modes, disconnects the supply and at the same time turns on the intersection switch, which ensures the normal full-phase mode of consumers.
Insufficient reliability and low sensitivity of protection of the motor load against phase failure, as well as overloads from reverse sequence currents, is a disadvantage of this system. These disadvantages are eliminated when a fuzzy controller (FC) is included in the protection device, which, as you know, consists of a fuzzifier, a decision-making mechanism and defuzzifier. The FC output is connected to the input of the executive body. Figure 1 shows a block diagram of the proposed device for protection against an asymmetric mode based on FC. The intelligent system with FC consists of the following elements: current transformers 1-4; current sensors 5-10; analog-to-digital converter -14; switch -15; calculation block ratio of positive and negative sequence currents -16; fuzzy controller -17; fuzzifier -18; decision-making mechanism -19; defuzzifier -20; executive body -21.

Main parameters
The problem of the synthesis of intelligent protection against asymmetric mode in Matlab using modeling using the Fuzzy Logic Toolbox [5][6][7][8] is considered. The output linguistic variable is "Asymmetry" and the linguistic output parameters are "Delay" and "Control". The obtained membership functions (MF) of the terms of the linguistic variables input and output of the FC as a result of modeling are shown in Fig. 2 Fig. 4 shows a block diagram of the FC synthesized on the basis of simulation modeling. As can be seen, to ensure the operation of FC with one input and two outputs according to the Mamdani algorithm, a logical inference mechanism with fuzzy rules is obtained. This mechanism is structured as follows. Using a simple fuzzy linguistic model, it is possible to synthesize an FC with one input and two outputs where , are state variables, respectively, is a control parameter; А, В, and C -linguistic values (terms) of variables X, Y and Z on universal sets and , that is , and .

Fig. 4. Structural diagram of АС
In accordance with the above, the FC functioning algorithm is expressed as follows: The term-subsets of the linguistic variable "Asymmetry" is described as The term-subsets of the linguistic variable "Delay" is described as The term-subsets of the linguistic variable "Control" is described as respectively, the MF of term-subsets of linguistic variables , , L QS and D , which are defined in the unversimums , Table 1 shows the forms and parameters of the terms of linguistic variables. As can be seen from (2), the fuzzy linguistic model consists of five simple implications and the general fuzzy relationship R can be defined by combining the fuzzy relations In this case R, the FP of fuzzy relations is determined as follows: For defuzzification, you can apply the centroid method [4][5][6][7]: where n-the number of output quantization level.

Simulation results
On the basis of the above algorithm, computer modeling calculations of the proposed intelligent protection against asymmetric mode based on FC have been carried out. For this purpose, a Simuling-model of protection is built and is shown in Fig. 5, which consists of an FC (rm), an executive body (subsystem) and recording measuring devices. In Fig. 6 The input fuzzy parameter "Asymmetry" is expressed as , and the numerical values are obtained using the simulation of the Monte Karlo method and are graphically presented in Fig.7. As can be seen from Fig.  7, a, the value of the variable changes in the interval . In this case, the obtained values for the variable "Delay" using the Simuling-model are generated on the interval . For various values of "Asymmetry", the diagram of the protection system is shown in Fig. 7, b. As you can see from these figure, the FC does not make any decisions with the aim of disconnecting the circuit to an unbalance value of 0,2. But when the unbalance value exceeds 0.2, the FC generates a control signal to turn off the circuit with a delay of 2 seconds. For another case, the diagram of the system is shown in Fig. 8. As can be seen for different levels of asymmetry, the NC makes a similar decision.   FC it generates a control action to disconnect the circuit and is triggered almost instantly.

Technical background
Some asymmetric conditions, caused phase imbalances, phase rotation faults and open phasing, are associated with AC motors. But if a DC motor is powered by a DC converter, this controller protects the motor from these conditions. However, these converters present an enhanced fault tolerance capability, but an open-circuit fault can leads to ripple beyond load requirements. Поэтому разработка новых средств моделирования и управления DC converters позволяет фактически реализовать эффективную защиту и надѐжную работу DC motors. The paper also is shown the example of using an intelligent controller example based on the deep deterministic policy gradient algorithm (DDPG), which controls a three-phase permanent magnet synchronous motor (PMSM) is presented and compared to a cascaded PI-controller as a baseline for future research [9]. The circuit diagram of the phases for PMSM is similar to each other and the armature circuit of the externally excited motor (Figure 12) [10]. In practical applications, power electronic converters are used in between the motor and a DC link to provide a variable input voltage. Various converters provide different output voltage and current ranges, which affect the control behavior, which can include in the simulation as well as a mechanical load model. Usually, the motor often shall run at different velocities and, thus, the input voltage is not constant. Typical controllers provide either a desired output voltage or a duty cycle in a normalized form. This continuous value needs to be mapped to a switching pattern over time.
A novel approach is to use reinforcement learning (RL) to have an agent learn electric drive control from scratch merely by interacting with a suitable control environment. The controller acts as DDPG-agent and an environment includes the motor model and the reference trajectories. The DDPG-agent receives a reward depending on how close the motor is following its reference trajectory. We used RL-based motor environment, developed in [9], which simulate combinations of converter, electric motor and load, depicted in Fig. 12.   Fig. 12. Scheme of converter, motor, load and control flow from an action to a new observation The control action at is converted to an input voltage of the motor. Then, the next state is calculated using an ODE solver, according ODE system for PMSM (eq.9).
where and are d-axis and q-axis currents/voltages for rotor fixed coordinates d and q; is torque produced by the motor; is torque from the load; is permanent linked rotor flux; is moment of inertia; is stator resistance; are d-axis and a-axis inductance; is the mechanical angle. A PMSM may have more than one pole pair, thus . In this case the electrical angular velocity is . This solver uses the motors differential equations including the load torque (eq.10). (10) with a constant load torque a, viscous friction coefficient b and aerodynamic load torque coefficient c. These parameters as well as a moment of inertia of the load can be freely defined by the user to simulate different loads.
Afterwards, the reward is calculated based on the current state and current reference . If a state exceeds the specified safety limits, the limit observer stops the episode and the lowest possible reward is returned to the agent to punish the limit violation.

Limit observation and motor damage protection
The typical operation range of electric motors is limited by the nominal values of each variable. However, the technical limits of the electric motor are larger. Those limits must not be exceeded to prevent motor damage, which might be inflicted due to excessive heat generation. Motors are stopped if limits are violated in real applications, including in the event of dangerous situations due to asymmetric modes in the converter. For safety agent training, we can specify the nominal values and safety margin (11) An important task for the control is to hold those limits. Consequently, learning episodes will be terminated if limits are violated as in real applications, and a penalty term can be chosen that is affecting the final reward to account for those cases.

Test example
In this example, we used the proposed approach to train a DDPG-agent using the open-source Python package [10]. The agent learns to control the current of a PMSM with a continuous action space. Motor and load parameters are compiled in Tab. 2. The reward function is the shifted weighted sum of absolute error with reward weight 1 on the current i and 0 otherwise. The training consists of 75000 simulation steps partitioned in episodes of length 1000.
The testing process is depicted in Fig. 13. At the beginning, the MAE is 229.15 and decreases to 83.04 at 75 000 steps. The control behavior during the training and afterwards is visualized in Fig. 1. The agent does perform well. This shows that the RL control approach for electric motors reaches control quality similar to a state-of-the-art controller, and that RL is a highly promising approach for electric motor control. The control quality of the DDPG-agent might be improved with an optimization of the DDPGparameters and architecture in future research.

Conclusions
1. An analysis of the existing protection and developments against asymmetric and incompletephase modes was carried out and it was determined that with the uncertainty of the initial information, depending on the degree of asymmetry, the requirement of selectivity and sensitivity is not met.
To reduce failures and increase the reliability of protection, a new protection method based on the theory of fuzzy logic is proposed. 2. A block diagram and an algorithm for triggering intelligent protection against asymmetric conditions based on fuzzy controller with one input and two output parameters are proposed. The terms, types and parameters of their membership functions are determined. 3. The results of fuzzy controller synthesis are presented and the results of the calculated implementation of the protection actuation algorithm are obtained. The obtained results of computational experiments show that with a change in asymmetry in the interval 0-1.0, the selectivity and reliability of protection against asymmetric modes are fully ensured. 4. An approach to modeling and control for controlled drive systems with PMSM based on RL is proposed, which allows finding optimal policies for controlling voltage DC converters in normal and emergency conditions. The resulting learning models can be considered as a option of protection against asymmetric conditions arising in a DC converter.