Adaptive test method for effective value of transient electrical quantity parameter
By employing an adaptive testing method and utilizing high-frequency sampling hardware and software for high-speed acquisition, combined with zero-crossing detection and root mean square value calculation, the problem of indeterminate waveform period of transient electrical quantity parameters was solved, enabling rapid and accurate calculation of effective values and intuitive display of changes in electrical quantity parameters.
Patent Information
- Application Number
- CN202511827626.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-05
- Publication Date
- 2026-02-27
AI Technical Summary
In power quality assessment tests, the waveform period of transient electrical parameters is not fixed, and the results of human judgment are easily affected by signal interference, making it difficult to accurately calculate the effective value.
An adaptive testing method is adopted, which uses high-frequency sampling hardware and software high-speed acquisition technology, combined with zero-crossing detection and root mean square value calculation, to automatically determine the waveform period and generate the effective value curve of electrical quantity parameters.
It enables rapid and accurate calculation of effective values during dynamic changes in electrical parameters, possesses anti-interference capabilities, provides intuitive data on changes in electrical parameters, and offers a reliable basis for judgment in generator set testing.
Smart Images

Figure CN121577950A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of generator set electrical quantity parameter testing and analysis technology, and in particular to an adaptive testing method for the effective value of transient electrical quantity parameters. Background Technology
[0002] In power quality assessment tests, it is usually necessary to collect and analyze transient electrical parameters of generator sets. During the acquisition process, the raw waveforms are mostly displayed. For example, the original waveform of an AC voltage signal is a sine wave, but due to the high sampling frequency, the original waveform curve is basically displayed as a band, such as... Figure 1 As shown, it is difficult to discern the specific changes in AC voltage from the original waveform curve. Furthermore, during transient voltage changes, the original curve needs to be zoomed out over a fixed time interval to reveal the true changes. In many data acquisition and analysis processes, users find it difficult to determine the effective value based on the original curve, failing to meet the status monitoring requirements of generator transient voltage.
[0003] The banded region of the original waveform curve represents the peak value of the actual electrical quantity parameter. To obtain the effective value of the electrical quantity parameter, the traditional method is to manually calculate the effective value when viewing the original waveform within a fixed magnification time interval. However, in actual experiments, the waveform period of transient electrical quantity parameters is variable, especially during sudden load changes. Due to sudden load changes, signal interference changes are easily caused, which seriously affects the human judgment results. Summary of the Invention
[0004] To address the aforementioned problems and technical requirements, this application proposes an adaptive testing method for the effective values of transient electrical quantity parameters. The technical solution of this application is as follows: An adaptive testing method for the effective value of transient electrical quantity parameters includes the following steps: For any i-th sampling period within the target sampling time period, according to the preset sampling rate The electrical quantity parameters of the generator set in the current sampling period are obtained and concatenated with the electrical quantity parameters in the previous sampling period in chronological order to obtain the original electrical quantity sequence. The original electrical quantity sequence includes multiple electrical quantity parameters collected in two consecutive sampling periods. Each electrical quantity parameter corresponds to an index value. The index value of the electrical quantity parameter corresponds to the sampling time of the electrical quantity parameter and indicates the order of the electrical quantity parameter in the original electrical quantity sequence. Integer parameter i > 1. Zero-crossing detection is performed on the original electrical quantity sequence to identify all zero-crossing index values; based on all identified zero-crossing index values, the waveform period of each electrical quantity parameter in the original electrical quantity sequence is determined. Each waveform period corresponds to three consecutive zero-crossing index values, and the zero-crossing index value represents the index value of the electrical quantity parameter in the original electrical quantity sequence that belongs to the zero-crossing point. Based on all electrical quantity parameters within each waveform cycle, the effective values of the electrical quantity parameters for each waveform cycle are calculated. Based on the effective values of electrical quantity parameters for each waveform period calculated from all sampling periods within the target sampling time period, a curve of the effective values of electrical quantity parameters within the target sampling time period is generated according to the target display sampling rate.
[0005] A further technical solution involves performing zero-crossing detection on the original electrical quantity sequence to identify all zero-crossing index values, including: Initialize the number of iterations k=1 and determine the zero-crossing threshold. ; The absolute values of electrical quantity parameters in the original electrical quantity sequence are less than the zero-crossing threshold. The index values of each electrical quantity parameter are used as candidate index values, and the candidate index values are combined in order to obtain a candidate index array; Calculate the difference between two adjacent candidate index values in the candidate index array sequentially. When there is a difference between two adjacent candidate index values If the difference requirement is not met, update the original electrical quantity sequence and update the zero-crossing threshold. ; Let k = k + 1, based on the updated zero-crossing threshold. Repeat the zero-crossing detection until the difference between any two adjacent candidate index values in the candidate index array meets the difference requirement, and obtain all zero-crossing index values.
[0006] A further technical solution involves updating the zero-crossing threshold. include: When the difference between two adjacent candidate index values When the value is 1, the zero-crossing threshold is updated. ; When the difference between two adjacent candidate index values Greater than 1 and less than the second threshold At that time, the zero-crossing threshold is updated. ; When the difference between two adjacent candidate index values Greater than the third threshold At that time, the zero-crossing threshold is updated. Among them, the third threshold Greater than the second threshold .
[0007] The further technical solution involves updating the original electrical quantity sequence, including: When the difference between two adjacent candidate index values Equal to 1, or the difference between two adjacent candidate index values. Greater than the third preset value At the same time, the original electrical parameter sequence remains unchanged; When the difference between two adjacent candidate index values Greater than 1 and less than the second preset value When the current two adjacent candidate index values are at the same time, calculate the difference between the previous index value and the previous index value, and the difference between the next index value and the next index value, determine the candidate index value corresponding to the smaller difference between the previous and next differences between the current two adjacent candidate index values, and remove the electrical quantity parameters corresponding to the candidate index values from the original electrical quantity sequence.
[0008] Its further technical solution is to, based on a preset sampling rate and rated values of electrical quantity parameters Determine the zero-crossing threshold for the initial iteration with k=1. , It is a scaling factor and .
[0009] A further technical solution involves generating the effective value curve of electrical quantity parameters within the target sampling period according to the target display sampling rate, including: For any waveform period in any original electrical quantity sequence within the target sampling period, all electrical quantity parameters in the waveform period are replaced with the valid values of the electrical quantity parameters of the waveform period. The electrical quantity parameters at the start and end index values of the original electrical quantity sequence that have not reached one waveform period are replaced with the valid values of the electrical quantity parameters of the waveform period adjacent to the index value. Based on the target display sampling rate, the effective values of electrical quantity parameters in each waveform period are downsampled, and the effective values of each electrical quantity parameter after downsampling are used to generate the effective value curve of the electrical quantity parameter.
[0010] A further technical solution involves downsampling the effective values of electrical quantity parameters within any waveform period based on the target display sampling rate, including: Based on the target display sampling rate and waveform period, determine the number of data points N to be displayed within the waveform period, and reduce the number of valid values of electrical parameters in the waveform period to the number of data points N.
[0011] A further technical solution is to display the sampling rate based on the target. The waveform period T determines the number of data points to be displayed within the waveform period. .
[0012] Its further technical solution is to preset the sampling rate. ≥20kHz.
[0013] A further technical solution involves calculating the effective values of electrical quantity parameters for any waveform period, including: Calculate the root mean square (RMS) value of all electrical quantity parameters within the waveform period, and use the calculated RMS value as the effective value of the electrical quantity parameters within the waveform period.
[0014] The beneficial technical effects of this application are: This application discloses an adaptive testing method for the effective values of transient electrical quantity parameters. It employs high-frequency testing hardware combined with high-speed software acquisition. During acquisition, a buffer space is allocated to concatenate the electrical quantity parameters acquired in the current sampling period with those acquired in the previous sampling period. This prevents incomplete waveform periods in the currently acquired high-speed data. Zero-crossing detection is performed on the buffered data to automatically determine the waveform period of each electrical quantity parameter. Simultaneously, the effective values of transient electrical quantity parameters for each waveform period can be quickly calculated, exhibiting strong anti-interference capabilities.
[0015] Meanwhile, considering the characteristics of the waveform of electrical parameters during dynamic changes in the original generator set, the waveform of electrical parameters in actual testing is a strip waveform, making it difficult for users to intuitively see the specific changes in the effective values. The adaptive testing method of this application reconstructs and displays the calculated effective values of electrical parameters according to the target display sampling rate set by the user. This allows users to intuitively understand the dynamic changes of the effective values of generator set electrical parameters, especially during dynamic changes, providing reliable effective value data for generator set testing and a strong basis for judgment during dynamic testing of generator sets. Attached Figure Description
[0016] Figure 1 This is a strip waveform diagram of transient AC voltage in an example.
[0017] Figure 2 This is a flowchart of the adaptive testing method.
[0018] Figure 3 This is an AC voltage waveform acquired during one sampling period in an example.
[0019] Figure 4 This is a flowchart for generating the effective value curve of electrical quantity parameters in an example.
[0020] Figure 5 This is a graph showing the effective voltage value in an example. Detailed Implementation
[0021] The specific embodiments of this application will be further described below with reference to the accompanying drawings.
[0022] This application discloses an adaptive testing method for the effective values of transient electrical quantity parameters, applied to the testing of the effective values of transient electrical quantity parameters in generator sets. To obtain the changes in these parameters, high-frequency sampling testing hardware is required. To complement this hardware, the software testing method must possess high-speed data acquisition capabilities. For details, please refer to... Figure 2 The flowchart shown illustrates the specific steps of this adaptive testing method: Step 1: For any i-th sampling period within the target sampling time period, perform sampling according to the preset sampling rate. The electrical quantity parameters of the generator set within the current sampling period are acquired and concatenated with the electrical quantity parameters from the previous sampling period in chronological order to obtain the original electrical quantity sequence. To ensure accurate acquisition of transient electrical quantity parameters, a preset sampling rate is used. ≥20kHz. The target sampling period is selected according to the actual application requirements; this application collects electrical parameters for one minute.
[0023] In the data acquisition thread, transient electrical parameter acquisition begins after the acquisition task is issued. Since the lower-level machine uploads data at fixed time intervals, such as 0.2 seconds, the very beginning and end of the 0.2-second data segment may not represent a complete waveform cycle at the start of acquisition. The generator set's electrical parameters include AC voltage and AC current. Taking AC voltage acquisition with a sampling period of 0.1 seconds as an example, the waveform of the electrical parameters acquired within one sampling period is as follows: Figure 3 As shown, the electrical quantity parameters within the sampling period are not complete cycles at the acquisition edges. It is necessary to concatenate the original waveform of the current transmission with the previous waveform before performing period determination and RMS value calculation. This ensures that the RMS value is not distorted at the data edges of a dynamic acquisition cycle. Specifically, based on the preset sampling rate, the system automatically allocates a waveform queue within the target sampling period and places it in the system buffer. After each acquisition of electrical quantity parameters for the current sampling period, the currently acquired electrical quantity parameters are concatenated with the previously acquired electrical quantity parameters in a first-in-first-out stack manner according to the sampling time order, and then placed into the system-allocated buffer.
[0024] After data concatenation, a raw electrical quantity sequence is formed, consisting of a set of original electrical quantity parameters. This raw electrical quantity sequence then forms a set of data combinations corresponding to index values and data values based on the sampling rate. Specifically, the raw electrical quantity sequence includes multiple electrical quantity parameters collected within two consecutive sampling periods. Each electrical quantity parameter corresponds to an index value, which in turn corresponds to the sampling time of the electrical quantity parameter. The index value indicates the order of the electrical quantity parameter in the raw electrical quantity sequence. For example, starting from the beginning of the current sampling period, the index value of the first collected electrical quantity parameter is 1. As the sampling time progresses, the index values of the electrical quantity parameters increase sequentially. Therefore, the index values of the electrical quantity parameters correspond one-to-one with the sampling time. It should be noted that when the sampling period is not the initial sampling period (i.e., integer parameter i > 1), the current sampling period needs to be concatenated with the electrical quantity parameters of the previous sampling period. If the sampling period is the initial sampling period (i = 1), the collected electrical quantity parameters do not need to be concatenated and are directly stored in the system cache.
[0025] Step 2: Perform zero-crossing detection on the original electrical quantity sequence and identify all zero-crossing index values; determine the waveform period of each electrical quantity parameter in the original electrical quantity sequence based on all identified zero-crossing index values. The zero-crossing index value represents the index value of the electrical quantity parameter in the original electrical quantity sequence that belongs to the zero-crossing point.
[0026] In transient electrical quantity parameter testing, sudden application and removal can cause changes in the waveform period of electrical quantity parameters. Therefore, accurately determining the waveform period is crucial for the accurate calculation of the effective value of electrical quantity parameters. Since each waveform period corresponds to three consecutive zero-crossing index values, identifying the zero-crossing index values can determine the waveform period. Therefore, the first step is to identify the zero-crossing index values.
[0027] In one embodiment, zero-crossing detection is performed on the original electrical quantity sequence to identify all zero-crossing index values, including: Initialize the number of iterations k=1 and determine the zero-crossing threshold. The zero-crossing threshold must be accurately and reliably determined; otherwise, inaccurate zero-crossing determination will lead to inaccurate waveform period determination, and consequently, problems in the calculation of the effective value. Furthermore, AC waveforms exhibit a sinusoidal distribution and theoretically should always cross zero. However, regardless of the sampling rate, there is always an interval between sampling points. Therefore, the electrical quantity parameters at the sampling points can only be infinitely close to zero, not exactly zero. Thus, it is necessary to set a zero-crossing threshold to filter out the zero-crossing points among the collected electrical quantity parameters.
[0028] When k=1 in the initial iteration, according to the preset sampling rate and the predetermined rated values of electrical quantity parameters Determine the zero-crossing threshold for the initial iteration with k=1. , It is a scaling factor and , The specific value is customized according to actual application requirements, with a default value of 0.8; when k>1, the zero-crossing threshold for this iteration is determined based on the zero-crossing threshold obtained from the previous iteration update. .
[0029] In each iteration, a preliminary zero-crossing screening is first performed, selecting electrical quantity parameters in the original electrical quantity sequence whose absolute values are less than the zero-crossing threshold. The index values of each electrical quantity parameter are used as candidate index values, and the candidate index values are combined in order to obtain a candidate index array; the candidate index values in the candidate index array are sorted according to the order of the index values in the original electrical quantity sequence.
[0030] Further, the rationality of the selected candidate index values is confirmed by looping through the candidate index array and subtracting the previous candidate index value from the next candidate index value to obtain the difference between any two adjacent candidate index values. When there is a difference between two adjacent candidate index values If the difference requirement is not met, update the original electrical quantity sequence and update the zero-crossing threshold. .
[0031] On the one hand, the zero-crossing threshold is obtained through updating. include: When the difference between two adjacent candidate index values A value of 1 indicates that the zero-crossing threshold is set too high, and the condition for zero-crossing determination is too lenient. This causes more consecutive sampling points in the signal to be misjudged as zero-crossings because their absolute values are less than the high threshold. This is reflected in the candidate index array as a difference of 1 between adjacent candidate index values. This situation indicates that the zero-crossing determination range is too large, containing a large number of non-true zero-crossings, thus making the determination unreasonable. In this case, the zero-crossing threshold needs to be adjusted to update the obtained zero-crossing threshold. ; When the difference between two adjacent candidate index values Greater than 1 and less than the second threshold If the waveform exhibits clutter interference near the zero-crossing point, this indicates the presence of such interference. Clutter interference typically has a high frequency and manifests as small intervals between adjacent candidate index values. In this case, it is unnecessary to adjust the zero-crossing threshold; simply remove the zero-crossing points caused by the clutter interference and update the zero-crossing threshold accordingly. Among them, the second threshold The specific value can be set based on accumulated experimental experience, for example, setting... =10.
[0032] When the difference between two adjacent candidate index values Greater than the third threshold If the threshold is set too low, the zero-crossing condition will be too strict, only allowing points with extremely small absolute values of electrical parameters to be identified as zero-crossings. This results in a large number of true zero-crossings not being identified, significantly increasing the interval between adjacent zero-crossings in the zero-crossing index array. The zero-crossing threshold is then updated. Among them, the third threshold Greater than the second threshold The third threshold The specific value is set in conjunction with the preset sampling rate and the basic waveform period of the electrical quantity parameters. For example, based on the fact that the period of the commonly used AC voltage of the generator set is 0.02s, the value is set as follows: Multiplying 0.02 by the preset sampling rate is equivalent to the number of sampling points that should be included in a complete 50Hz cycle. For example, when the preset sampling rate is 20kHz, 0.02 × 20000 = 400 points (i.e., the number of samples within a 50Hz cycle). If the difference between adjacent candidate index values is greater than this value, it indicates that the time interval between two zero-crossings exceeds the normal waveform cycle (0.02s), meaning that a large number of true zero-crossings are not identified due to the low threshold, resulting in zero-crossing loss. Therefore, 0.02 is an industry-standard parameter based on the 50Hz AC voltage cycle, which can be used to quantitatively determine whether the zero-crossing interval is abnormal, ensuring the accuracy of cycle determination.
[0033] On the other hand, updating the original electrical quantity sequence includes: When the difference between two adjacent candidate index values Equal to 1, or the difference between two adjacent candidate index values. Greater than the third preset value At the same time, the original electrical parameter sequence remains unchanged; When the difference between two adjacent candidate index values Greater than 1 and less than the second preset value When identifying false zero-crossing indices caused by clutter interference between two adjacent candidate indices, a judgment is made by combining the consistency of the differences between them and the benchmark of the normal period. Specifically, the difference between the previous candidate index value and the previous candidate index value in the current two adjacent candidate index values, and the difference between the next candidate index value and the next candidate index value in the current two adjacent candidate index values, are calculated. The candidate index value corresponding to the smaller difference between the previous and next differences between the current two adjacent candidate index values is determined, and the electrical quantity parameter corresponding to the candidate index value is removed from the original electrical quantity sequence. For example, if the current two adjacent candidate index values are A and B, the difference between A and the previous candidate index value is checked and recorded as D1; the difference between B and the next candidate index value is checked and recorded as D2; if D1 is greater than D2, then A is a true zero-crossing point, and B is a false index caused by clutter, and the electrical quantity parameter corresponding to B is removed.
[0034] Let k = k + 1, based on the updated zero-crossing threshold. The zero-crossing detection is repeated until the difference between any two adjacent candidate index values in the candidate index array meets the difference requirement, thus obtaining all zero-crossing index values. The difference requirement for any two adjacent candidate index values is as follows: .
[0035] By executing the aforementioned iterative zero-crossing detection process, each waveform period of the electrical quantity parameter waveform can be adaptively determined without manual intervention. After the zero-crossing index is determined to be normal, the original electrical quantity sequence is divided according to the waveform period composed of three consecutive zero-crossing index values, resulting in multiple consecutive waveform period intervals corresponding to the electrical quantity parameter waveforms. The original electrical quantity parameters within each interval represent all sampling points within a complete waveform period, which are used for subsequent effective value calculation.
[0036] Step 3: Calculate the effective values of the electrical quantity parameters for each waveform cycle based on all electrical quantity parameters within each waveform cycle.
[0037] Because signals are subject to interference during sampling, the traditional method of calculating RMS values based on peaks and troughs is susceptible to interference, leading to inaccurate peak and trough determination and allowing noise to participate in the RMS calculation, resulting in a significant deviation from the actual value. To address this issue, this application calculates the root mean square (RMS) value of all electrical quantity parameters within the waveform period when calculating the RMS value of electrical quantity parameters for any waveform period, and uses the calculated RMS value as the RMS value of the electrical quantity parameter for that waveform period.
[0038] The effective value of the electrical quantity parameters of this waveform period The calculation formula is: ,in, This represents the electrical quantity parameter value at sampling time t, where T represents the waveform period.
[0039] After determining the reasonableness of the waveform period index, the root mean square (RMS) values of all electrical parameters within the waveform period are calculated to ensure the accuracy of the RMS value calculation. On one hand, judging the reasonableness of the index filters out a lot of noise and interference, especially at zero-crossing points, which helps improve the accuracy of subsequent RMS value calculations. On the other hand, due to the high sampling rate and large data volume within the waveform period, and the interference frequency being several orders of magnitude higher than the actual electrical parameter frequency, using the RMS value method to calculate the RMS value of all electrical parameters within the waveform period minimizes the impact of interference, thus ensuring the stability of the RMS value calculation.
[0040] Step 4: Based on the effective values of electrical quantity parameters for each waveform period calculated from all sampling periods within the target sampling time period, generate the effective value curve of electrical quantity parameters within the target sampling time period according to the target display sampling rate.
[0041] Due to the high sampling rate, the density of the calculated RMS values of electrical quantity parameters is relatively large. If displayed according to the original sampling frequency of the electrical quantity parameters, it is difficult to clearly see the changes in the RMS values. Therefore, after the RMS values are calculated, the waveform display data needs to be reconstructed according to the sampling rate required by the user to generate the RMS value curve of the electrical quantity parameters.
[0042] Please refer to Figure 4 The flowchart shown illustrates how to generate effective value curves for electrical quantity parameters within a target sampling period according to the target display sampling rate, including: For any waveform period in any original electrical quantity sequence within the target sampling period, all electrical quantity parameters in that waveform period are replaced with the valid values of the electrical quantity parameters in that waveform period. Electrical quantity parameters at the start and end indices of the original electrical quantity sequence that do not reach a full waveform period are replaced with the valid values of the electrical quantity parameters from the waveform period adjacent to that index. Specifically, at the boundary between the electrical quantity parameters of the current sampling period and the electrical quantity parameters of the previous sampling period, the correct valid values can be calculated because the concatenation is complete. At the edges of the sampling period, data that does not reach a full waveform period are directly replaced with the valid values of the most recent waveform period.
[0043] Based on the target display sampling rate, the effective values of electrical quantity parameters in each waveform period are downsampled, and the effective values of each electrical quantity parameter after downsampling are used to generate the effective value curve of the electrical quantity parameter.
[0044] In this process, the effective values of electrical quantity parameters for each waveform cycle are cached in the effective value queue in sequence. After the data calculation is completed, the data in the effective value queue is downsampled. After downsampling, the data in the effective value queue can be directly extracted to generate the effective value curve of electrical quantity parameters and display it.
[0045] The target display sampling rate is set before data acquisition begins. This ensures that the actual sampled values are reprocessed according to the target sampling rate before display, guaranteeing that changes in the actual waveform period do not affect the curve display. This allows users to intuitively perceive changes in the effective values of electrical parameters. Furthermore, during sudden increases or decreases in load, there is no need to worry about frequency changes affecting the effective values, nor about interference or other factors influencing them.
[0046] In one embodiment, downsampling the effective values of electrical quantity parameters within any waveform period according to the target display sampling rate includes: determining the number of data points N to be displayed within the waveform period based on the target display sampling rate and the waveform period, and reducing the number of effective values of electrical quantity parameters in the waveform period to the number of data points N.
[0047] Among them, the sampling rate is displayed according to the target. The waveform period T determines the number of data points to be displayed within that waveform period. .
[0048] Taking the adaptive test of transient AC voltage RMS value as an example, the original signal acquired is the low-voltage AC voltage output by the diesel generator set. This voltage is converted into a weak signal by a current transformer and acquired by a high-speed acquisition board. After acquisition, it is converted into the actual voltage through the set transformation ratio parameters. Then, using the adaptive test method of transient electrical quantity parameter RMS value of this application, the RMS value of the voltage for each waveform cycle is accurately calculated and displayed intuitively as a voltage RMS curve according to user requirements. Figure 5 As shown, the effective voltage value fluctuates slightly around 380V.
[0049] The above descriptions are merely preferred embodiments of this application, and this application is not limited to the above embodiments. It is understood that other improvements and variations that can be directly derived or conceived by those skilled in the art without departing from the spirit and concept of this application should be considered to be included within the protection scope of this application.
Claims
1. An adaptive testing method for the effective value of transient electrical quantity parameters, characterized in that, The adaptive testing method includes: For any i-th sampling period within the target sampling time period, according to the preset sampling rate The electrical quantity parameters of the generator set in the current sampling period are obtained and concatenated with the electrical quantity parameters in the previous sampling period in chronological order to obtain the original electrical quantity sequence. The original electrical quantity sequence includes multiple electrical quantity parameters collected in two consecutive sampling periods. Each electrical quantity parameter corresponds to an index value, which corresponds to the sampling time of the electrical quantity parameter and indicates the order of the electrical quantity parameter in the original electrical quantity sequence. Integer parameter i >
1. Zero-crossing detection is performed on the original electrical quantity sequence to identify all zero-crossing index values; based on all identified zero-crossing index values, the waveform period of each electrical quantity parameter in the original electrical quantity sequence is determined, and each waveform period corresponds to three consecutive zero-crossing index values. The zero-crossing index value represents the index value of the electrical quantity parameter in the original electrical quantity sequence that belongs to the zero-crossing point. Based on all electrical quantity parameters within each waveform cycle, the effective values of the electrical quantity parameters for each waveform cycle are calculated. Based on the effective values of electrical quantity parameters for each waveform period calculated from all sampling periods within the target sampling time period, a curve of effective values of electrical quantity parameters within the target sampling time period is generated according to the target display sampling rate.
2. The adaptive testing method according to claim 1, characterized in that, Zero-crossing detection is performed on the original electrical quantity sequence to identify all zero-crossing index values, including: Initialize the number of iterations k=1 and determine the zero-crossing threshold. ; The absolute value of the electrical quantity parameter in the original electrical quantity sequence is less than the zero-crossing threshold. The index values of each electrical quantity parameter are used as candidate index values, and the candidate index values are combined in order to obtain a candidate index array; Iterate through the candidate index array, subtracting the previous candidate index from the next candidate index value in each iteration, to obtain the difference between any two adjacent candidate index values. When there is a difference between two adjacent candidate index values If the difference requirement is not met, update the original electrical quantity sequence and update the zero-crossing threshold. ; Let k = k + 1, based on the updated zero-crossing threshold. The zero-crossing detection is repeated until the difference between any two adjacent candidate index values in the candidate index array meets the difference requirement, thus obtaining all zero-crossing index values.
3. The adaptive testing method according to claim 2, characterized in that, The updated zero-crossing threshold is obtained. include: When the difference between two adjacent candidate index values When the value is 1, the zero-crossing threshold is updated. ; When the difference between two adjacent candidate index values Greater than 1 and less than the second threshold At that time, the zero-crossing threshold is updated. ; When the difference between two adjacent candidate index values Greater than the third threshold At that time, the zero-crossing threshold is updated. Among them, the third threshold Greater than the second threshold .
4. The adaptive testing method according to claim 2, characterized in that, Updating the original electrical quantity sequence includes: When the difference between two adjacent candidate index values Equal to 1, or the difference between two adjacent candidate index values. Greater than the third preset value At the same time, the original electrical parameter sequence remains unchanged; When the difference between two adjacent candidate index values Greater than 1 and less than the second preset value When the current two adjacent candidate index values are at the same time, the difference between the previous candidate index value and the previous candidate index value, and the difference between the next candidate index value and the next candidate index value are calculated. The candidate index value corresponding to the smaller difference between the previous and next differences of the current two adjacent candidate index values is determined, and the electrical quantity parameter corresponding to the candidate index value is removed from the original electrical quantity sequence.
5. The adaptive testing method according to claim 2, characterized in that, According to the preset sampling rate and rated values of electrical quantity parameters Determine the zero-crossing threshold for the initial iteration with k=1. , It is a scaling factor and .
6. The adaptive testing method according to claim 1, characterized in that, The process of generating the effective value curve of electrical quantity parameters within the target sampling period according to the target display sampling rate includes: For any waveform period in any original electrical quantity sequence within the target sampling period, all electrical quantity parameters in the waveform period are replaced with the valid values of the electrical quantity parameters of the waveform period, and the electrical quantity parameters at the start and end index values of the original electrical quantity sequence that have not reached one waveform period are replaced with the valid values of the electrical quantity parameters of the waveform period adjacent to the index value. Based on the target display sampling rate, the effective values of electrical quantity parameters in each waveform period are downsampled, and the effective values of each electrical quantity parameter after downsampling are used to generate the effective value curve of the electrical quantity parameter.
7. The adaptive testing method according to claim 6, characterized in that, Downsampling of the effective values of electrical quantity parameters within any waveform period based on the target display sampling rate includes: Based on the target display sampling rate and the waveform period, determine the number of data points N to be displayed within the waveform period, and reduce the number of valid values of electrical quantity parameters in the waveform period to the number of data points N.
8. The adaptive testing method according to claim 7, characterized in that, Based on the target, the sampling rate is displayed. The number of data points to be displayed within the waveform period is determined by the waveform period T. .
9. The adaptive testing method according to claim 1, characterized in that, The preset sampling rate ≥20kHz.
10. The adaptive testing method according to claim 1, characterized in that, The effective values of electrical quantity parameters with arbitrary waveform periods are calculated as follows: Calculate the root mean square (RMS) value of all electrical quantity parameters within the waveform period, and use the calculated RMS value as the effective value of the electrical quantity parameters within the waveform period.