A direct-current charging pile automatic power distribution method, medium and system
By combining a three-level power allocation framework and harmonic probability matrix, and utilizing an adaptive optimization model and the Ford-Fulkerson algorithm, dynamic power allocation and power quality optimization of DC charging piles under different load conditions are achieved, thereby improving the system's reliability and power quality.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- QINGDAO HIGH TECH COMM
- Filing Date
- 2025-08-22
- Publication Date
- 2026-06-09
Smart Images

Figure CN120942085B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of DC charging pile technology, and specifically relates to an automatic power distribution method, medium and system for DC charging piles. Background Technology
[0002] With the rapid development of the electric vehicle industry, DC charging piles play a crucial role in urban charging networks as core infrastructure. Traditional DC charging pile power allocation technologies mainly employ static uniform allocation methods or simple priority allocation strategies, managing the power demand of multiple charging ports through preset fixed power allocation ratios or queuing mechanisms based on charging time. These methods are widely used in charging stations, parking lots, and commercial complexes, meeting basic multi-vehicle parallel charging needs. However, traditional power allocation technologies have significant drawbacks. First, static allocation methods cannot dynamically adjust based on real-time charging status and battery characteristics, resulting in low power utilization efficiency. Second, existing technologies lack comprehensive consideration of power quality issues such as harmonics, easily leading to grid pollution under high load conditions. Third, traditional methods lack sufficient monitoring and prediction capabilities for power stability, making it difficult to guarantee the reliability of the charging process. Therefore, traditional technologies struggle to address the core problem of coordinating and balancing power allocation and power quality optimization when multiple ports of a DC charging pile are charging simultaneously. Especially under complex load conditions, the contradiction between power allocation efficiency and power quality becomes increasingly prominent, severely impacting the overall performance of the charging system. Summary of the Invention
[0003] In view of this, the present invention provides an automatic power distribution method, medium and system for DC charging piles, which can solve the technical problem in the prior art that it is difficult to coordinate and balance power distribution and power quality optimization when multiple ports of DC charging piles are charging at the same time.
[0004] The present invention is implemented as follows: The first aspect of the present invention provides an automatic power allocation method for DC charging piles, comprising: establishing a multi-level power allocation framework, allocating the total power of the charging pile in three levels according to the urgency of charging demand and battery capacity status, and using a hierarchical separation function to determine the power separation threshold between each level; calculating the allocation factor for each charging port, and establishing an allocation weight matrix by real-time monitoring of the charging current, voltage fluctuation amplitude, and remaining charging time of each port; constructing a harmonic probability matrix, collecting harmonic spectrum data of each charging port at different power levels, and calculating the harmonic impact factor through a harmonic risk assessment function; generating a compensation factor, and calculating the required harmonic suppression power ratio for each charging port based on the harmonic probability matrix; establishing a power stability matrix, and using an adaptive optimization model for stability prediction; calculating the power factor stability index; and executing automatic power allocation, transforming the power allocation problem into a maximum flow problem in graph theory for solution, constructing a flow network graph with the charging pile as the source and each charging port as the sink, using the Ford-Fulkerson algorithm to iteratively find augmenting paths, and updating the flow allocation through a residual network to achieve a balance between power quality optimization and power allocation efficiency.
[0005] The multi-level power allocation step is specifically a technical method for allocating and managing the total power of the charging pile according to different levels. The first level of basic power allocation is evenly distributed according to the number of connected vehicles and basic charging needs. The second level of dynamic power adjustment is adjusted in real time according to the charging status and urgency of each vehicle. The third level of harmonic compensation power is reserved to deal with power quality problems generated during the charging process.
[0006] Specifically, the harmonic probability matrix is a two-dimensional data structure that records the probability of occurrence of each harmonic under different charging power and load conditions. The matrix rows represent different power levels, the columns represent different harmonic orders, and the matrix element values are the statistical probabilities of the occurrence of harmonics under the corresponding conditions.
[0007] The power stability matrix is a data matrix that evaluates the stability of the power output of each charging port. It includes stability indicators such as power fluctuation variance, stable response time, overshoot, and steady-state error, and is used to quantify the reliability of the current allocation scheme.
[0008] The power factor stability index is a comprehensive evaluation index that measures the stability of the power factor of a charging system. It is calculated by monitoring parameters such as the rate of change, fluctuation amplitude, and recovery time of the power factor to obtain a value that reflects the stability of the system's power quality.
[0009] The hierarchical separation function is used to determine the power separation threshold between each level in the multi-level power allocation framework. The inputs include the total power capacity of the charging pile, the number of current access ports, historical load peak data, power grid quality level parameters, and ambient temperature compensation coefficient. The outputs are two values: the separation threshold between the first level and the second level, and the separation threshold between the second level and the third level.
[0010] The harmonic risk assessment function is used to calculate the comprehensive risk level of harmonics generated by each charging port under the current operating conditions. The input includes five key parameters: charging current, load characteristic coefficient, grid impedance parameter, historical harmonic data and ambient temperature. The output is a harmonic influence factor value between 0 and 1. The larger the harmonic influence factor value, the higher the risk of harmonic generation and the more compensation power needs to be reserved.
[0011] The adaptive optimization model is a time-series prediction network based on an improved Transformer architecture. It includes a multi-layer encoder module for processing historical power data features, a decoder module for predicting future power stability trends, and a hierarchical fusion weight in the key multi-head attention mechanism that is dynamically adjusted based on three parameters: the current total load rate of the charging pile, the number of ports, and the average charging power.
[0012] The allocation factor is a numerical parameter that characterizes the power allocation weight of each charging port. It is calculated by comprehensively considering multiple dimensions such as charging current, voltage fluctuation amplitude, remaining charging time and user priority, to obtain the coefficient of the proportion of each port in the total power.
[0013] The compensation factor is specifically an adjustment parameter used to correct power distribution to offset the effects of harmonics. Based on the predicted probability and intensity of harmonic generation, the proportion of additional compensation power that needs to be allocated to each charging port is calculated to ensure that the overall power quality meets the standard requirements.
[0014] Furthermore, before training the adaptive optimization model, the process includes establishing a training dataset, collecting charging pile operation data for different seasons and time periods, recording information such as power fluctuation variance, stabilization time, load changes, and environmental parameters for each port, constructing a basic dataset containing at least 10,000 time series samples, performing normalization processing and feature engineering transformation on the data, and extracting derived features such as power gradient, fluctuation frequency, and stability evaluation indicators.
[0015] The Ford-Fulkerson algorithm in this scheme is used as follows: first, the source capacity is set according to the total power capacity of the charging pile; the sink capacity is set according to the maximum allowable power of each charging port; the flow limit of each edge in the network is determined according to the allocation factor and compensation factor; starting from the source, the augmenting path to the sink is found using depth-first search or breadth-first search; the flow allocation is updated along the augmenting path and the remaining capacity of each edge in the residual network is modified.
[0016] The adaptive weight adjustment function is used to adjust the hierarchical fusion weight parameters of the adaptive optimization model. The adaptive weight adjustment function calculates a comprehensive load status evaluation value based on multiple data such as the current total load rate of the charging pile, the number of access ports, the average charging power, the power fluctuation variance, and the ambient temperature. When the comprehensive load status evaluation value belongs to the low load range, the linear weight adjustment function is used to maintain the balance of weights at each level.
[0017] A second aspect of the present invention provides a computer-readable storage medium storing program instructions, which, when executed in a computer, are used to perform the above-described automatic power allocation method for a DC charging pile.
[0018] A third aspect of the present invention provides an automatic power distribution system for DC charging piles, comprising the aforementioned computer-readable storage medium. The system is any one of a computer, a server, or a microcontroller. The computer-readable storage medium is disposed within the system, and the system is provided with a microprocessor that executes the program instructions stored in the computer-readable storage medium.
[0019] This invention achieves coordinated optimization of power allocation and power quality by establishing a three-level power allocation system and a harmonic probability matrix. The method uses a hierarchical separation function to dynamically determine the allocation thresholds at each level, combined with real-time monitored allocation and compensation factors, to construct a complete power management system. This system achieves progressive optimization from basic uniform allocation to dynamic adjustment and then to harmonic compensation, overcoming the limitations of static allocation methods. Based on the compensation mechanism of the harmonic probability matrix and risk assessment function, it actively predicts and suppresses power quality problems, solving the problem of insufficient harmonic consideration in traditional methods. The adaptive optimization model improves system reliability by accurately predicting power stability through an improved Transformer architecture. By transforming power allocation into a graph-theoretic maximum flow problem, the Ford-Fulkerson algorithm is used to find the optimal solution, ensuring power allocation efficiency while considering power quality requirements. Multi-dimensional evaluation indicators and an adaptive weight adjustment mechanism ensure dynamic balance under different load conditions, solving the core problem of coordinating power allocation and power quality optimization. Attached Figure Description
[0020] Figure 1 This is a flowchart of the method of the present invention.
[0021] Figure 2 This is a schematic diagram of the adaptive optimization model. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings.
[0023] like Figure 1 The diagram shown is a flowchart of an automatic power allocation method for a DC charging pile provided by the first aspect of the present invention. This method includes the following steps:
[0024] S01. Establish a multi-level power allocation framework, allocate the total power of the charging pile in three levels according to the urgency of charging demand and battery capacity status, and use a hierarchical separation function to determine the power separation threshold between the first level basic power allocation, the second level dynamic power adjustment and the third level harmonic compensation power reservation.
[0025] S02. Calculate the allocation factor for each charging port. By monitoring the charging current, voltage fluctuation amplitude and remaining charging time of each port in real time, establish an allocation weight matrix and determine the power allocation priority coefficient of each port at the current moment.
[0026] S03. Construct a harmonic probability matrix, collect harmonic spectrum data of each charging port at different power levels, statistically analyze the probability distribution of each harmonic occurrence, calculate the harmonic impact factor through the harmonic risk assessment function, and form a two-dimensional data matrix for predicting harmonic risk.
[0027] S04. Generate compensation factors. Based on the harmonic probability matrix and the current power allocation state, calculate the proportion of harmonic suppression power required for each charging port as a correction parameter for power allocation.
[0028] S05. Establish a power stability matrix, record the fluctuation variance and stabilization time of power output at each port in real time, construct a stability evaluation index matrix, and use an adaptive optimization model to predict stability and optimize adjustment parameters to evaluate the stability of the current allocation scheme.
[0029] S06. Calculate the power factor stability index, monitor the power factor change trend of each charging port, establish a power factor stability evaluation model, and control the power factor fluctuation within the set threshold range.
[0030] S07. Perform automatic power allocation, transforming the power allocation problem into a maximum flow problem in graph theory. Construct a flow network graph with charging piles as the source and each charging port as the sink. Set the capacity of each edge in the network to the maximum allowable power of the corresponding port. Use the Ford-Fulkerson algorithm to iteratively find augmenting paths and update the flow allocation through the residual network until the maximum flow state is reached, thereby achieving a balance between power quality optimization and power allocation efficiency.
[0031] Among them, the multi-level power allocation is a technical method for allocating and managing the total power of the charging pile according to different levels. The first level of basic power allocation is evenly distributed according to the number of connected vehicles and basic charging needs. The second level of dynamic power adjustment is adjusted in real time according to the charging status and urgency of each vehicle. The third level of harmonic compensation power is reserved to deal with power quality problems generated during the charging process.
[0032] The allocation factor is a numerical parameter that characterizes the power allocation weight of each charging port. It is calculated by comprehensively considering multiple dimensions such as charging current, voltage fluctuation amplitude, remaining charging time and user priority, to determine the proportion of each port in the total power.
[0033] The compensation factor is a parameter used to adjust power distribution to offset the effects of harmonics. Based on the predicted probability and intensity of harmonic generation, it calculates the proportion of additional compensation power that needs to be allocated to each charging port to ensure that the overall power quality meets the standard requirements.
[0034] The harmonic probability matrix is a two-dimensional data structure that records the probability of each harmonic occurrence under different charging power and load conditions. The rows of the matrix represent different power levels, the columns represent different harmonic orders, and the matrix element values are the statistical probabilities of harmonic occurrence under the corresponding conditions.
[0035] The power stability matrix is a data matrix that evaluates the stability of power output at each charging port. It includes stability indicators such as power fluctuation variance, stable response time, overshoot, and steady-state error, and is used to quantify the reliability of the current allocation scheme.
[0036] Among them, the power factor stability index is a comprehensive evaluation index that measures the stability of the power factor of the charging system. It is calculated by monitoring parameters such as the rate of change, fluctuation amplitude and recovery time of the power factor to obtain a value that reflects the stability of the system's power quality.
[0037] The hierarchical separation function is used to determine the power separation threshold between each level in the multi-level power allocation framework. The input includes five parameters: total power capacity of charging piles, number of current access ports, historical load peak data, power grid quality level parameters, and ambient temperature compensation coefficient. The output consists of two values: the separation threshold between the first and second levels and the separation threshold between the second and third levels. These values are used to dynamically adjust the power allocation range of each level.
[0038] The harmonic risk assessment function is used to calculate the comprehensive risk level of harmonics generated by each charging port under the current operating conditions. The input includes five key parameters: charging current, load characteristic coefficient, grid impedance parameter, historical harmonic data and ambient temperature. The output is a harmonic influence factor value between 0 and 1. The larger the harmonic influence factor value, the higher the risk of harmonic generation and the more compensation power reserve is required.
[0039] The adaptive optimization model is structured as a time-series prediction network based on an improved Transformer architecture. It includes a multi-layer encoder module for processing historical power data features and a decoder module for predicting future power stability trends. The hierarchical fusion weights in the key multi-head attention mechanism are dynamically adjusted based on three parameters: the total load rate of the charging pile, the number of ports, and the average charging power. When the total load rate is below 0.329, uniform weight distribution is used. When the load rate is between 0.329 and 0.655, weights are distributed according to the importance of the ports. When the load rate exceeds 0.655, the stability prediction of high-power ports is given special attention.
[0040] The steps for establishing the training dataset for the adaptive optimization model include collecting charging pile operation data for different seasons and time periods, recording information such as power fluctuation variance, stabilization time, load changes, and environmental parameters for each port, constructing a basic dataset containing at least 10,000 time series samples, performing normalization and feature engineering transformation on the data, extracting derived features such as power gradient, fluctuation frequency, and stability evaluation indicators, and dividing the dataset into training and validation sets according to time order to ensure that the model can learn the power stability patterns under different operating conditions.
[0041] The adaptive optimization model training process includes training the model using an end-to-end supervised learning approach, using mean squared error as the main loss function to measure the difference between predicted stability and actual stability, combining regularization techniques to prevent model overfitting, optimizing network parameters through the backpropagation algorithm, setting appropriate learning rate decay strategies and early stopping mechanisms, evaluating model performance on the validation set and performing hyperparameter tuning, and finally obtaining a trained model that can accurately predict power stability and adaptively adjust the optimization strategy.
[0042] In this scheme, the Ford-Fulkerson algorithm is used as follows: First, the source capacity is set according to the total power capacity of the charging pile, and the sink capacity is set according to the maximum allowable power of each charging port. The flow limit of each edge in the network is determined according to the allocation factor and compensation factor. Starting from the source, depth-first search or breadth-first search is used to find an augmenting path to the sink. The flow allocation is updated along the augmenting path and the remaining capacity of each edge in the residual network is modified. The process of finding an augmenting path is repeated until no new augmenting path can be found. At this time, the network reaches the maximum flow state, and the corresponding flow allocation scheme is the optimal power allocation result.
[0043] The adaptive weight adjustment function is used to adjust the hierarchical fusion weight parameters of the adaptive optimization model. The adaptive weight adjustment function is calculated based on multiple data such as the current total load rate of the charging pile, the number of access ports, the average charging power, the power fluctuation variance, and the ambient temperature to obtain a comprehensive load status evaluation value. When the comprehensive load status evaluation value belongs to the low load range, a linear weight adjustment function is used to maintain the balance of weights at each level. When the comprehensive load status evaluation value belongs to the medium load range, an exponential weight adjustment function is used to highlight the importance of key ports. When the comprehensive load status evaluation value belongs to the high load range, a logarithmic weight adjustment function is used to focus on optimizing the stability prediction accuracy of high-power ports.
[0044] The specific implementation of the above steps is described in detail below. Step S01 is implemented by establishing a multi-level allocation framework through a hierarchical power management strategy. This framework achieves intelligent hierarchical power management based on a priority ranking algorithm and threshold segmentation theory. First, the total power capacity of the charging piles is collected as a basic parameter, typically set within the range of 150kW to 500kW. Then, the number of basic allocation units is determined based on the number of currently connected vehicles. The first-level basic power allocation uses an average allocation algorithm, distributing 60% to 70% of the total power evenly according to the number of connected ports, ensuring that each port receives basic charging security. The second-level dynamic power adjustment reserves 20% to 30% of the total power, adjusting in real time based on an urgency assessment function and battery state-of-charge parameters. The urgency threshold is set at 0.8; ports exceeding this value receive priority for additional power allocation. The third-level harmonic compensation power reserve accounts for 5% to 15% of the total power to address power quality issues. The hierarchical separation function uses a piecewise linear interpolation algorithm to dynamically calculate the separation threshold based on historical load peak data and power grid quality level parameters. The separation threshold between the first and second levels is usually set to 65% to 75% of the total power, and the separation threshold between the second and third levels is set to 85% to 95% of the total power.
[0045] The specific implementation of step S02 involves constructing a multi-dimensional weighted evaluation system to calculate the allocation factor for each charging port. This method is based on fuzzy logic control theory and analytic hierarchy process (AHP) to achieve precise quantification of weights. A real-time monitoring system collects charging current data from each port, typically ranging from 50A to 400A. The charging speed requirement is assessed using a current change rate analysis algorithm. Voltage fluctuation amplitude monitoring employs a sliding window variance calculation method, with a window length set between 10 and 30 seconds and a fluctuation threshold set at 2% to 5% of the rated voltage. The remaining charging time is calculated using a battery capacity estimation algorithm and a charging curve fitting method, and the time weight coefficient is determined by combining the current state of charge (SOC) and the target SOC. The allocation weight matrix is established using a normalization method, converting each dimension parameter into standardized values between 0 and 1. Then, a weighted summation algorithm is used to calculate the comprehensive allocation factor for each port. The weight coefficients are dynamically adjusted based on factors such as charging urgency, battery capacity status, and user priority. The priority coefficient is typically set between 0.1 and 2.0.
[0046] The specific implementation of step S03 involves establishing a harmonic prediction system based on spectrum analysis and probabilistic statistics. This system employs the Fast Fourier Transform algorithm and the Monte Carlo method to accurately assess harmonic risk. First, a high-precision harmonic monitoring device is deployed, with a sampling frequency set between 2kHz and 10kHz, capable of effectively capturing 2nd to 50th harmonic components. Harmonic spectrum data acquisition uses the sliding window method, with data acquisition time for each power level not less than 5 minutes to ensure sufficient statistical samples. When constructing the two-dimensional harmonic probability matrix, the row dimension represents the power level, typically divided into 10 to 20 levels, and the column dimension represents the harmonic order, covering the 2nd to 25th major harmonics. Probability calculation uses frequency statistics methods, recording the frequency at which each harmonic exceeds the limit under each operating condition. The limits are set with reference to the national standard GB / T 14549, with a voltage total harmonic distortion (THD) limit of 5% and a current THD limit of 8%. The harmonic risk assessment function is built on a fuzzy inference system. The input parameters include charging current, load characteristic coefficient, grid impedance parameters, historical harmonic data and ambient temperature. The harmonic influence factor is output through fuzzification, inference and defuzzification processes. The value of the factor ranges from 0 to 1 and is used to quantify the severity of the risk of harmonic generation.
[0047] The specific implementation of step S04 involves calculating the compensation factor based on harmonic prediction results and power allocation status. This process employs dynamic programming algorithms and optimization theory to achieve precise allocation of compensation power. Based on the risk assessment data in the harmonic probability matrix and combined with the current power allocation status of each port, the probability of harmonic generation for each port is calculated using a risk-weighted summation method. The compensation factor calculation uses a proportional-integral-derivative (PID) control algorithm, with the harmonic influence factor as the input signal. The proportional element rapidly responds to harmonic changes, the integral element eliminates steady-state errors, and the derivative element improves the system's dynamic response speed. The proportion of harmonic suppression power for each charging port is determined using a load balancing algorithm to ensure that the total compensation power does not exceed the reserved harmonic compensation power capacity. The compensation factor typically ranges from 0.05 to 0.25. When the harmonic influence factor exceeds 0.7, the compensation factor is correspondingly increased to above 0.2 to ensure sufficient harmonic suppression.
[0048] The specific implementation of step S05 involves constructing a real-time power stability assessment and prediction system. This system achieves quantitative evaluation of stability based on time series analysis theory and machine learning algorithms. The power stability matrix uses a multi-dimensional data structure to store stability indicators for each port, including parameters such as power fluctuation variance, stable response time, overshoot, and steady-state error. Power fluctuation variance is calculated using a sliding window variance method, with a window length set between 60 and 180 seconds and a variance threshold set between 1% and 3% of the rated power. Stable response time is determined using a step response analysis method, recording the time required for power to rise from 10% to 90% of the rated value, with a normal range of 2 to 10 seconds. Overshoot is calculated using a peak detection algorithm, with an allowable range of 5% to 15% of the rated power. Steady-state error is evaluated using a long-term average comparison method, with the error range controlled within 1% of the rated power. The adaptive optimization model employs an improved Transformer architecture, processing historical power data through a multi-layer encoder and decoder structure to predict future stability trends. Model training uses supervised learning, and the loss function is a weighted combination of mean squared error and stability indicators.
[0049] The specific implementation of step S06 involves establishing a dynamic power factor monitoring and control system. This system achieves stable power factor maintenance based on real-time signal processing technology and adaptive control theory. Power factor monitoring employs a digital signal processor with a sampling frequency set between 1kHz and 5kHz, accurately capturing rapid changes in the power factor. The power factor stability evaluation model uses a variational mode decomposition algorithm to decompose the power factor signal into multiple intrinsic mode functions and analyze the stability characteristics of each frequency component. Trend prediction uses a Kalman filter algorithm to establish a dynamic model of the power factor through state equations and observation equations, enabling accurate prediction of future trends. The power factor stability index is calculated using a weighted average method, with weighting coefficients determined based on parameters such as the rate of change, fluctuation amplitude, and recovery time. The index ranges from 0 to 1, with values closer to 1 indicating better stability. The power factor fluctuation control threshold is set within the range of ±0.02 to ±0.05. When the threshold is exceeded, an automatic adjustment mechanism is activated, using a reactive power compensation device to quickly correct the power factor.
[0050] The specific implementation of step S07 involves transforming the power allocation problem into a network flow optimization problem and using the Ford-Fulksen algorithm to solve for the optimal allocation scheme. This method achieves globally optimal power allocation based on graph theory and the maximum flow minimum cut theorem. First, a directed graph network is constructed, with charging piles as the source and each charging port as the sink. The capacity of each edge in the network is set to the maximum allowable power of the corresponding port, typically ranging from 10kW to 100kW. Edge weights are calculated based on allocation and compensation factors to ensure that high-priority ports receive a greater probability of flow allocation. The Ford-Fulksen algorithm first initializes the flow of all edges to zero. Then, a depth-first search or breadth-first search algorithm is used to find augmenting paths from the source to the sink, with the search depth limited to the network layer plus two. When updating the flow allocation along the augmenting path, the minimum capacity of the path is used as the increment value, and the remaining capacity of each edge in the residual network is updated simultaneously. The iterative process continues until no new augmenting paths can be found. At this point, the network reaches the maximum flow state, and the corresponding flow allocation is the optimal power allocation result. The convergence of the algorithm is judged based on whether there is a feasible path from the source to the sink in the residual network, and it usually reaches convergence within 10 to 50 iterations.
[0051] like Figure 2As shown, the adaptive optimization model employs an improved Transformer architecture as the core prediction network, optimized for power stability prediction tasks. The encoder section comprises 6 to 12 identical encoder modules, each consisting of a multi-head self-attention mechanism, a feedforward neural network, and residual connections. The multi-head self-attention mechanism uses 8 to 16 attention heads, capable of capturing dependencies across different time scales and feature dimensions. Position encoding uses sine and cosine functions, supporting time-series inputs of arbitrary length. The decoder section adopts a similar structure but adds an encoder-decoder attention mechanism to fuse historical information and the prediction target. The hierarchical fusion weight mechanism is a key innovation of this model, dynamically adjusting the attention weight allocation strategy based on the current total load rate of the charging pile. When the total load rate is below 0.329, uniform weight allocation is used, with all ports having equal importance. When the load rate is between 0.329 and 0.655, weights are allocated based on port importance and charging urgency, with the weight coefficient for important ports set at 1.5 to 2.0 times. When the load factor exceeds 0.655, focus on high-power ports, with a weighting factor of 3.0 to 5.0 times, to ensure the accuracy of stability prediction under high load conditions.
[0052] The training dataset creation process begins with large-scale data collection, covering all four seasons and 24 hours a day, with a collection period of at least one year to obtain sufficient samples of seasonal variations. The data acquisition system records key parameters such as power output, voltage and current waveforms, power factor, harmonic content, ambient temperature, and humidity at each charging port, with sampling intervals set between 1 and 10 seconds. In the data preprocessing stage, outlier detection algorithms are used to remove abnormal data caused by sensor malfunctions or communication errors; outliers are defined as data points deviating from the mean by more than three standard deviations. In the feature engineering stage, derived features such as power gradient, fluctuation frequency, autocorrelation coefficient, and frequency domain features are extracted. Principal component analysis is used to reduce feature dimensionality, retaining principal components with a cumulative contribution rate of over 95%. The dataset is divided chronologically, with the first 80% of the data used as the training set and the last 20% as the validation set to ensure that the causal relationship of the time series is not disrupted. Model training employs the backpropagation algorithm and the Adam optimizer, with an initial learning rate set to 0.001, using a cosine annealing learning rate scheduling strategy. Batch size is set to 32 to 128, training epochs are 100 to 500, and an early stopping mechanism is used to prevent overfitting. Training stops when the validation set loss shows no improvement for 10 consecutive epochs. Regularization techniques include weight decay and random deactivation. The weight decay coefficient is set to 0.0001 to 0.001, and the random deactivation probability is set to 0.1 to 0.3.
[0053] It should be noted that the three-level power allocation framework constructed in this invention has significant technical advantages over traditional single allocation strategies. Traditional methods typically employ static uniform allocation or simple priority sorting, which cannot cope with complex and ever-changing charging demand scenarios. This invention ensures that the basic charging needs of all access ports are met through the first-level basic power allocation, the second-level dynamic power adjustment makes fine adjustments based on real-time charging status and urgency, and the third-level harmonic compensation power reservation proactively addresses power quality issues. This layered and progressive design principle enables power allocation to possess both basic guarantee capabilities and dynamic response characteristics, while also taking into account power quality management, fundamentally overcoming the technical limitations of traditional methods such as single functionality and poor adaptability.
[0054] The introduction of a harmonic probability matrix and a risk assessment function represents a technological leap from passive response to proactive prevention. Existing technologies typically address harmonic issues only after they occur, leading to deteriorated power quality and system instability. This invention constructs a two-dimensional harmonic probability matrix to record the occurrence patterns of harmonics under different power levels and load conditions. Combined with a risk assessment function, it calculates the harmonic impact factor, enabling the prediction of potential harmonic risks and the pre-allocation of compensation power during the power allocation phase. The technical principle of this predictive compensation mechanism lies in combining historical statistical data with real-time operating conditions. Through probabilistic modeling, risk quantification is achieved, transforming harmonic suppression from reactive measures to proactive prevention, significantly enhancing the initiative and effectiveness of power quality control.
[0055] This invention transforms the power allocation problem into a maximum flow problem in graph theory and solves it using the Ford-Fulkerson algorithm, achieving a technological breakthrough from empirical allocation to mathematical optimization. Traditional power allocation methods rely on preset rules or simple algorithms, making it difficult to guarantee global optimality. This invention constructs a flow network graph with charging piles as the source and each port as the sink, transforming allocation factors and compensation factors into capacity constraints on network edges. Maximum flow is achieved by finding augmenting paths and updating the residual network. This graph theory modeling principle transforms a complex multi-constraint optimization problem into a classic network flow problem, utilizing mature mathematical theory to guarantee the optimality of the solution. Furthermore, the algorithm's iterative characteristics allow it to dynamically adapt to changes in constraints, providing a stronger theoretical foundation and superior performance guarantees compared to traditional heuristic methods.
[0056] The synergistic effect of the three key technological approaches described above forms a complete intelligent power allocation system, producing comprehensive technical effects that cannot be achieved by a single technology. The multi-level allocation framework provides power reserve space and a basis for harmonic prediction and compensation. The compensation factor generated by the harmonic probability matrix serves as an important constraint condition for the graph theory algorithm in the optimization solution, and the global optimization result of the graph theory algorithm, in turn, guides the specific power allocation execution at each level. This interdependent and mutually reinforcing synergistic mechanism enables the system to proactively prevent power quality problems while ensuring basic charging needs, and simultaneously achieves mathematical optimization of global power allocation. Compared to the existing technical architecture where each module operates independently and lacks overall coordination, the collaborative design of this invention fundamentally solves the technical challenge of balancing power allocation efficiency and power quality optimization, achieving an organic unity of multi-objective optimization.
[0057] A second aspect of the present invention provides a computer-readable storage medium storing program instructions, which, when executed in a computer, are used to perform the above-described automatic power allocation method for a DC charging pile.
[0058] A third aspect of the present invention provides an automatic power distribution system for DC charging piles, comprising the aforementioned computer-readable storage medium. The system is any one of a computer, a server, or a microcontroller. The computer-readable storage medium is disposed within the system, and the system is provided with a microprocessor that executes the program instructions stored in the computer-readable storage medium.
[0059] Specifically, the principle of this invention is as follows: The fundamental principle behind its ability to solve the problem of coordinating power allocation and power quality lies in the construction of a systematic, multi-level optimization framework. This framework decomposes the complex power management problem into interrelated sub-problems through a three-level allocation system. The first level, basic allocation, ensures basic power requirements; the second level, dynamic adjustment, responds to real-time changes; and the third level, harmonic compensation, reserves power quality, forming a complete technical path from bottom-level protection to top-level optimization. The hierarchical separation function dynamically determines the thresholds at each level based on multiple parameters such as total power capacity, number of ports, and historical data, enabling power allocation to adapt to different operating conditions.
[0060] The introduction of allocation and compensation factors provides a precise quantitative basis for power allocation. The allocation factor comprehensively considers multiple parameters such as charging current, voltage fluctuations, and remaining time, establishing a weight matrix to determine the priority of each port, thus achieving intelligent allocation based on real-time status. The compensation factor predicts power quality risks based on the harmonic probability matrix and calculates the required compensation power ratio, transforming passive response into proactive prevention. The harmonic risk assessment function provides quantitative indicators for compensation decisions by inputting and outputting influence factors between 0 and 1 using multiple parameters.
[0061] The adaptive optimization model employs an improved Transformer architecture to construct a time-series prediction network, achieving accurate prediction of power stability through a multi-head attention mechanism and hierarchical weight fusion. The model dynamically adjusts the weight allocation strategy based on the total load factor, using appropriate weight adjustment functions in different load ranges to ensure prediction accuracy. The Ford-Fulkerson algorithm transforms the power allocation problem into a graph-based maximum flow solution, achieving globally optimal allocation while satisfying capacity constraints at each port by constructing a flow network graph and finding augmenting paths. This technical solution forms a complete logical closed loop from theoretical foundation and algorithm design to implementation method, enabling the optimization of power quality while ensuring power allocation efficiency, fundamentally solving the technical challenge of coordinating and balancing these two aspects.
[0062] The following provides a specific embodiment 1 of the present invention, and the specific implementation of each step in this embodiment 1 is described in detail below.
[0063] The specific implementation method of step S01 is the same as described above, wherein the calculation process of the hierarchical separation function is described in detail below. The hierarchical separation function is specifically expressed as follows:
[0064] ;
[0065] ;
[0066] In the formula, This is the power separation threshold between the first and second stages, in kW. This is the power separation threshold between the second and third stages, in kW. This refers to the total power capacity of the charging piles, in kW. This represents the current number of access ports. This represents the maximum number of ports. Historical peak load power, in kW; This is a parameter for power grid quality level, ranging from 0.8 to 1.2; The ambient temperature compensation coefficient is calculated using the following formula: ,in This refers to the ambient temperature, expressed in °C. It is a dimensionless parameter.
[0067] The parameter acquisition method is as follows: Obtained from the nameplate of the charging pile equipment; Obtained through a real-time monitoring system; Data was obtained using historical statistical methods, with a statistical period of 30 days. The comprehensive assessment, including voltage stability and frequency stability, is obtained through power grid quality monitoring equipment. The temperature is measured in real time by a temperature sensor.
[0068] The specific implementation of step S02 is the same as described above, wherein the calculation process of the weight allocation matrix and the allocation factor is described in detail below. The weight allocation matrix is specifically represented as follows:
[0069] ;
[0070] The formula for calculating the allocation factor for each charging port is as follows:
[0071] ;
[0072] In the formula, To assign weight matrices; This represents the total number of charging ports. For the first The allocation factor for each port; For the first The first port Weight coefficients for each dimension; For the first Normalized charging current of each port; For the first Voltage fluctuation coefficient of each port; For the first The remaining time coefficient for each port; For the first Priority coefficients for each port.
[0073] The normalized charging current is calculated as follows: ,in For the first Current charging current at each port and These are the system's minimum and maximum charging currents, respectively; the voltage fluctuation coefficient is calculated as follows: ,in For the first Standard deviation of port voltage The rated voltage is used; the remaining time coefficient is calculated as follows: ,in Charged time This is the estimated total charging time.
[0074] The specific implementation method of step S03 is the same as described above, wherein the calculation process of the harmonic probability matrix and the harmonic risk assessment function is described in detail below. The harmonic probability matrix is specifically represented as follows:
[0075] ;
[0076] The harmonic risk assessment function is specifically expressed as follows:
[0077] ;
[0078] In the formula, This is the harmonic probability matrix; Number of power levels; For harmonic order; For the first The power level The probability of the occurrence of subharmonics; For the first Harmonic influence factor of each port; These are weighting coefficients, with values ranging from 0.3 to 0.4, 0.2 to 0.3, 0.1 to 0.2, 0.1 to 0.2, and 0.05 to 0.15, respectively. This is the rated charging current; For the first Load characteristic coefficient of each port; The impedance of the power grid; Reference impedance; For the first Historical harmonic indices of each port; The reference temperature is 25℃. This is the harmonic assessment error term, ranging from -0.05 to 0.05.
[0079] The parameter acquisition method is as follows: Measured in real time using a current sensor; The load characteristics were determined using a load characteristic analyzer, including the proportions of resistive, inductive, and capacitive loads. Measured using an impedance analyzer; The statistical calculation is based on historical harmonic data, with a statistical period of 7 days.
[0080] The specific implementation method of step S04 is the same as described above, wherein the calculation process of the compensation factor is described in detail below. The compensation factor is specifically expressed as:
[0081] ;
[0082] In the formula, For the first Compensation factor for each port; These are the proportional, integral, and differential coefficients, with values ranging from 0.8 to 1.2, 0.1 to 0.3, and 0.05 to 0.15, respectively. For the first The basic compensation coefficient for each port ranges from 0.02 to 0.08; It is a time variable.
[0083] The specific implementation method of step S05 is the same as described above, wherein the calculation process of the power stability matrix is described in detail below. The power stability matrix is specifically represented as follows:
[0084] ;
[0085] In the formula, This is the power stability matrix; For the first Power fluctuation variance of each port; For the first Stable response time for each port; For the first Overshoot of each port; For the first Steady-state error of each port.
[0086] The power fluctuation variance is calculated as follows: ,in For the first The first port The power value of the next sample. For the first Average power of each port This represents the number of sampling points; For the first The current actual output power of each port, in kW.
[0087] The specific implementation method of step S06 is the same as described above, wherein the calculation process of the power factor stability index is described in detail below. The power factor stability index is specifically expressed as:
[0088] ;
[0089] In the formula, For the first Power factor stability index of each port; These are weighting coefficients, with values of 0.4, 0.3, and 0.3 respectively. For the first Power factor of each port; The rate of change of the power factor; The reference rate of change is 0.02 / s; This represents the standard deviation of power factor fluctuation. The standard deviation of the fluctuation is 0.01 for reference. Power factor recovery time; The recovery time is 5 seconds for reference. This is the stability exponential error term, ranging from -0.02 to 0.02.
[0090] The parameter acquisition method is as follows: Measured in real time using a power analyzer; Calculated using numerical differentiation methods; Calculated using the standard deviation of a sliding window; Obtained through step response testing.
[0091] The specific implementation of step S07 is the same as described above, wherein the network flow calculation process of the Ford-Fulkerson algorithm is described in detail below. The capacity matrix of the network flow graph is specifically represented as follows:
[0092] ;
[0093] Maximum flow calculation is performed through an iterative process, with the flow increment in each iteration being:
[0094] ;
[0095] In the formula, This is the network capacity matrix; For the node To the node edge capacity; For the first The augmenting path found in the next iteration; For the edge Current traffic; For the first The traffic increment of the next iteration.
[0096] The edge capacity is determined based on the allocation factor and the compensation factor: ,in For the first Maximum allowed power for each port.
[0097] It should be noted that the derivation of the two key thresholds, 0.3297 and 0.6545, is based on the analysis of the load characteristics of the charging pile system and the theory of power distribution stability optimization. Firstly, starting with the relationship between system load rate and power distribution efficiency, statistical analysis of a large amount of experimental data revealed that the power distribution efficiency of the charging pile system... With total load rate There is a non-linear relationship between them, which can be represented by a piecewise function. When the system is under low load, the power demand differences between ports are small. In this case, a uniform weight allocation strategy can achieve optimal allocation efficiency and system stability. By analyzing the system response characteristics under different load rates, a load rate critical point determination function is established. ,in For the port power demand variance, Port capacity variance The number of active ports. This represents the total number of ports. For power fluctuation variance, The average power is taken as the threshold value. Based on system dynamics and control theory, when the load rate is below a certain critical value, the system is in an underdamped state, and the transient response of power allocation exhibits uniform convergence characteristics. In this case, the optimal weight allocation strategy is uniform allocation. Regression analysis was performed on 1000 sets of experimental data under different operating conditions, and the optimal parameter combination was solved using a Bayesian optimization algorithm. And consider the system safety margin factor. The first threshold is calculated. .
[0098] The derivation of the second threshold, 0.6545, is based on determining the boundary point where the system transitions from a stable operating state to a critical saturation state. As the system load rate continues to increase, power competition among ports intensifies. At this point, differentiated weight allocation based on port importance and the urgency of power demand is necessary to prevent the system from entering an unstable state. A system stability criterion function is then established. ,in For the first The weight coefficient of each port, These are the influencing factors for power utilization, harmonic risk, and power factor stability, respectively. When When the set threshold is exceeded, the system begins to exhibit power distribution imbalance and power quality deterioration, requiring the activation of the high-power port priority protection mechanism. Based on Lyapunov stability theory analysis, the system stability domain boundary equations are established. ,in Let be the system state vector. The matrix is positive definite. Using the Routh-Hurwitz stability criterion, the load rate threshold corresponding to the system's critical stability point is determined. Considering the hardware characteristics and heat dissipation limitations of the charging pile, when the load rate exceeds the critical value, the temperature of the system's power devices rises sharply, the power conversion efficiency decreases significantly, and the probability of harmonic generation increases substantially. Through thermodynamic analysis and electromagnetic compatibility testing, a mathematical model of load rate and system performance degradation is established. ,in These are device characteristic parameters. To determine the junction temperature. Based on multi-objective optimization theory, an objective function is constructed. The optimal load factor upper limit was determined using a particle swarm optimization algorithm. Taking into account system stability margin, hardware safety operating boundaries, and power quality requirements, and combining this with statistical methods to fit and analyze historical operating data, a second threshold was finally determined. The value of 0.7 is the theoretically calculated critical load factor, and 0.935 is the comprehensive safety factor. This threshold ensures that the system can maintain stable operation and meet power quality standards under high load conditions.
[0099] To better understand and implement this invention, a specific application scenario, Example 2, is provided below: Researchers tested and verified the automatic power distribution method on a 500kW DC charging pile in a laboratory environment. The charging pile has 8 charging ports, with a maximum of 10 ports; currently, 6 ports are connected to electric vehicles for charging. The experimental environment temperature was 32℃, the grid quality rating parameter was 0.95, and the historical peak load power was 480kW.
[0100] First, step S01 is executed to establish a multi-level power allocation framework. The power separation threshold between the first and second levels is calculated based on the hierarchical separation function. An ambient temperature compensation coefficient is also considered. Calculations yielded kW. Power separation threshold between the second and third stages. Based on this separation threshold, the first-level basic power allocation is 378.05kW, the second-level dynamic power adjustment is 99.25kW, and the third-level harmonic compensation power reserve is 22.7kW.
[0101] Next, step S02 is performed to calculate the allocation factor for each charging port. Researchers monitor the operating parameters of each port in real time, as shown in Table 1.
[0102] Table 1 Real-time operating parameters for each port
[0103]
[0104] Calculate the normalized parameters based on the data in Table 1. Minimum system charging current. A, Maximum charging current A, Rated voltage V. Taking port 1 as an example, the normalized charging current Voltage fluctuation coefficient Remaining time coefficient Using weighting coefficients , , , The allocation factor for port 1 is calculated. The allocation factors for other ports were calculated using the same method, and the results are shown in Table 2.
[0105] Table 2 Calculation Results of Port Allocation Factors
[0106]
[0107] The next step, S03, involves constructing a harmonic probability matrix. Researchers collected harmonic spectrum data for each port at different power levels, statistically analyzing the probability of occurrence of the 2nd to 25th harmonics. The harmonic impact factor for each port was calculated using a harmonic risk assessment function. Taking port 2 as an example, the rated charging current... A, Load characteristic coefficient Grid impedance Ω, reference impedance Ω, Historical Harmonic Index Reference temperature ℃. Weighting coefficients are used. , , , , Harmonic evaluation error term Calculations yielded .
[0108] Step S04 generates the compensation factor. Based on the harmonic probability matrix and the current power distribution state, the compensation factor for each port is calculated using a proportional-integral-derivative (PID) control algorithm. The proportional coefficient is then set. Integral coefficient Differential coefficients Basic compensation coefficient The compensation factor for port 2 is obtained through numerical integration and differentiation. Since the compensation factor exceeds 1, normalization is required, resulting in the final... .
[0109] Step S05 establishes the power stability matrix. Researchers record parameters such as power output fluctuation variance, stable response time, overshoot, and steady-state error at each port in real time. Using a sliding window length of 120s and sampling points N=120, the power stability indices for each port are calculated, as shown in Table 3.
[0110] Table 3 Statistical Table of Power Stability Indicators
[0111]
[0112] Based on the data in Table 3, a power stability matrix S was constructed, and an improved Transformer architecture adaptive optimization model was used for stability prediction. The current total load rate of the charging piles is 0.72, exceeding the 0.6545 threshold; therefore, the stability prediction of high-power ports is the primary focus.
[0113] Step S06 involves calculating the power factor stability index. Researchers monitor the power factor variation trend at each port and use weighting coefficients. , , Reference rate of change / s, reference standard deviation of fluctuation Reference recovery time s. Taking port 4 as an example, power factor rate of change of power factor / s, standard deviation of power factor fluctuation Power factor recovery time s, the stability exponential error term Calculations yielded .
[0114] Finally, step S07 is executed for automatic power allocation. Researchers transformed the power allocation problem into a maximum flow problem in graph theory, constructing a flow network graph with charging piles as sources and each port as a sink. The network edge capacity is determined based on the maximum allowable power of each port, the allocation factor, and the compensation factor. Assuming the maximum allowable power of each port is 100kW, the edge capacity of port 2 is... kW. The Ford-Fulkerson algorithm was used to iteratively find augmenting paths. After 15 iterations, the maximum flow state was reached. The optimal power allocation results for each port are shown in Table 4.
[0115] Table 4 Optimal Power Allocation Results
[0116]
[0117] Experimental results show that the automatic power distribution method can effectively achieve intelligent power distribution across multiple ports. The total system power distribution is 406.4kW, with a power utilization rate of 81.3%. The power distribution across ports is balanced and meets actual charging requirements. The total harmonic distortion rate is controlled within 4.2%, meeting national standards. The average power factor is 0.94, and the average power factor stability index is 0.78, indicating stable system operation.
[0118] Traditional charging pile power allocation methods typically employ a static uniform allocation strategy, distributing total power evenly across the number of access ports. This fails to consider the differences in actual charging demand and power quality requirements at each port. Under the same test conditions, the power utilization rate of the traditional method is only 73.8%, 7.5 percentage points lower than the method of this invention. The total harmonic distortion rate reaches 5.8%, exceeding the standard limit, and the average power factor stability index is 0.65, indicating poor system stability. This invention, through the synergistic effect of a multi-level allocation framework, harmonic prediction compensation, and graph theory optimization algorithms, improves power utilization by 10.2%, harmonic suppression by 27.6%, and power factor stability by 20.0% compared to the traditional method. This method fundamentally solves the technical problem that traditional static allocation strategies cannot adapt to dynamic charging demands, achieving an organic unity between power allocation efficiency and power quality optimization, and providing an effective technical solution for the intelligent management of DC charging piles.
[0119] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the present invention.
Claims
1. An automatic power distribution method for DC charging piles, characterized in that, Includes the following steps: S01. Establish a multi-level power allocation framework, allocate the total power of the charging pile in three levels according to the urgency of charging demand and battery capacity status, and use a hierarchical separation function to determine the power separation threshold between the first level basic power allocation, the second level dynamic power adjustment and the third level harmonic compensation power reservation. S02. Calculate the allocation factor for each charging port. By monitoring the charging current, voltage fluctuation amplitude and remaining charging time of each port in real time, establish an allocation weight matrix and determine the power allocation priority coefficient of each port at the current moment. S03. Construct a harmonic probability matrix, collect harmonic spectrum data of each charging port at different power levels, statistically analyze the probability distribution of each harmonic occurrence, calculate the harmonic impact factor through the harmonic risk assessment function, and form a two-dimensional data matrix for predicting harmonic risk. S04. Generate compensation factors. Based on the harmonic probability matrix and the current power allocation state, calculate the proportion of harmonic suppression power required for each charging port as a correction parameter for power allocation. S05. Establish a power stability matrix, record the fluctuation variance and stabilization time of power output at each port in real time, construct a stability evaluation index matrix, and use an adaptive optimization model to predict stability and optimize adjustment parameters to evaluate the stability of the current allocation scheme. S06. Calculate the power factor stability index, monitor the power factor change trend of each charging port, establish a power factor stability evaluation model, and control the power factor fluctuation within the set threshold range. S07. Perform automatic power allocation, transform the power allocation problem into a maximum flow problem in graph theory, construct a flow network graph with charging piles as the source and each charging port as the sink, set the capacity of each edge in the network to the maximum allowable power of the corresponding port, use the Ford-Fulkerson algorithm to iteratively find augmenting paths, update the flow allocation through the residual network until the maximum flow state is reached, and achieve a balance between power quality optimization and power allocation efficiency. The step of multi-level power allocation is specifically a technical method for allocating and managing the total power of the charging pile according to different levels. The first level of basic power allocation is evenly distributed according to the number of connected vehicles and basic charging needs. The second level of dynamic power adjustment is adjusted in real time according to the charging status and urgency of each vehicle. The third level of harmonic compensation power is reserved to deal with power quality problems generated during the charging process. The hierarchical separation function is used to determine the power separation threshold between each level in the multi-level power allocation framework. The inputs include the total power capacity of the charging pile, the number of current access ports, historical load peak data, power grid quality level parameters, and ambient temperature compensation coefficient. The outputs are two values: the separation threshold between the first level and the second level, and the separation threshold between the second level and the third level.
2. The method according to claim 1, characterized in that, The harmonic probability matrix is a two-dimensional data structure that records the probability of each harmonic occurrence under different charging power and load conditions. The matrix rows represent different power levels, the columns represent different harmonic orders, and the matrix element values are the statistical probabilities of harmonic occurrence under the corresponding conditions.
3. The method according to claim 2, characterized in that, The power stability matrix is a data matrix that evaluates the stability of the power output of each charging port. It includes stability indicators such as power fluctuation variance, stable response time, overshoot, and steady-state error, and is used to quantify the reliability of the current allocation scheme.
4. The method according to claim 3, characterized in that, The power factor stability index is a comprehensive evaluation index that measures the stability of the power factor of a charging system. It is calculated by monitoring the rate of change, fluctuation amplitude, and recovery time of the power factor to obtain a value that reflects the stability of the system's power quality.
5. The method according to claim 4, characterized in that, The harmonic risk assessment function is used to calculate the comprehensive risk level of harmonics generated by each charging port under the current operating conditions. The input includes five key parameters: charging current, load characteristic coefficient, grid impedance parameter, historical harmonic data and ambient temperature. The output is a harmonic influence factor value between 0 and 1. The larger the harmonic influence factor value, the higher the risk of harmonic generation and the more compensation power reserve is required.
6. The method according to claim 5, characterized in that, The adaptive optimization model is structured as a time-series prediction network based on an improved Transformer architecture. It includes a multi-layer encoder module for processing historical power data features, a decoder module for predicting future power stability trends, and a hierarchical fusion weight in the key multi-head attention mechanism that is dynamically adjusted based on three parameters: the current total load rate of the charging pile, the number of ports, and the average charging power.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores program instructions, which, when executed in a computer, are used to perform an automatic power allocation method for a DC charging pile as described in any one of claims 1-6.
8. An automatic power distribution system for DC charging piles, characterized in that, The system includes the computer-readable storage medium of claim 7, wherein the system is any one of a computer, a server, or a microcontroller, the computer-readable storage medium is disposed within the system, and the system is provided with a microprocessor that executes the program instructions stored in the computer-readable storage medium.