Method for rapidly detecting phase angle of power grid voltage

By combining ultra-high-speed photonic sampling and parallel photonic computation with photonic neural network adaptive calibration, the problems of insufficient high-frequency detail capture and dynamic operating condition adaptability of traditional power grid voltage phase angle detection methods are solved, realizing real-time and high-precision detection of power grid voltage phase angle.

CN121978408APending Publication Date: 2026-05-05NINGXIA UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
NINGXIA UNIVERSITY
Filing Date
2026-01-26
Publication Date
2026-05-05

AI Technical Summary

Technical Problem

Traditional grid voltage phase angle detection methods are insufficient in capturing high-frequency details and adapting to dynamic operating conditions, making it difficult to meet the requirements of modern power grids for fast and accurate synchronous control.

Method used

The technology approach employs photonic ultra-high-speed sampling, spatiotemporal coding, parallel photonic computation, and photonic neural network adaptive calibration. Ultra-high-speed sampling is performed through a photonic analog-to-digital converter to construct a three-dimensional photonic feature matrix. The phase angle is solved in parallel using a silicon-based photonic chip, and online calibration is performed through a photonic neural network. Finally, the output is photonic-electronic compatible.

Benefits of technology

It achieves real-time, high-precision, and highly adaptive detection of the grid voltage phase angle, breaking through the bandwidth limitations of traditional methods, improving detection speed and robustness, and is suitable for complex dynamic operating conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121978408A_ABST
    Figure CN121978408A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of power system measurement, and discloses a power grid voltage phase angle rapid detection method which is characterized by comprising the steps of photon ultra-high-speed sampling and space-time super-resolution coding, direct phase angle solving through photon parallel operation, photon adaptive calibration and photon-electron compatible output. A photon analog-to-digital converter is used for carrying out ultra-high-speed sampling on a power grid voltage signal, a photon characteristic matrix is constructed through space-time super-resolution coding, an instantaneous phase angle at each sampling moment is directly solved through a parallel photon interference array, and photon domain moving average is implemented to suppress noise, so that the noise is reduced; a photon neural network is adopted to carry out self-adaptive calibration on an initial detection value under a dynamic working condition, detection precision and robustness are improved through an online weight updating and feedback optimization mechanism, and finally a photon-electron compatible output module converts a photon domain detection result into a standard electric signal to be output. Real-time, high-precision and strong-adaptive detection of the phase angle is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of power system measurement technology, and more specifically, to a method for rapid detection of grid voltage phase angle. Background Technology

[0002] In fields such as power system synchronization control, grid-connected inverter operation, and renewable energy generation integration, real-time and accurate detection of grid voltage phase angle is crucial. Traditional detection methods are mostly based on electronic sampling and digital signal processing technologies. Their sampling rate is limited by the bandwidth of electronic analog-to-digital converters, making it difficult to capture high-frequency details in the signal. When calculating the phase angle, they usually rely on iterative algorithms such as phase-locked loops, which have convergence delays and insufficient dynamic response speed. In addition, facing complex dynamic conditions such as rapid voltage amplitude fluctuations and frequency shifts brought about by the high proportion of renewable energy grid integration, traditional methods lack effective online adaptive calibration mechanisms, resulting in decreased detection accuracy and poor robustness, making it difficult to meet the stringent requirements of modern power grids for fast and accurate synchronization control.

[0003] Therefore, the present invention provides a method for rapid detection of grid voltage phase angle, which improves the above-mentioned technical problems. Summary of the Invention

[0004] This disclosure aims to address the shortcomings of existing technologies by providing a method for rapid detection of grid voltage phase angle. The invention employs a technical approach of ultra-high-speed photonic sampling, spatiotemporal coding, parallel photonic computation, and adaptive calibration of photonic neural networks, achieving real-time, high-precision, and highly adaptive detection of grid voltage phase angle.

[0005] The above-mentioned technical objective of the present invention is achieved through the following technical solution: a method for rapid detection of grid voltage phase angle, comprising the following steps:

[0006] S1. Photonic ultra-high-speed sampling and spatiotemporal super-resolution coding: A photonic analog-to-digital converter is used to sample the grid voltage analog signal at ultra-high speed to generate a photonic pulse stream. Spatiotemporal super-resolution coding is then performed on the photonic pulse stream to construct a three-dimensional photonic feature matrix containing voltage timing, amplitude, and phase information in the form of "time-space-polarization".

[0007] S2. Directly solve the phase angle using photonic parallel computation: The three-dimensional photonic feature matrix is ​​input into a photonic linear computation array based on a silicon-based photonic chip. The instantaneous phase angle at each sampling moment is solved in parallel in the photonic domain through photonic interference. The instantaneous phase angle sequence is then processed by photonic domain moving average to output the initial detection value of the phase angle.

[0008] S3. Photonic Adaptive Calibration: Based on a photonic neural network integrated with the photonic linear operation array on the same silicon-based photonic chip, it receives the initial phase angle detection value and the dynamic operating condition characteristic parameters collected in real time. Through online inference and weight update using a pre-trained phase deviation compensation model, it calibrates the initial phase angle detection value and outputs an accurate phase angle detection value.

[0009] S4. Photonic-Electron Compatible Output: The photonic signal corresponding to the precise phase angle detection value is converted into an electrical signal through a photonic detection array. After signal conditioning, analog-to-digital conversion and communication protocol encapsulation, the signal is output to the power grid control system.

[0010] As a preferred embodiment of the present invention, the spatiotemporal super-resolution coding in S1 includes:

[0011] S1.1, Time-dimension encoding: Mapping the sampling moment to a timestamp of a photon pulse;

[0012] S1.2, Spatial Dimension Encoding: The voltage amplitude and instantaneous phase at each sampling moment are coupled to the photon polarization state parameters through encoding coefficients;

[0013] S1.3 Construct the three-dimensional photon feature matrix based on timestamps and polarization state parameters.

[0014] As a preferred embodiment of the present invention, the photonic linear operation array in S2 comprises: P parallel photonic interference units, where P is equal to the total number of sampling points N of the three-dimensional photonic feature matrix;

[0015] Each photonic interferometer unit contains a photonic beam splitter, a phase modulator, a photonic coupler, and a photonic intensity detector, used to process the encoded data of a single sampling point.

[0016] As a preferred embodiment of the present invention, the parallel solution of the instantaneous phase angle at each sampling moment in S2 specifically involves:

[0017] Each photonic interference unit splits the input photon pulse into an in-phase interference branch and an orthogonal interference branch, and calculates the instantaneous phase angle using the photon intensity values ​​output from the two interference paths. The calculation formula is:

[0018] in, and These represent the photon intensities output from the in-phase branch and the quadrature branch, respectively. and These are the conversion coefficients determined through offline calibration.

[0019] As a preferred technical solution of the present invention, the photonic neural network described in S3 is a hierarchical photonic synaptic architecture, including: an input layer, a hidden layer and an output layer;

[0020] The dynamic operating condition characteristic parameters include at least: the power output change rate of the power generation system, the voltage amplitude fluctuation of the grid, the voltage angular frequency offset of the grid, and the change rate of the initial detected phase angle.

[0021] As a preferred embodiment of the present invention, the online weight update in S3 specifically involves: dynamically adjusting the photonic synapse weights based on the real-time detected phase angle error, using the following update formula:

[0022] in, and These are the photon synapse weights before and after the update, respectively. Update the step size for weights. For phase angle error, This is the predicted value for the phase angle deviation.

[0023] As a preferred embodiment of the present invention, S3 further includes constraining and truncating the updated weights to ensure that they are within a preset weight constraint range determined by the physical properties of the photonic device.

[0024] As a preferred embodiment of the present invention, S3 further includes deviation rationality verification: comparing the predicted phase angle deviation value output by the photonic neural network with a preset reasonable deviation threshold range, and if it exceeds the range, correcting it to the corresponding threshold boundary value.

[0025] As a preferred embodiment of the present invention, S3 further includes feedback optimization compensation: dynamically calculating the feedback adjustment coefficient based on the current phase angle calibration error, and dynamically adjusting the deviation compensation coefficient based on the severity of the operating condition fluctuation and the feedback adjustment coefficient, for calculating the accurate phase angle detection value.

[0026] As a preferred embodiment of the present invention, the signal conditioning in S4 includes: current-to-voltage conversion, low-noise amplification, and low-pass filtering; the communication protocol encapsulation supports Ethernet / IP, Modbus TCP, or IEC 61850 standards, and embeds cyclic redundancy check codes in the data frames.

[0027] In summary, the present invention has the following beneficial effects:

[0028] Firstly, by employing a photonic analog-to-digital converter for ultra-high-speed sampling and spatiotemporal super-resolution coding, the bandwidth limitations of traditional electronic sampling technology are overcome. This enables the high-fidelity capture of all key information (timing, amplitude, and phase) of the power grid voltage signal in a single operation, laying a reliable data foundation for subsequent rapid and accurate phase angle calculations.

[0029] Secondly, by using a parallel photonic interference array constructed with silicon-based photonic chips, the phase angle of each sampling point can be solved in parallel and synchronously directly in the photonic domain. This completely avoids the convergence delay problem of traditional iterative algorithms such as phase-locked loops, realizes instantaneous calculation of the phase angle, and improves the detection speed by orders of magnitude.

[0030] Third, an innovative adaptive online calibration mechanism based on photonic neural networks is introduced, which can sense the dynamic operating conditions of the grid connection in real time (such as power surges, voltage fluctuations, etc.). Through pre-trained models and online weight updates, detection deviations are dynamically compensated, which significantly improves the detection accuracy and robustness of the method in complex and time-varying power grid environments.

[0031] Fourth, the entire detection process (sampling, calculation, calibration) is completed in the photonic domain. The calculation delay depends only on the extremely short propagation time of photons in the waveguide, and the standard signal is finally output through a high-speed opto-compatible interface. Thus, while ensuring ultra-low latency and high-precision detection, it achieves seamless compatibility with existing power grid control systems and has excellent engineering practicality. Attached Figure Description

[0032] Figure 1 A flowchart of a method for rapid detection of grid voltage phase angle provided in an embodiment of the present invention. Detailed Implementation

[0033] The present application will now be described in detail with reference to specific embodiments. These embodiments will help those skilled in the art to further understand the present application, but do not limit the present application in any way. It should be noted that those skilled in the art can make several modifications and improvements without departing from the concept of the present application. These all fall within the protection scope of the present application.

[0034] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0035] Unless otherwise defined, all technical and scientific terms used in this specification have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the scope of this application. The term "and / or" as used in this specification includes any and all combinations of one or more of the associated listed items.

[0036] This disclosure aims to address the technical shortcomings of traditional electronic domain detection algorithms (such as phase-locked loops (PLLs) and discrete Fourier transforms (DFTs), including serial iteration delays, limited detection rates, and poor adaptability to dynamic operating conditions. This disclosure provides a fast method for detecting the phase angle of grid voltage. First, a photonic analog-to-digital converter (PAC) is used to sample the grid voltage signal at ultra-high speed, and a photonic feature matrix containing timing, amplitude, and phase information is constructed through spatiotemporal super-resolution coding. Next, the instantaneous phase angle at each sampling moment is directly solved using a parallel photonic interferometer array on a silicon-based photonic chip, and a photonic domain moving average is implemented to suppress noise. Then, a photonic neural network is used to adaptively calibrate the initial detection value under dynamic operating conditions, and online weight updates and feedback optimization mechanisms are used to improve detection accuracy and robustness. Finally, the photonic domain detection result is converted into a standard electrical signal output via a photonic-electronic compatible output module, supporting seamless integration with existing grid equipment. This method achieves real-time, high-precision, and highly adaptive phase angle detection, suitable for dynamic operating conditions such as high-proportion renewable energy grid integration, and offers advantages such as low latency, strong anti-interference capability, and good compatibility.

[0037] Furthermore, the technical features involved in the various embodiments of this application described below can be combined with each other as long as they do not conflict with each other.

[0038] Please refer to Figure 1 , Figure 1 A flowchart of a method for rapid detection of grid voltage phase angle according to an embodiment of this disclosure is shown. The overall process mainly includes the following four steps:

[0039] S1, Photon Ultra-High-Speed ​​Sampling and Spatiotemporal Super-Resolution Coding.

[0040] The PADC uses a photonic analog-to-digital converter (PADC) to perform ultra-high-speed sampling of the grid voltage analog signal, directly converting the continuous grid voltage analog signal into a discrete photonic pulse stream. The sampling rate of the PADC can break through the bandwidth limitation of the traditional electronic analog-to-digital converter (ADC) and can fully capture the high-frequency details related to the phase angle in the grid voltage signal.

[0041] A spatiotemporal super-resolution coding operation is performed on the photon pulse stream to achieve the one-time capture of all the information required for phase angle detection. The specific coding logic is as follows:

[0042] S1.1 Time Dimension Encoding: Timestamp encoding is used to characterize the temporal characteristics of instantaneous voltage values. The sampling time of the analog grid voltage signal is defined as... ( For the sampling sequence index, , (Total number of samples in a single encoding), the instantaneous value of the grid voltage at the corresponding moment is The timestamp of each photon pulse is marked as , and It presents a one-to-one mapping relationship, that is, through The voltage instantaneous value change pattern at the corresponding sampling time can be traced in reverse, and the mapping relationship satisfies:

[0043]

[0044] in, This is the starting sampling time for a single encoding. The sampling time interval of the PADC is determined by the sampling rate of the PADC.

[0045] S1.2 Spatial Dimension Encoding: The coupling characteristics of voltage amplitude and phase are characterized using photon polarization state encoding. The polarization state parameters of the photon are defined as follows: , The polarization angle is the voltage amplitude at the corresponding sampling time. and instantaneous phase Related, voltage amplitude for The absolute value, that is Instantaneous phase for exist Phase information at time, polarization state parameters The encoding formula is:

[0046]

[0047] in, These are voltage amplitude encoding coefficients, used to quantize the voltage amplitude into polarization angle components. These are the instantaneous phase encoding coefficients, used to preserve the original characteristics of the instantaneous phase. and This is determined through offline calibration to ensure that amplitude and phase characteristics are not distorted during the encoding process.

[0048] S1.3. By using timestamp encoding in the time dimension and polarization state encoding in the spatial dimension, a three-dimensional photon feature matrix of "time-space-polarization" is constructed. The row index of this matrix corresponds to the sampling sequence index. The column indexes correspond to the encoding dimensions (time dimension, spatial dimension), and the matrix elements are the encoded values ​​of the corresponding dimensions, forming a three-dimensional photon feature matrix. The expression is:

[0049]

[0050] Three-dimensional photon feature matrix It includes the timing characteristics of the instantaneous voltage value, voltage amplitude information, and instantaneous phase characteristics at each sampling time, realizing the integrated capture of all the key information required for phase angle detection, and avoiding the information loss problem caused by traditional step-by-step sampling.

[0051] S2. The phase angle is directly solved by photon parallel computation.

[0052] S2.1 Construct a photonic linear computation array based on a silicon-based photonic chip. This array consists of... It consists of a series of identical, parallel photon interference units. The value of and the three-dimensional photon feature matrix Total number of samples Equal (i.e.) This ensures that each photonic interferometer unit processes the encoded feature data of a single sampling moment in the matrix on a one-to-one basis, enabling parallel computation of the entire dataset. Each photonic interferometer unit includes a photonic beam splitter, a phase modulator, a photonic coupler, and a photonic intensity detector. All components are integrated on the same chip via silicon-based optical waveguides, and the optical path propagation loss is optimized to be at an extremely low level.

[0053] S2.2, The three-dimensional photon feature matrix of "time-space-polarization" Before being input to the photonic linear computation array, the photonic pulse stream is first collimated by a photonic collimator to ensure that the photonic pulses can be accurately coupled to the input ports of each photonic interference unit. The photonic beam splitter divides each sampling time... The corresponding photon pulses are split into two beams with a 1:1 power ratio and injected into the in-phase interference branch and the quadrature interference branch, respectively. The optical path phase of the in-phase interference branch is consistent with the reference phase of the grid voltage, while the optical path phase of the quadrature interference branch differs from the reference phase. (Preset by the phase shifter built into the branch).

[0054] S2.3, Based on the complex number representation principle of the power grid voltage signal, at each sampling time... Corresponding instantaneous value of grid voltage It can be decomposed into in-phase components. Orthogonal components The complex relation between the two is expressed as follows:

[0055]

[0056] in, The imaginary unit ( ), for In the reference phase direction (set as) Projection components along the axial direction, for In the direction perpendicular to the reference phase (let's call it...) The projection components in the axial direction, and satisfying , Voltage amplitude, The angular frequency of the grid voltage. for The instantaneous initial phase, therefore , .

[0057] Combining three-dimensional photon feature matrix polarization state parameters in (Polarization angle), characteristic decoupling is achieved through optical path interference of photon interference units: In the in-phase interference branch, the photon polarization state matches the branch phase, producing constructive interference, and the output light intensity is in line with the in-phase component. The intensity is proportional to the square of the polarization; in the orthogonal interference branch, the photon polarization state matches the branch phase, also producing constructive interference, and the output light intensity is proportional to the orthogonal component. It is proportional to the square of the equation. The photon intensity corresponding to the in-phase component is defined as... The photon intensity corresponding to the orthogonal component is The linear mapping relationship between the two and the voltage component is expressed as follows:

[0058]

[0059]

[0060] in, The in-phase component photon intensity conversion coefficient. The photon intensity conversion coefficient of the orthogonal components. and Determined through offline calibration: Select A set of standard sinusoidal voltage signals with known amplitudes ( The amplitude covers 80%-120% of the rated voltage of the power grid. The corresponding photon intensity output values ​​are recorded by inputting them into the photon interference unit. The linear conversion coefficients are obtained by fitting the values ​​using the least squares method, ensuring that the fitting error is less than the preset threshold.

[0061] S2.4, Grid voltage at sampling time instantaneous phase angle The intensity of photons in phase Photon intensity of orthogonal components The ratio relationship determines, combined with and From the trigonometric relationships, the formula for calculating the instantaneous phase angle is derived as follows:

[0062]

[0063] The physical essence of this formula is to eliminate voltage amplitude through the ratio of photon intensities. The impact directly reflects The value of is then used to obtain the instantaneous phase angle through arctangent calculation. Since the photon interference process occurs in parallel, all sampling times The solution is completed synchronously, eliminating the need for iterative approximation steps required by traditional algorithms.

[0064] S2.5 To eliminate random noise interference that may exist in a single sampling, for all sampling times... ( The corresponding instantaneous phase angle Perform photonic domain moving average processing. Set the moving average window length to... ( Less than A positive integer, set according to the dynamic variation characteristics of the power grid voltage signal, usually taken as... The moving average weighting coefficient is defined as follows: ( ),satisfy And the weighting coefficients vary with The weighting increases linearly (i.e., the weight of data closer to the latest sampling time is greater, ensuring that the initial detection value can reflect the latest state of the phase angle), and the formula for calculating the weighting coefficient is:

[0065]

[0066] Based on the aforementioned weighting coefficients, the phase angle sequence end The data points are weighted and averaged to output the initial detection value of the phase angle. Its calculation expression is:

[0067]

[0068] The entire photonic parallel computation process is completed within the photonic domain, and the computational delay is determined solely by the propagation time of photons in the silicon-based optical waveguide. The calculation formula is ,in The total optical path length of the photon interference unit. The speed at which photons propagate in a silicon-based optical waveguide is given by... Approaching the speed of light in a vacuum, the computational latency is significantly reduced compared to traditional electronic domain algorithms, and it avoids the clock synchronization delay and iteration convergence delay problems of electronic domain algorithms.

[0069] S3, Photon Adaptive Calibration.

[0070] Photonic adaptive calibration is based on a photonic neural network as its core processing unit. This unit is integrated with a photonic linear computation array on the same silicon-based photonic chip. It achieves delay-free transmission of the initial phase angle detection value via a photonic waveguide. The entire calibration process is completed in the photonic domain, without introducing electronic domain conversion and processing delays. The photonic neural network employs a hierarchical photonic synaptic architecture, comprising an input layer, a hidden layer, and an output layer. The input layer receives the initial phase angle detection value and dynamic operating condition characteristic parameters. The hidden layer performs online inference of the deviation compensation model through dynamic adjustment of photonic synaptic weights. The output layer outputs the accurate calibrated phase angle detection value.

[0071] S3.1 Constructing a dynamic operating condition feature perception module: Real-time acquisition of key operating condition parameters during renewable energy grid connection, defining the operating condition feature vector as... ,in The rate of change of the output power of the power generation system. This refers to the fluctuation in the magnitude of the grid voltage. This represents the angular frequency offset of the grid voltage. This represents the rate of change of the initial detected phase angle. (This is related to) the operating condition feature vector. After normalization to eliminate the dimensional differences between parameters of different dimensions, the normalized feature vector is as follows:

[0072] The normalization formula for each component is:

[0073]

[0074] in, , For the first The minimum value of each operating parameter (determined based on historical grid connection data statistics). For the first The maximum value of each operating parameter (determined based on historical grid connection data statistics), after normalization .

[0075] Secondly, the phase deviation compensation model built into the photonic calibration operator is pre-trained. This model is trained by offline collection of massive dynamic operating condition samples of renewable energy grid connection (covering typical scenarios such as power surges, voltage amplitude fluctuations, and angular frequency shifts). The training sample set is defined as follows: ( , (where the total number of samples is 1), For the first The normalized chemical condition feature vector of each sample. For the first The true value of the phase angle deviation corresponding to each sample , For the first The true phase angle value of each sample (obtained by measuring a high-precision standard phase meter). For the first The initial detection value of the phase angle of each sample (output by the photon parallel computing module).

[0076] The training objective of a photonic neural network is to minimize the mean square error between the predicted and actual phase deviation values. A loss function is defined as follows: for:

[0077]

[0078] in, The first output of the photonic neural network The predicted phase angle deviation for each sample. The network weights are adjusted using a photonic synaptic weight optimization algorithm to optimize the loss function. The network converges to below a preset threshold, and a fixed network weight matrix is ​​obtained after training. (Weight matrix from input layer to hidden layer) (The number of neurons in the hidden layer, set according to the training convergence effect) and (Weight matrix from hidden layer to output layer).

[0079] S3.2, Phase Deviation Prediction: During real-time calibration, the normalized chemical condition characteristic vector is... Initial detection value of phase angle (Output from the photonic parallel computing module) These inputs are shared into the input layer of the photonic neural network, and the input layer neurons will... Converted into the corresponding photon pulse intensity signal The conversion formula is:

[0080]

[0081] in, This is the phase angle-photon intensity conversion coefficient (determined through offline calibration, used to map the phase angle physical quantity to photon signal intensity). Simultaneously, the normalized chemical condition eigenvector is... Each component is converted into the corresponding photon signal intensity, and the first component is defined as... The photon signal intensity corresponding to each normalized chemical condition characteristic is: The conversion formula is:

[0082]

[0083] in, For the first Individual operating condition characteristics - photon intensity conversion coefficient ( (Determined through offline calibration, used to map dimensionless normalized features to photon signal intensity). With each After being superimposed through a photonic coupler, the signal is transmitted to the hidden layer.

[0084] Hidden layer neurons achieve the interaction between input signals and weight matrices through photon interference. Linear operations, defining the hidden layer output vector , each component ( ) is the hidden layer The output photon intensity of each neuron is calculated using the following expression:

[0085]

[0086] in, For the input layer Each working condition feature neuron and the hidden layer Photonic synaptic weights between neurons (characterizing the signal transmission strength between two neurons). For the phase angle signal input channel and the hidden layer Photosynaptic weights between neurons (characterizing the effect of phase angle signal on the hidden layer) (the intensity of action of each neuron) The photon activation function, employing a nonlinear function based on the photon saturation absorption effect, is used to achieve nonlinear mapping of the signal. Its expression is:

[0087]

[0088] in, The saturation output intensity of the photonic activation function (determined by the physical characteristics of the photonic device, representing the upper limit of the output intensity) is given. This is the slope adjustment coefficient of the activation function (determined through offline calibration, used to adjust the nonlinear steepness of the activation function). The threshold strength of the activation function (determined by the physical characteristics of the photonic device, it is the critical input strength at which the activation function begins to respond nonlinearly).

[0089] Hidden layer output vector After being transmitted to the output layer via a photonic waveguide, it is combined with the weight matrix. Perform linear calculations to obtain the photon signal intensity corresponding to the predicted phase angle deviation. Its calculation expression is:

[0090]

[0091] in, For the hidden layer Photonic synaptic weights between the first hidden layer neuron and the output layer neuron (representing the first hidden layer neuron) (The contribution intensity of each neuron to the output signal). Convert to phase angle deviation prediction value The conversion formula is:

[0092]

[0093] in, The bias is used to predict the photon intensity-phase angle conversion coefficient (determined through offline calibration, used to reverse map the photon intensity signal into the phase angle bias physical quantity).

[0094] S3.3 Online Weight Update and Robustness Verification: To achieve adaptive calibration under dynamic operating conditions, an online weight update mechanism is introduced. Based on the real-time detected phase angle error, the photon synapse weights are dynamically adjusted to ensure the adaptability of the deviation compensation model to changes in operating conditions. The phase angle error is defined as follows: ,in The reference value for the grid voltage phase angle (provided by the grid synchronization signal and used as a benchmark for phase angle detection). This is the phase angle detection value after calibration at the previous time step (used to compare with the current reference value to obtain the error). The input layer-hidden layer weight update formula is:

[0095]

[0096] The formula for updating the weights of the hidden layer and the output layer is:

[0097]

[0098] in, , For the updated photonic synapse weights, , The photon synapse weights before the update. , The weight update step size is set for the input layer-hidden layer and the hidden layer-output layer, respectively (the step size is set according to the convergence speed requirements; the larger the step size, the more sensitive the weight adjustment). For the bias prediction value of the input layer - hidden layer, the first... The partial derivative of the weight (characterizing the degree of influence of the weight change on the predicted bias value). The bias prediction value is the value of the hidden layer - output layer. The partial derivatives of the bit weights (characterizing the degree of influence of the weight change on the predicted deviation value) are solved in real time by the photon domain gradient calculation module. The solution process is based on the inverse derivation of the intensity change of the photon interference signal.

[0099] To adapt to the hardware operating characteristics of photonic neural networks and avoid optical path blockage and signal distortion caused by excessive weights, a constraint range is set for the photonic synaptic weights. The input layer-hidden layer weight constraint range is defined as follows: ,in For the input layer - hidden layer The minimum value of the photonic synaptic weight. This represents the maximum value of the weight; the hidden layer-output layer weight constraint interval is defined as follows. ,in For hidden layer - output layer The minimum value of the photonic synaptic weight. This represents the maximum value of the weight. The weight constraint range is determined based on the physical properties of the photonic device (such as phase modulation range and light intensity attenuation limit).

[0100] During the online weight update process, if the updated weights exceed the constraint range, truncation is performed. The formula for input layer - hidden layer weight truncation is as follows:

[0101]

[0102] The formula for truncating the weights of the hidden layer and the output layer is:

[0103]

[0104] in, , For the photonic synaptic weights ultimately used for network inference, ensure that the operation of the photonic neural network always remains within the safe limits achievable by the hardware.

[0105] To further ensure the robustness of the calibration process, a deviation rationality verification module was added to verify the predicted phase angle deviation value. To determine validity, calibration distortion caused by model inference anomalies under extreme operating conditions is avoided. The deviation threshold range is defined as follows: ,in The minimum reasonable deviation value, The maximum reasonable deviation value is determined based on the physical variation limit of the grid voltage phase angle and statistical analysis of historical calibration data.

[0106] The logic for determining the reasonableness of deviations is as follows:

[0107] 1. If ,determination Valid and can be directly used for subsequent calibration calculations;

[0108] 2. If Then the deviation prediction value will be corrected to ;

[0109] 3. If Then the deviation prediction value will be corrected to .

[0110] Corrected phase angle deviation prediction value The calculation formula is:

[0111]

[0112] S3.4 Feedback Optimization and Compensation: Construct a calibration result feedback adjustment mechanism to monitor the accuracy of the calibration process in real time and dynamically optimize the deviation compensation effect. Define the phase angle calibration error at the current moment. ,in This is the temporary calibration value at the current moment that has not undergone feedback adjustment; the feedback adjustment coefficient. The calculation formula is:

[0113]

[0114] in, The gain is the feedback adjustment coefficient (determined through offline calibration, used to control the adjustment sensitivity; the larger the gain, the more significant the impact of the error on the compensation effect).

[0115] Construct a dynamic adjustment logic for the deviation compensation coefficient, optimize the deviation compensation weight based on the power grid operating status, and define the benchmark compensation coefficient as follows. (Determined through offline calibration, these are the default compensation coefficients under stable operating conditions), Deviation compensation coefficients The initial adjustment formula is:

[0116]

[0117] in, Attenuation coefficient (used for adjustment) (rate of change with operating conditions) Working condition feature vector The maximum absolute value of each component is used to characterize the severity of operating condition fluctuations, and its calculation expression is:

[0118]

[0119] Feedback adjustment coefficient By introducing the adjustment logic for the deviation compensation coefficient, the corrected deviation compensation coefficient is obtained. The formula is:

[0120]

[0121] Through this feedback mechanism, when the calibration error is large, the weight of the deviation compensation is automatically increased to accelerate the convergence of calibration accuracy; when the calibration error is small, the stability of the compensation coefficient is maintained to avoid fluctuations in the detection value caused by over-adjustment.

[0122] Finally, by combining the initial phase angle detection value, the corrected deviation prediction value, and the corrected deviation compensation coefficient, the final accurate phase angle detection value is calculated. The calculation formula is:

[0123]

[0124] This detection value integrates multi-level logic such as dynamic operating condition adaptation, online deviation compensation, robustness verification, weight constraints and feedback optimization, and is processed entirely in the photonic domain, which ensures both calibration accuracy and dynamic adaptability, while maintaining the rapid response characteristics of the detection process.

[0125] S4, photonic-electronic compatible output.

[0126] The photonics-electronics compatible output module consists of a photonics detection array, a signal conditioning unit, an analog-to-digital converter module, and a communication interface module. These modules are connected sequentially via a high-speed signal link to achieve distortion-free conversion of the precise phase angle detection value in the photonics domain to the standard signal in the electronic domain. The module also maintains low-latency connection with the preceding photonics domain processing throughout the process, ensuring the real-time performance and compatibility of the detection results.

[0127] S4.1 An array-type photonic detector is used to receive the photonic signal corresponding to the final accurate phase angle detection value of the photonic domain output. This photonic detector is directly coupled to the output layer of the photonic neural network through a photonic waveguide. An avalanche photodiode (APD) array is selected as the detector type, and its detection wavelength matches the transmission wavelength of the photonic signal to ensure high efficiency in photonic-to-electrical energy conversion. The intensity of the photonic signal received by the photonic detector is defined as... This signal is related to the final accurate phase angle detection value. There is a linear mapping relationship, and the mapping formula is:

[0128]

[0129] in, The final phase angle-photon intensity conversion coefficient (determined through offline calibration, used to stably map the calibrated phase angle physical quantity into a photon intensity signal).

[0130] Photon detectors measure photon signal intensity Converted into a corresponding weak current signal The conversion process is based on the photoelectric effect, and the conversion formula is:

[0131]

[0132] in, The quantum efficiency of a photon detector (determined by the detector's hardware characteristics, characterizing the conversion ratio of photons to photoelectrons). The wavelength of the photonic signal (preset based on the transmission characteristics of the photonic waveguide). Let be Planck's constant. It is the speed of light in a vacuum.

[0133] weak current signal The signal conditioning unit amplifies, filters, and performs impedance matching to eliminate noise interference and meet the input requirements of the subsequent analog-to-digital converter. The signal conditioning unit includes a low-noise operational amplifier, an active filter circuit, and an impedance converter. First, the low-noise operational amplifier... Perform current-to-voltage conversion and amplitude amplification to obtain a voltage signal. The conversion and amplification formulas are as follows:

[0134]

[0135] in, This is the feedback resistor for the operational amplifier (determined through offline calibration to set the current-to-voltage conversion ratio). This is the voltage amplification factor of the operational amplifier (set according to the amplitude range of the weak current signal).

[0136] S4.2 Active filter circuit Low-pass filtering is performed to remove high-frequency noise and electromagnetic interference, resulting in a filtered voltage signal. The filtering characteristics are determined by the transfer function. The description, expressed as:

[0137]

[0138] in, For complex frequency variables, The filtering time constant ( ), For filtering resistors, For filtering capacitors, The value is set according to the frequency range of the change in the phase angle of the grid voltage to ensure that the effective signal passes through without distortion.

[0139] Filtered voltage signal The impedance is matched to the input impedance of the analog-to-digital converter module by an impedance converter to obtain a standard voltage signal suitable for analog-to-digital conversion. The impedance transformation process satisfies the impedance matching condition. ,in The output impedance of the signal conditioning unit. This is the input impedance of the analog-to-digital converter module, to avoid amplitude distortion caused by signal reflection.

[0140] The analog-to-digital converter module uses a high-precision, high-speed analog-to-digital converter (ADC) to convert standard voltage signals. Convert to digital signal (for Bit binary number, (Based on the required detection accuracy), the conversion formula is:

[0141]

[0142] in, This is the minimum input voltage for the analog-to-digital converter. This is the maximum input voltage of the analog-to-digital converter. This is a rounding function that ensures the converted digital signal is an integer binary number. for The maximum quantization value of a bit-to-bit analog-to-digital converter.

[0143] S4.3 To achieve compatibility between digital signals and the power grid connection control system, the communication interface module supports digital signals. It performs protocol conversion and format encapsulation, supporting mainstream industrial communication protocols (such as Ethernet / IP, ModbusTCP, IEC61850, etc.). The encapsulated digital signal is defined as... (To conform to the frame structure data of the communication protocol), the encapsulation process follows the frame format specification of the corresponding communication protocol, including a frame header, data segment, check segment, and frame trailer, where the data segment is... The corresponding binary data uses a cyclic redundancy check (CRC) algorithm to generate a checksum. The calculation formula is:

[0144]

[0145] in, This is a cyclic redundancy check function. The preset generator polynomial (set according to the communication protocol standard, such as the generator polynomial of CRC-32). ), used to verify the integrity of data transmission.

[0146] The communication interface module transmits the packaged digital signals via an industrial bus or Ethernet link. The output is sent to the renewable energy grid-connected control system, achieving seamless compatibility between the detection results and existing grid equipment. Simultaneously, the module has a built-in signal status monitoring unit that monitors the transmission status of the output signal in real time and defines transmission status flags. ( This indicates that the transmission is normal. (Indicating a transmission anomaly), when a transmission anomaly is detected, an automatic signal retransmission mechanism is triggered to ensure reliable transmission of the detection results. The delay of the entire photonics-electronics compatible output process is determined by the hardware response time of each module. By optimizing device selection and link design, the output delay is ensured to match the delay of the preceding photonics domain processing, so as not to affect the real-time performance of the overall detection.

[0147] The above description is merely a preferred embodiment of the present invention. The scope of protection of the present invention is not limited to the above embodiments. All technical solutions falling within the scope of the present invention's concept are within the scope of protection of the present invention. It should be noted that for those skilled in the art, any improvements and modifications made without departing from the principles of the present invention should also be considered within the scope of protection of the present invention.

Claims

1. A method for rapid detection of grid voltage phase angle, characterized in that, The method includes the following steps: S1. Photonic ultra-high-speed sampling and spatiotemporal super-resolution coding: A photonic analog-to-digital converter is used to sample the grid voltage analog signal at ultra-high speed to generate a photonic pulse stream. Spatiotemporal super-resolution coding is then performed on the photonic pulse stream to construct a three-dimensional photonic feature matrix containing voltage timing, amplitude, and phase information in the form of "time-space-polarization". S2. Directly solve the phase angle using photonic parallel computation: The three-dimensional photonic feature matrix is ​​input into a photonic linear computation array based on a silicon-based photonic chip. The instantaneous phase angle at each sampling moment is solved in parallel in the photonic domain through photonic interference. The instantaneous phase angle sequence is then processed by photonic domain moving average to output the initial detection value of the phase angle. S3. Photonic Adaptive Calibration: Based on a photonic neural network integrated with the photonic linear operation array on the same silicon-based photonic chip, it receives the initial phase angle detection value and the dynamic operating condition characteristic parameters collected in real time. Through online inference and weight update using a pre-trained phase deviation compensation model, it calibrates the initial phase angle detection value and outputs an accurate phase angle detection value. S4. Photonic-Electron Compatible Output: The photonic signal corresponding to the precise phase angle detection value is converted into an electrical signal through a photonic detection array. After signal conditioning, analog-to-digital conversion and communication protocol encapsulation, the signal is output to the power grid control system.

2. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, The spatiotemporal super-resolution coding described in S1 includes: S1.1, Time-dimension encoding: Mapping the sampling moment to a timestamp of a photon pulse; S1.2, Spatial Dimension Encoding: The voltage amplitude and instantaneous phase at each sampling moment are coupled to the photon polarization state parameters through encoding coefficients; S1.3 Construct the three-dimensional photon feature matrix based on timestamps and polarization state parameters.

3. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, The photonic linear operation array described in S2 includes: P parallel photonic interference units, where P is equal to the total number of sampling points N of the three-dimensional photonic feature matrix; Each photonic interferometer unit contains a photonic beam splitter, a phase modulator, a photonic coupler, and a photonic intensity detector, used to process the encoded data of a single sampling point.

4. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, The parallel solution of the instantaneous phase angle at each sampling time, as described in S2, is as follows: Each photonic interference unit splits the input photon pulse into an in-phase interference branch and an orthogonal interference branch, and calculates the instantaneous phase angle using the photon intensity values ​​output from the two interference paths. The calculation formula is: ; in, and These represent the photon intensities output from the in-phase branch and the quadrature branch, respectively. and These are the conversion coefficients determined through offline calibration.

5. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, The photonic neural network described in S3 is a hierarchical photonic synaptic architecture, including: an input layer, a hidden layer, and an output layer; The dynamic operating condition characteristic parameters include at least: the power output change rate of the power generation system, the voltage amplitude fluctuation of the grid, the voltage angular frequency offset of the grid, and the change rate of the initial detected phase angle.

6. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, The online weight update described in S3 specifically involves dynamically adjusting the photonic synapse weights based on the real-time detected phase angle error, using the following update formula: ; in, and These are the photon synapse weights before and after the update, respectively. Update the step size for weights. For phase angle error, This is the predicted value for the phase angle deviation.

7. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, S3 also includes constraining and truncation of the updated weights to ensure that they are within the preset weight constraint range determined by the physical properties of the photonic devices.

8. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, S3 also includes deviation rationality verification: the phase angle deviation prediction value output by the photonic neural network is compared with the preset reasonable deviation threshold range, and if it exceeds the range, it is corrected to the corresponding threshold boundary value.

9. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, S3 also includes feedback optimization compensation: dynamically calculates the feedback adjustment coefficient based on the current phase angle calibration error, and dynamically adjusts the deviation compensation coefficient based on the severity of the operating condition fluctuation and the feedback adjustment coefficient, which is used to calculate the accurate phase angle detection value.

10. The method for rapid detection of grid voltage phase angle according to claim 1, characterized in that, The signal conditioning described in S4 includes: current-to-voltage conversion, low-noise amplification, and low-pass filtering; the communication protocol encapsulation supports Ethernet / IP, Modbus TCP, or IEC 61850 standards, and embeds cyclic redundancy check codes in the data frames.